176 theme: theme, |
176 theme: theme, |
177 showstatusbar: true, |
177 showstatusbar: true, |
178 renderstatusbar: function (statusbar) { |
178 renderstatusbar: function (statusbar) { |
179 var container = $("<div style='overflow: hidden; position: relative; margin: 5px;'></div>"); |
179 var container = $("<div style='overflow: hidden; position: relative; margin: 5px;'></div>"); |
180 var addButton = $("<div style='float: right; margin-right: 15px;'><img style='position: relative; margin-top: 2px;' src='images/add.png'/><span style='margin-left: 4px; position: relative; top: -3px;'>Nieuw</span></div>"); |
180 var addButton = $("<div style='float: right; margin-right: 15px;'><img style='position: relative; margin-top: 2px;' src='images/add.png'/><span style='margin-left: 4px; position: relative; top: -3px;'>Nieuw</span></div>"); |
|
181 var impButton = $("<div style='float: right; margin-right: 50px;'><img style='position: relative; margin-top: 2px;' src='images/add.png'/><span style='margin-left: 4px; position: relative; top: -3px;'>Import</span></div>"); |
181 container.append(addButton); |
182 container.append(addButton); |
|
183 container.append(impButton); |
182 statusbar.append(container); |
184 statusbar.append(container); |
183 addButton.jqxButton({ theme: theme, width: 90, height: 20 }); |
185 addButton.jqxButton({ theme: theme, width: 90, height: 20 }); |
|
186 impButton.jqxButton({ theme: theme, width: 90, height: 20 }); |
184 // add new row. |
187 // add new row. |
185 addButton.click(function (event) { |
188 addButton.click(function (event) { |
186 editrow = -1; |
189 editrow = -1; |
187 $("#popupWindow").jqxWindow({ position: { x: 110, y: 30 } }); |
190 $("#popupWindow").jqxWindow({ position: { x: 110, y: 30 } }); |
188 $("#name").val(''); |
191 $("#name").val(''); |
196 $("#inventory").val(0); |
199 $("#inventory").val(0); |
197 $("#cost").val(0); |
200 $("#cost").val(0); |
198 $("#production_date").val(''); |
201 $("#production_date").val(''); |
199 $("#tht_date").val(''); |
202 $("#tht_date").val(''); |
200 $("#popupWindow").jqxWindow('open'); |
203 $("#popupWindow").jqxWindow('open'); |
|
204 }); |
|
205 impButton.click(function (event) { |
|
206 var url="import_ingredients.php?select=miscs"; |
|
207 window.location.href = url; |
201 }); |
208 }); |
202 }, |
209 }, |
203 filterable: true, |
210 filterable: true, |
204 filtermode: 'excel', |
211 filtermode: 'excel', |
205 columns: [ |
212 columns: [ |