Disable taste entries only after the product is locked.

Mon, 04 Mar 2019 11:40:33 +0100

author
Michiel Broek <mbroek@mbse.eu>
date
Mon, 04 Mar 2019 11:40:33 +0100
changeset 315
0df8d2db55fb
parent 314
f943efa07d9f
child 316
82c3bb9a40c2

Disable taste entries only after the product is locked.

www/js/prod_edit.js file | annotate | diff | comparison | revisions
--- a/www/js/prod_edit.js	Mon Mar 04 11:05:26 2019 +0100
+++ b/www/js/prod_edit.js	Mon Mar 04 11:40:33 2019 +0100
@@ -1880,7 +1880,7 @@
 			$('#jqxTabs').jqxTabs('enableAt', 11);
 		}
 
-		if (dataRecord.stage > 9) { // Tasted
+		if (dataRecord.stage == 11) { // Locked
 			$("#taste_date").jqxDateTimeInput({ disabled: true });
 			$("#taste_rate").jqxNumberInput({ spinButtons: false, readOnly: true, width: 90 });
 			$("#taste_color").jqxInput({ disabled: true });
@@ -1891,9 +1891,6 @@
 			$("#taste_aftertaste").jqxInput({ disabled: true });
 			$("#taste_mouthfeel").jqxInput({ disabled: true });
 			$("#taste_notes").jqxInput({ disabled: true });
-		}
-
-		if (dataRecord.stage == 11) { // Locked
 			$("#notes").jqxInput({ disabled: true });
 		} else {
 			$("#notes").jqxInput({ disabled: false });

mercurial