183 container = $('<div style="overflow: hidden; position: relative; margin: 5px;"></div>'); |
183 container = $('<div style="overflow: hidden; position: relative; margin: 5px;"></div>'); |
184 addButton = $('<div style="float: right; margin-right: 15px;"><img style="position: relative; margin-top: 2px;" ' + |
184 addButton = $('<div style="float: right; margin-right: 15px;"><img style="position: relative; margin-top: 2px;" ' + |
185 'src="images/add.png"/><span style="margin-left: 4px; position: relative; top: -3px;">Nieuw</span></div>'); |
185 'src="images/add.png"/><span style="margin-left: 4px; position: relative; top: -3px;">Nieuw</span></div>'); |
186 impButton = $('<div style="float: right; margin-right: 50px;"><img style="position: relative; margin-top: 2px;" ' + |
186 impButton = $('<div style="float: right; margin-right: 50px;"><img style="position: relative; margin-top: 2px;" ' + |
187 'src="images/add.png"/><span style="margin-left: 4px; position: relative; top: -3px;">Import</span></div>'); |
187 'src="images/add.png"/><span style="margin-left: 4px; position: relative; top: -3px;">Import</span></div>'); |
|
188 expButton = $('<div style="float: right; margin-right: 50px;"><img style="position: relative; margin-top: 2px;" ' + |
|
189 'src="images/database.png"/><span style="margin-left: 4px; position: relative; top: -3px;">Export</span></div>'); |
188 container.append(addButton); |
190 container.append(addButton); |
189 container.append(impButton); |
191 container.append(impButton); |
|
192 container.append(expButton); |
190 statusbar.append(container); |
193 statusbar.append(container); |
191 addButton.jqxButton({ theme: theme, width: 90, height: 20 }); |
194 addButton.jqxButton({ theme: theme, width: 90, height: 20 }); |
192 impButton.jqxButton({ theme: theme, width: 90, height: 20 }); |
195 impButton.jqxButton({ theme: theme, width: 90, height: 20 }); |
|
196 expButton.jqxButton({ theme: theme, width: 90, height: 20 }); |
193 // add new row. |
197 // add new row. |
194 addButton.click(function(event) { |
198 addButton.click(function(event) { |
195 editrow = -1; |
199 editrow = -1; |
196 $('#popupWindow').jqxWindow({ position: { x: 110, y: 30 } }); |
200 $('#popupWindow').jqxWindow({ position: { x: 110, y: 30 } }); |
197 $('#name').val('Nieuwe hop'); |
201 $('#name').val('Nieuwe hop'); |
215 $('#total_oil').val(0); |
219 $('#total_oil').val(0); |
216 $('#popupWindow').jqxWindow('open'); |
220 $('#popupWindow').jqxWindow('open'); |
217 }); |
221 }); |
218 impButton.click(function(event) { |
222 impButton.click(function(event) { |
219 window.location.href = 'import_ingredients.php?select=hops'; |
223 window.location.href = 'import_ingredients.php?select=hops'; |
|
224 }); |
|
225 expButton.click(function(event) { |
|
226 window.open('export_hops.php'); |
220 }); |
227 }); |
221 }, |
228 }, |
222 filterable: true, |
229 filterable: true, |
223 filtermode: 'excel', |
230 filtermode: 'excel', |
224 columns: [ |
231 columns: [ |