Removed some notes from the source. Added kcal/l calculation.

Fri, 21 Jun 2019 16:55:36 +0200

author
Michiel Broek <mbroek@mbse.eu>
date
Fri, 21 Jun 2019 16:55:36 +0200
changeset 428
a5d4467c9201
parent 425
7671a5fc5171
child 429
0d2cf505957c

Removed some notes from the source. Added kcal/l calculation.

www/includes/formulas.php file | annotate | diff | comparison | revisions
www/js/global.js file | annotate | diff | comparison | revisions
www/js/prod_edit.js file | annotate | diff | comparison | revisions
www/js/rec_edit.js file | annotate | diff | comparison | revisions
www/prod_edit.php file | annotate | diff | comparison | revisions
www/rec_edit.php file | annotate | diff | comparison | revisions
--- a/www/includes/formulas.php	Thu Jun 20 22:16:05 2019 +0200
+++ b/www/includes/formulas.php	Fri Jun 21 16:55:36 2019 +0200
@@ -289,198 +289,4 @@
 }
 
 
-
-/*
-
-Brouwhulp data.pas
-
-
-
-Procedure TFermentable.SetpHParameters(force : boolean);
-var x, ebc : double;
-begin
-  if Between(FDIpH.Value, -0.01, 0.01) or Between(FAcidTo57.Value, -0.1, 0.1) or force then
-  begin
-    ebc:= SRMtoEBC(FColor.Value);
-    case FGrainType of
-    gtBase, gtKilned:
-    begin
-      FDIpH.Value:= -0.0132 * ebc + 5.7605;
-      x:= 0.4278 * ebc - 1.8106;
-      FAcidTo57.Value:= x;
-    end;
-    gtRoast:
-    begin
-      FDIpH.Value:= 0.00018 * ebc + 4.558;
-      FAcidTo57.Value:= -0.0176 * ebc + 60.04;
-    end;
-    gtCrystal:
-    begin
-      FDIpH.Value:= -0.0019 * ebc + 5.2175;
-      FAcidTo57.Value:= 0.132 * ebc + 14.277;
-    end;
-    gtSour:
-    begin
-      FDIpH.Value:= 3.44;
-      FAcidTo57.Value:= 337;
-    end;
-    gtSpecial: //this could be anything. Assume for now it is a non-acidulated base or kilned malt
-    begin
-      FDIpH.Value:= -0.0132 * ebc + 5.7605;
-      FAcidTo57.Value:= 0.4278 * ebc - 1.8106;
-    end;
-    end;
-  end;
-  //known parameters should be filled in here
-  if FSupplier.Value = 'Weyermann' then
-  begin
-    if FName.Value = 'Vienna mout' then
-    begin
-      FDIpH.Value:= 5.65;
-      FAcidTo57.Value:= 1.6;
-    end;
-    if FName.Value = 'Münchner I' then
-    begin
-      FDIpH.Value:= 5.44;
-      FAcidTo57.Value:= 8.4;
-    end;
-    if FName.Value = 'Münchner II' then
-    begin
-      FDIpH.Value:= 5.54;
-      FAcidTo57.Value:= 5.6;
-    end;
-    if FName.Value = 'Caramunich I' then
-    begin
-      FDIpH.Value:= 5.1;
-      FAcidTo57.Value:= 22.4;
-    end;
-    if FName.Value = 'Caramunich II' then
-    begin
-      FDIpH.Value:= 4.71;
-      FAcidTo57.Value:= 49;
-    end;
-    if FName.Value = 'Caramunich III' then
-    begin
-      FDIpH.Value:= 4.92;
-      FAcidTo57.Value:= 31.2;
-    end;
-    if FName.Value = 'Cara-aroma' then
-    begin
-      FDIpH.Value:= 4.48;
-      FAcidTo57.Value:= 74.4;
-    end;
-    if FName.Value = 'Carafa I' then
-    begin
-      FDIpH.Value:= 4.71;
-      FAcidTo57.Value:= 42;
-    end;
-    if FName.Value = 'Carafa III' then
-    begin
-      FDIpH.Value:= 4.81;
-      FAcidTo57.Value:= 35.4;
-    end;
-    if FName.Value = 'Carafa II' then
-    begin
-      FDIpH.Value:= 4.76;
-      FAcidTo57.Value:= 38.7;
-    end;
-    if FName.Value = 'Carafa Special I' then
-    begin
-      FDIpH.Value:= 4.73;
-      FAcidTo57.Value:= 46.4;
-    end;
-    if FName.Value = 'Carafa Special II' then
-    begin
-      FDIpH.Value:= 4.78;
-      FAcidTo57.Value:= 42.9;
-    end;
-    if FName.Value = 'Carafa Special III' then
-    begin
-      FDIpH.Value:= 4.83;
-      FAcidTo57.Value:= 38.9;
-    end;
-    if IsInString(FName.Value, 'Zuurmout') then
-    begin
-      FDIpH.Value:= 3.44;
-      FAcidTo57.Value:= 358.2;
-    end;
-  end;
-end;
-
-
-function TFermentable.GetExtract: double;
-begin
-  Result := 0;
-  if FRecipe <> nil then
-  begin
-    Result := FAmount.Value * FYield.Value / 100 * (1 - FMoisture.Value / 100);
-    if FAdded = atMash then
-      Result := Result * FRecipe.Efficiency / 100;
-  end;
-end;
-
-
-function TFermentable.GetKolbachIndex: double;
-begin
-  if FProtein.Value > 0 then
-    Result := FDissolvedProtein.Value / FProtein.Value
-  else
-    Result := 0;
-end;
-
-
-function TWater.GetResidualAlkalinity: double;
-begin
-  //Result in mg/l as CaCO3
-  Result:= FTotalAlkalinity.Value - (FCalcium.Value / 1.4 + FMagnesium.Value / 1.7);
-end;
-
-
-function TWater.GetHardness: double;
-begin
-  Result := 0.14 * FCalcium.Value - 0.23 * FMagnesium.Value;
-end;
-
-function TWater.GetEstPhMash: double;
-{var
-  pHdemi, S: double;}
-begin
-  Result:= MashpH;
-{  Result := 0;
-  if FRecipe <> nil then
-  begin
-    pHDemi := FRecipe.pHdemi;
-    S := 0.013 * FRecipe.MashThickness + 0.013;
-    Result := pHDemi + ResidualAlkalinity / 50 * S;
-  end;}
-end;
-
-
-
-
-
-Procedure TRecipe.CalcCalories;
-var sug, alc, org, fig : double;
-begin
-  if FOGFermenter.Value > 1.001 then org:= FOGFermenter.Value
-  else if FOG.Value > 1.001 then org:= FOG.Value
-  else org:= 0;
-  if FFG.Value > 0.999 then fig:= FFG.Value
-  else if FEstFG.Value > 1.000 then fig:= FEstFG.Value
-  else if FEstFG2.Value > 1.000 then fig:= FEstFG2.Value
-  else fig:= 0;
-  if (org > 0) and (fig > 0) then
-  begin
-    alc:= 1881.22 * fig * (org - fig) / (1.775 - org);
-    sug:= 3550 * fig * (0.1808 * org + 0.8192 * fig - 1.0004);
-    FCalories.Value:= (alc + sug) / (12 * 0.0295735296);
-  end
-  else FCalories.Value:= 0;
-end;
-
-
-
-
-*/
-
 ?>
--- a/www/js/global.js	Thu Jun 20 22:16:05 2019 +0200
+++ b/www/js/global.js	Fri Jun 21 16:55:36 2019 +0200
@@ -378,6 +378,8 @@
 var Show1wat = { inputMode: 'simple', theme: theme, width:  74, height: 23, decimalDigits: 1, readOnly: true };
 var Show2wat = { inputMode: 'simple', theme: theme, width:  74, height: 23, decimalDigits: 2, readOnly: true };
 var Show3wat = { inputMode: 'simple', theme: theme, width:  74, height: 23, decimalDigits: 3, readOnly: true };
+var Smal0dec = { inputMode: 'simple', theme: theme, width:  50, height: 23, decimalDigits: 0, readOnly: true };
+var Smal1dec = { inputMode: 'simple', theme: theme, width:  50, height: 23, decimalDigits: 1, readOnly: true };
 var Show0dec = { inputMode: 'simple', theme: theme, width:  90, height: 23, readOnly: true, decimalDigits: 0 };
 var Show1dec = { inputMode: 'simple', theme: theme, width:  90, height: 23, readOnly: true, decimalDigits: 1 };
 var Show2dec = { inputMode: 'simple', theme: theme, width:  90, height: 23, readOnly: true, decimalDigits: 2 };
--- a/www/js/prod_edit.js	Thu Jun 20 22:16:05 2019 +0200
+++ b/www/js/prod_edit.js	Fri Jun 21 16:55:36 2019 +0200
@@ -270,6 +270,7 @@
 		dataRecord.est_og = estimate_sg(sugarsf + addedS, parseFloat(dataRecord.batch_size));
                 $('#est_og').val(dataRecord.est_og);
                 $('#est_og2').val(dataRecord.est_og);
+		var org = dataRecord.est_og;
 
 		// Estimate SG in kettle after boil
 		aboil_sg = estimate_sg(sugarsf, parseFloat(dataRecord.batch_size));
@@ -387,6 +388,7 @@
 		$('#est_fg').val(dataRecord.est_fg);
 		$('#est_fg2').val(dataRecord.est_fg);
 		$('#est_fg3').val(dataRecord.est_fg);
+		var fig = dataRecord.est_fg;
 
 		dataRecord.est_abv = abvol(dataRecord.est_og, dataRecord.est_fg);
 		$("#est_abv").val(dataRecord.est_abv);
@@ -395,10 +397,17 @@
 		// Calculate the final svg if available use the real value.
 		if ((dataRecord.stage >= 6) && (dataRecord.fg > 0.990) && (dataRecord.fg < dataRecord.brew_fermenter_sg)) {
 			svg = 100 * (dataRecord.brew_fermenter_sg - dataRecord.fg) / (dataRecord.brew_fermenter_sg - 1);
+			org = dataRecord.brew_fermenter_sg;
+			fig = dataRecord.fg;
 		}
 
 		$("#yeast_cells").val(initcells);
 		$("#need_cells").val(getNeededYeastCells());
+
+		// Calculate the calories in kcal/l (from brouwhulp)
+		var alc = 1881.22 * fig * (org - fig) / (1.775 - org);
+		var sug = 3550 * fig * (0.1808 * org + 0.8192 * fig - 1.0004);
+		$("#kcal").val(Math.round((alc + sug) / (12 * 0.0295735296)));
 	};
 
 	function calcMash() {
@@ -4437,13 +4446,13 @@
 	$("#st_name").jqxTooltip({ content: 'De bierstijl naam voor dit recept.'});
 	$("#st_name").jqxInput({ theme: theme, width: 250, height: 23 });
 	$("#st_letter").jqxTooltip({ content: 'De bierstijl letter voor dit recept.'});
-	$("#st_letter").jqxInput({ theme: theme, width: 100, height: 23 });
+	$("#st_letter").jqxInput({ theme: theme, width: 90, height: 23 });
 	$("#st_type").jqxTooltip({ content: 'Het bierstijl type.'});
 	$("#st_type").jqxInput({ theme: theme, width: 250, height: 23 });
 	$("#st_category").jqxTooltip({ content: 'De Amerikaanse bierstijl categorie.'});
 	$("#st_category").jqxInput({ theme: theme, width: 250, height: 23 });
 	$("#st_category_number").jqxTooltip({ content: 'De Amerikaanse bierstijl categorie sub nummer.'});
-	$("#st_category_number").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_category_number").jqxNumberInput(Smal0dec);
 
 	$("#est_og").jqxTooltip({ content: 'Het begin SG wat je wilt bereiken. De moutstort wordt automatisch herberekend.' });
 	$("#est_og").jqxNumberInput( SGopts );
@@ -4460,18 +4469,18 @@
 	$("#st_fg_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 3, readOnly: true });
 
 	$("#est_abv").jqxTooltip({ content: 'Alcohol volume %. Dit wordt automatisch berekend.' });
-	$("#est_abv").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#est_abv").jqxNumberInput(Smal1dec);
 	$("#st_abv_min").jqxTooltip({ content: 'Het minimum alcohol volume % voor deze bierstijl.'});
-	$("#st_abv_min").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_abv_min").jqxNumberInput(Smal1dec);
 	$("#st_abv_max").jqxTooltip({ content: 'Het maximum alcohol volume % voor deze bierstijl.'});
-	$("#st_abv_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_abv_max").jqxNumberInput(Smal1dec);
 
 	$("#est_color").jqxTooltip({ content: 'De kleur in EBC. Dit wordt automatisch berekend.' });
 	$("#est_color").jqxNumberInput( Show0dec );
 	$("#st_color_min").jqxTooltip({ content: 'De minimum kleur voor deze bierstijl.'});
-	$("#st_color_min").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_color_min").jqxNumberInput(Smal0dec);
 	$("#st_color_max").jqxTooltip({ content: 'De maximum kleur voor deze bierstijl.'});
-	$("#st_color_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_color_max").jqxNumberInput(Smal0dec);
 	$("#color_method").jqxDropDownList({
 		theme: theme,
 		source: ColorMethodAdapter,
@@ -4481,13 +4490,12 @@
 		height: 23,
 		autoDropDownHeight: true
 	});
-
 	$("#est_ibu").jqxTooltip({ content: 'De bitterheid in IBU. Dit wordt automatisch berekend.' });
 	$("#est_ibu").jqxNumberInput( Show0dec );
 	$("#st_ibu_min").jqxTooltip({ content: 'De minimum bitterheid voor deze bierstijl.'});
-	$("#st_ibu_min").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_ibu_min").jqxNumberInput(Smal0dec);
 	$("#st_ibu_max").jqxTooltip({ content: 'De maximum bitterheid voor deze bierstijl.'});
-	$("#st_ibu_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_ibu_max").jqxNumberInput(Smal0dec);
 	$("#ibu_method").jqxDropDownList({
 		theme: theme,
 		source: IBUmethodAdapter,
@@ -4498,13 +4506,14 @@
 		autoDropDownHeight: true,
 		dropDownVerticalAlignment: 'top'
 	});
-
+	$("#kcal").jqxTooltip({ content: 'Energie-inhoud in kcal/liter.' });
+	$("#kcal").jqxNumberInput( Smal0dec );
 	$("#est_carb").jqxTooltip({ content: 'Koolzuur volume. Dit wordt automatisch berekend.' });
-	$("#est_carb").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#est_carb").jqxNumberInput(Smal1dec);
 	$("#st_carb_min").jqxTooltip({ content: 'Het minimum koolzuur volume voor deze bierstijl.'});
-	$("#st_carb_min").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_carb_min").jqxNumberInput(Smal1dec);
 	$("#st_carb_max").jqxTooltip({ content: 'Het maximum koolzuur volume voor deze bierstijl.'});
-	$("#st_carb_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_carb_max").jqxNumberInput(Smal1dec);
 
 	// Tab 2, Equipment
 	$("#eq_name").jqxTooltip({ content: 'De naam van deze brouw apparatuur.' });
@@ -4829,7 +4838,7 @@
 
 	// Tab 4, Hops
 	$("#est_ibu2").jqxTooltip({ content: 'De bitterheid in IBU. Dit wordt automatisch berekend.' });
-	$("#est_ibu2").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#est_ibu2").jqxNumberInput(Smal0dec);
 	$("#hop_flavour").jqxProgressBar({
 		width: 300,
 		height: 23,
@@ -5145,7 +5154,7 @@
 	$("#est_fg2").jqxTooltip({ content: 'Het verwachte eind SG. Dit wordt automatisch berekend.' });
 	$("#est_fg2").jqxNumberInput( Show3dec );
 	$("#est_abv2").jqxTooltip({ content: 'Alcohol volume %. Dit wordt automatisch berekend.' });
-	$("#est_abv2").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#est_abv2").jqxNumberInput(Smal1dec);
 	$("#yeast_cells").jqxNumberInput( Show1dec );
 	$("#need_cells").jqxNumberInput( Show1dec );
 	$("#plato_cells").jqxNumberInput( Show2dec );
@@ -5824,9 +5833,9 @@
 	$('#package_abv').jqxTooltip({ content: 'De uiteindelijke hoeveelheid alcohol volume %.' });
 	$('#package_abv').jqxNumberInput( Show1dec );
 	$("#st_carb_min2").jqxTooltip({ content: 'Het minimum aanbevolen koolzuur volume voor deze bierstijl.'});
-	$("#st_carb_min2").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_carb_min2").jqxNumberInput(Smal1dec);
 	$("#st_carb_max2").jqxTooltip({ content: 'Het maximum aamnevolen koolzuur volume voor deze bierstijl.'});
-	$("#st_carb_max2").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_carb_max2").jqxNumberInput(Smal1dec);
 	$("#bottle_amount").jqxTooltip({ content: 'De totale hoeveelheid te bottelen bier.' });
 	$("#bottle_amount").jqxNumberInput( Spin1dec );
 	$("#keg_amount").jqxTooltip({ content: 'De totale hoeveelheid op fust te zetten bier.' });
--- a/www/js/rec_edit.js	Thu Jun 20 22:16:05 2019 +0200
+++ b/www/js/rec_edit.js	Fri Jun 21 16:55:36 2019 +0200
@@ -271,6 +271,7 @@
 		dataRecord.est_og = estimate_sg(sugarsf + addedS, parseFloat(dataRecord.batch_size));
 		$('#est_og').val(dataRecord.est_og);
 		$('#est_og2').val(dataRecord.est_og);
+		var org = dataRecord.est_og;
 
 		// Estimate SG in kettle before boil
 		preboil_sg = estimate_sg(sugarsm, parseFloat(dataRecord.boil_size));
@@ -318,10 +319,16 @@
 		}
 		$('#est_fg').val(dataRecord.est_fg);
 		$('#est_fg2').val(dataRecord.est_fg);
+		var fig = dataRecord.est_fg;
 
 		dataRecord.est_abv = abvol(dataRecord.est_og, dataRecord.est_fg);
 		$("#est_abv").val(dataRecord.est_abv);
 		$("#est_abv2").val(dataRecord.est_abv);
+
+		// Calculate the calories in kcal/l (from brouwhulp)
+		var alc = 1881.22 * fig * (org - fig) / (1.775 - org);
+		var sug = 3550 * fig * (0.1808 * org + 0.8192 * fig - 1.0004);
+		$("#kcal").val(Math.round((alc + sug) / (12 * 0.0295735296)));
 	};
 
 	function hopFlavourContribution(bt, vol, use, amount) {
@@ -2809,13 +2816,13 @@
 	$("#st_name").jqxTooltip({ content: 'De bierstijl naam voor dit recept.'});
 	$("#st_name").jqxInput({ theme: theme, width: 250, height: 23 });
 	$("#st_letter").jqxTooltip({ content: 'De bierstijl letter voor dit recept.'});
-	$("#st_letter").jqxInput({ theme: theme, width: 100, height: 23 });
+	$("#st_letter").jqxInput({ theme: theme, width: 90, height: 23 });
 	$("#st_guide").jqxTooltip({ content: 'De bierstijl gids voor dit recept.'});
 	$("#st_guide").jqxInput({ theme: theme, width: 250, height: 23 });
 	$("#st_category").jqxTooltip({ content: 'De Amerikaanse bierstijl categorie.'});
 	$("#st_category").jqxInput({ theme: theme, width: 250, height: 23 });
 	$("#st_category_number").jqxTooltip({ content: 'De Amerikaanse bierstijl categorie sub nummer.'});
-	$("#st_category_number").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_category_number").jqxNumberInput( Smal0dec );
 	$("#st_type").jqxTooltip({ content: 'Het bierstijl type.'});
 	$("#st_type").jqxInput({ theme: theme, width: 250, height: 23 });
 
@@ -2834,18 +2841,18 @@
 	$("#st_fg_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 3, readOnly: true });
 
 	$("#est_abv").jqxTooltip({ content: 'Alcohol volume %. Dit wordt automatisch berekend.' });
-	$("#est_abv").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#est_abv").jqxNumberInput( Smal1dec );
 	$("#st_abv_min").jqxTooltip({ content: 'Het minimum alcohol volume % voor deze bierstijl.'});
-	$("#st_abv_min").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_abv_min").jqxNumberInput( Smal1dec );
 	$("#st_abv_max").jqxTooltip({ content: 'Het maximum alcohol volume % voor deze bierstijl.'});
-	$("#st_abv_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_abv_max").jqxNumberInput( Smal1dec );
 
 	$("#est_color").jqxTooltip({ content: 'De kleur in EBC. Dit wordt automatisch berekend.' });
 	$("#est_color").jqxNumberInput( Show0dec );
 	$("#st_color_min").jqxTooltip({ content: 'De minimum kleur voor deze bierstijl.'});
-	$("#st_color_min").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_color_min").jqxNumberInput( Smal0dec );
 	$("#st_color_max").jqxTooltip({ content: 'De maximum kleur voor deze bierstijl.'});
-	$("#st_color_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_color_max").jqxNumberInput( Smal0dec );
 	$("#color_method").jqxDropDownList({
 		theme: theme,
 		source: ColorMethodAdapter,
@@ -2855,13 +2862,12 @@
 		height: 23,
 		autoDropDownHeight: true
 	});
-
 	$("#est_ibu").jqxTooltip({ content: 'De bitterheid in IBU. Dit wordt automatisch berekend.' });
 	$("#est_ibu").jqxNumberInput( Show0dec );
 	$("#st_ibu_min").jqxTooltip({ content: 'De minimum bitterheid voor deze bierstijl.'});
-	$("#st_ibu_min").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_ibu_min").jqxNumberInput( Smal0dec );
 	$("#st_ibu_max").jqxTooltip({ content: 'De maximum bitterheid voor deze bierstijl.'});
-	$("#st_ibu_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#st_ibu_max").jqxNumberInput( Smal0dec );
 	$("#ibu_method").jqxDropDownList({
 		theme: theme,
 		source: IBUmethodAdapter,
@@ -2872,13 +2878,14 @@
 		autoDropDownHeight: true,
 		dropDownVerticalAlignment: 'top'
 	});
-
+	$("#kcal").jqxTooltip({ content: 'Energie-inhoud in kcal/liter.' });
+	$("#kcal").jqxNumberInput( Smal0dec );
 	$("#est_carb").jqxTooltip({ content: 'Koolzuur volume. Dit wordt automatisch berekend.' });
-	$("#est_carb").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#est_carb").jqxNumberInput( Smal1dec );
 	$("#st_carb_min").jqxTooltip({ content: 'Het minimum koolzuur volume voor deze bierstijl.'});
-	$("#st_carb_min").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_carb_min").jqxNumberInput( Smal1dec );
 	$("#st_carb_max").jqxTooltip({ content: 'Het maximum koolzuur volume voor deze bierstijl.'});
-	$("#st_carb_max").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#st_carb_max").jqxNumberInput( Smal1dec );
 
 	// Tab 2, Vergistbaar
 	$("#est_color2").jqxTooltip({ content: 'De kleur in EBC. Dit wordt automatisch berekend.' });
@@ -3163,7 +3170,7 @@
 
 	// Tab 3, Hoppen
 	$("#est_ibu2").jqxTooltip({ content: 'De bitterheid in IBU. Dit wordt automatisch berekend.' });
-	$("#est_ibu2").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 0, readOnly: true });
+	$("#est_ibu2").jqxNumberInput( Smal0dec );
 	$("#hop_flavour").jqxProgressBar({
 		width: 300,
 		height: 23,
@@ -3480,7 +3487,7 @@
 	$("#est_fg2").jqxTooltip({ content: 'Het eind SG. Dit wordt automatisch berekend.' });
 	$("#est_fg2").jqxNumberInput( Show3dec );
 	$("#est_abv2").jqxTooltip({ content: 'Alcohol volume %. Dit wordt automatisch berekend.' });
-	$("#est_abv2").jqxNumberInput({ inputMode: 'simple', theme: theme, width: 50, height: 23, decimalDigits: 1, readOnly: true });
+	$("#est_abv2").jqxNumberInput( Smal1dec );
 	$("#popupYeast").jqxWindow({
 		width: 800,
 		height: 300,
--- a/www/prod_edit.php	Thu Jun 20 22:16:05 2019 +0200
+++ b/www/prod_edit.php	Fri Jun 21 16:55:36 2019 +0200
@@ -86,7 +86,7 @@
         <td style="padding: 3px;"><div style="float: left;" id="est_og"></div><div style="float: left; margin-left: 15px;" id="st_og_min"></div><div style="float: left; margin-left: 5px;" id="st_og_max"></div></td>
         <td style="vertical-align: top; float: right; padding: 3px;">Eind SG:</td>
         <td style="padding: 3px;"><div style="float: left;" id="est_fg"></div><div style="float: left; margin-left: 15px;" id="st_fg_min"></div><div style="float: left; margin-left: 5px;" id="st_fg_max"></div></td>
-        <td style="vertical-align: top; float: right; padding: 3px;">Alcohol vol%:</td>
+        <td style="vertical-align: top; float: right; padding: 3px;">Alcohol vol.%:</td>
         <td style="padding: 3px;"><div style="float: left;" id="est_abv"></div><div style="float: left; margin-left: 15px;" id="st_abv_min"></div><div style="float: left; margin-left: 5px;" id="st_abv_max"></div></td>
        </tr>
        <tr>
@@ -102,8 +102,8 @@
         <td style="padding: 3px;"><div style="float: left;" id="est_ibu"></div><div style="float: left; margin-left: 15px;" id="st_ibu_min"></div><div style="float: left; margin-left: 5px;" id="st_ibu_max"></div></td>
         <td style="vertical-align: top; float: right; padding: 3px;">Bitterheid methode:</td>
         <td style="padding: 3px;"><div style="float: left;" id="ibu_method"></div></td>
-        <td></td>
-        <td></td>
+        <td style="vertical-align: top; float: right; padding: 3px;">Energie-inhoud kcal/l:</td>
+        <td style="padding: 3px;"><div style="float: left;" id="kcal"></div></div></td>
        </tr>
       </table>
       <div style="float: right; margin-top: 20px; margin-bottom: 5px;">
@@ -708,7 +708,7 @@
         <td align="left" style="vertical-align: top;"><div id="final_brix"></div></td>
        </tr>
        <tr>
-        <td style="vertical-align: top; float: right; padding: 3px;">Alcohol percentage voor hergisting:</td>
+        <td style="vertical-align: top; float: right; padding: 3px;">Alcoholgehalte voor hergisting vol.%:</td>
         <td align="left" style="vertical-align: top;"><div id="final_abv"></div></td>
         <td style="vertical-align: top; float: right; padding: 3px;">Schijnbare vergistingsgraad %:</td>
         <td align="left" style="vertical-align: top;"><div id="final_svg"></div></td>
@@ -750,7 +750,7 @@
         <td align="left" colspan="3" style="vertical-align: top; padding: 3px;"><input id="package_infuse_notes" /></td>
        </tr>
        <tr>
-        <td style="vertical-align: top; float: right; padding: 3px;">Finaal alcohol %:</td>
+        <td style="vertical-align: top; float: right; padding: 3px;">Alcoholgehalte vol.%:</td>
         <td align="left" colspan="3" style="vertical-align: top;"><div id="package_abv"></div></td>
        </tr>
        <tr>
@@ -808,9 +808,9 @@
         <td align="left" style="vertical-align: top;"><div id="keg_pressure"></div></td>
        </tr>
        <tr>
-        <td style="vertical-align: top; float: right; padding: 3px;">Alcohol op fles:</td>
+        <td style="vertical-align: top; float: right; padding: 3px;">Alcoholgehalte flessen vol.%:</td>
         <td align="left" style="vertical-align: top;"><div id="bottle_abv"></div></td>
-        <td style="vertical-align: top; float: right; padding: 3px;">Alcohol op fust:</td>
+        <td style="vertical-align: top; float: right; padding: 3px;">Alcoholgehalte fusten vol.%:</td>
         <td align="left" style="vertical-align: top;"><div id="keg_abv"></div></td>
        </tr>
        <tr>
--- a/www/rec_edit.php	Thu Jun 20 22:16:05 2019 +0200
+++ b/www/rec_edit.php	Fri Jun 21 16:55:36 2019 +0200
@@ -32,7 +32,7 @@
         <tr>
 	 <td style="vertical-align: top; float: right; padding: 3px;">Brouw type:</td>
 	 <td align="left" style="padding: 3px;"><div id="type"></div></td>
-         <td style="vertical-align: top; float: right; padding: 3px;">Brouwzaal rendement %:</td>
+         <td style="vertical-align: top; float: right; padding: 3px;">Brouwzaal rendement:</td>
          <td colspan="3" style="padding: 3px;"><div id="efficiency"></div></td>
         </tr>
         <tr>
@@ -73,7 +73,7 @@
          <td style="padding: 3px;"><div style="float: left;" id="est_og"></div><div style="float: left; margin-left: 15px;" id="st_og_min"></div><div style="float: left; margin-left: 5px;" id="st_og_max"></div></td>
          <td style="vertical-align: top; float: right; padding: 3px;">Verwacht eind SG:</td>
 	 <td style="padding: 3px;"><div style="float: left;" id="est_fg"></div><div style="float: left; margin-left: 15px;" id="st_fg_min"></div><div style="float: left; margin-left: 5px;" id="st_fg_max"></div></td>
-         <td style="vertical-align: top; float: right; padding: 3px;">Alcohol vol%:</td>
+         <td style="vertical-align: top; float: right; padding: 3px;">Alcohol vol.%:</td>
          <td style="padding: 3px;"><div style="float: left;" id="est_abv"></div><div style="float: left; margin-left: 15px;" id="st_abv_min"></div><div style="float: left; margin-left: 5px;" id="st_abv_max"></div></td>
 	</tr>
         <tr>
@@ -89,8 +89,8 @@
          <td style="padding: 3px;"><div style="float: left;" id="est_ibu"></div><div style="float: left; margin-left: 35px;" id="st_ibu_min"></div><div style="float: left; margin-left: 5px;" id="st_ibu_max"></div></td>
          <td style="vertical-align: top; float: right; padding: 3px;">Bitterheid methode:</td>
          <td style="padding: 3px;"><div style="float: left;" id="ibu_method"></div></td>
-         <td></td>
-         <td></td>
+         <td style="vertical-align: top; float: right; padding: 3px;">Energie-inhoud kcal/l:</td>
+         <td style="padding: 3px;"><div style="float: left;" id="kcal"></div></div></td>
         </tr>
        </table>
        <div style="float: right; margin-top: 30px; margin-bottom: 10px;">

mercurial