diff -r 89b7449d1fd9 -r 3ce3df681be0 www/js/profile_fermentation.js
--- a/www/js/profile_fermentation.js Thu Jun 11 19:59:30 2020 +0200
+++ b/www/js/profile_fermentation.js Sat Jun 13 12:14:26 2020 +0200
@@ -79,9 +79,7 @@
commit(true);
location.reload(true);
},
- error: function(jqXHR, textStatus, errorThrown) {
- commit(false);
- }
+ error: function(jqXHR, textStatus, errorThrown) { commit(false); }
});
},
addrow: function(rowid, rowdata, position, commit) {
@@ -96,9 +94,7 @@
commit(true);
location.reload(true);
},
- error: function(jqXHR, textStatus, errorThrown) {
- commit(false);
- }
+ error: function(jqXHR, textStatus, errorThrown) { commit(false); }
});
},
updaterow: function(rowid, rowdata, commit) {
@@ -113,9 +109,7 @@
commit(true);
location.reload(true);
},
- error: function(jqXHR, textStatus, errorThrown) {
- commit(false);
- }
+ error: function(jqXHR, textStatus, errorThrown) { commit(false); }
});
}
},
@@ -228,6 +222,9 @@
$('#inittemp_hi').jqxNumberInput({ max: 45 });
$('#fridgemode').jqxCheckBox({ theme: theme, height: 23, enableContainerClick: false });
+ var localizationobj = {};
+ localizationobj.filterchoosestring= "Keuze:";
+
// initialize jqxGrid
$('#jqxgrid').jqxGrid({
width: 1280,
@@ -238,10 +235,10 @@
renderstatusbar: function(statusbar) {
var container = $('
');
var addButton = $('Nieuw ');
+ 'src="images/add.png"/>Nieuw');
container.append(addButton);
statusbar.append(container);
- addButton.jqxButton({ theme: theme, width: 90, height: 20 });
+ addButton.jqxButton({ theme: theme, width: 90, height: 17 });
// add new row.
addButton.click(function(event) {
editrow = -1;
@@ -256,12 +253,16 @@
$('#popupWindow').jqxWindow('open');
});
},
- filterable: false,
+ ready: function () {
+ $("#jqxgrid").jqxGrid('localizestrings', localizationobj);
+ },
+ filterable: true,
+ showfilterrow: true,
columns: [
- { text: 'Vergisting profiel', datafield: 'name' },
- { text: 'Min. start °C', datafield: 'inittemp_lo', width: 120, align: 'right', cellsalign: 'right', cellsformat: 'f1' },
- { text: 'Max. start °C', datafield: 'inittemp_hi', width: 120, align: 'right', cellsalign: 'right', cellsformat: 'f1' },
- { text: 'Sensor', datafield: 'fridgemode', align: 'right', width: 80,
+ { text: 'Vergisting profiel', datafield: 'name', filtertype: 'textbox' },
+ { text: 'Min. start °C', datafield: 'inittemp_lo', width: 120, align: 'right', cellsalign: 'right', cellsformat: 'f1', filtertype: 'number' },
+ { text: 'Max. start °C', datafield: 'inittemp_hi', width: 120, align: 'right', cellsalign: 'right', cellsformat: 'f1', filtertype: 'number' },
+ { text: 'Sensor', datafield: 'fridgemode', align: 'right', width: 80, filterable: false,
cellsrenderer: function(row, columnfield, value, defaulthtml, column) {
if (value == 0)
return 'Bier';
@@ -269,8 +270,8 @@
return 'Koelkast';
}
},
- { text: 'Stappen', datafield: 'totalsteps', width: 80, align: 'right', cellsalign: 'right' },
- { text: 'Tijdsduur', datafield: 'duration', width: 150, align: 'right',
+ { text: 'Stappen', datafield: 'totalsteps', width: 80, align: 'right', cellsalign: 'right', filterable: false },
+ { text: 'Tijdsduur', datafield: 'duration', width: 150, align: 'right', filterable: false,
cellsrenderer: function(row, columnfield, value, defaulthtml, column) {
var show, days, hours;
if (value < 24) {
@@ -286,7 +287,7 @@
return '' + show + '';
}
},
- { text: '', datafield: 'Edit', width: 100, align: 'center', columntype: 'button', cellsrenderer:
+ { text: '', datafield: 'Edit', width: 100, align: 'center', columntype: 'button', filterable: false, cellsrenderer:
function() {
return 'Wijzig';
}, buttonclick: function(row) {