comparison app/controller/grid/MessungList.js @ 1400:69ebd572fe5c release-2.5

Collapse rows on page change in probe and messung filter grid.
author Raimund Renkert <raimund.renkert@intevation.de>
date Thu, 16 Mar 2017 17:29:50 +0100
parents 056ffbc2790a
children
comparison
equal deleted inserted replaced
1399:78839fe4b9b7 1400:69ebd572fe5c
26 select: this.activateButtons, 26 select: this.activateButtons,
27 deselect: this.deactivateButtons 27 deselect: this.deactivateButtons
28 }, 28 },
29 'messunglistgrid toolbar button[action=setstatus]': { 29 'messunglistgrid toolbar button[action=setstatus]': {
30 click: this.setStatus 30 click: this.setStatus
31 },
32 'messunglistgrid pagingtoolbar': {
33 change: this.pageChange
31 } 34 }
32 }); 35 });
33 this.callParent(arguments); 36 this.callParent(arguments);
34 }, 37 },
35 38
295 298
296 reload: function(btn) { 299 reload: function(btn) {
297 if (btn === 'yes') { 300 if (btn === 'yes') {
298 location.reload(); 301 location.reload();
299 } 302 }
303 },
304
305 pageChange: function(toolbar) {
306 var grid = toolbar.up('grid');
307 var store = grid.getStore();
308 var rowExpander = grid.plugins[0]
309 var nodes = rowExpander.view.getNodes();
310 for (var i = 0; i < nodes.length; i++) {
311 var node = Ext.fly(nodes[i]);
312 if (node.hasCls(rowExpander.rowCollapsedCls) === false) {
313 rowExpander.toggleRow(i, store.getAt(i));
314 }
315 }
300 } 316 }
301 }); 317 });

http://lada.wald.intevation.org