BUG-15020 Pagination toolbar is not refreshing when when... SOLVED

- The search was done locally.
- the criteria was added in order to make the search by filename and user.
This commit is contained in:
Marco Antonio Nina
2014-05-23 10:53:38 -04:00
parent b5e9beefa2
commit bc3a75c852
3 changed files with 89 additions and 15 deletions

View File

@@ -1151,19 +1151,18 @@ var gridtb = new Ext.Toolbar(
}), new Ext.Toolbar.Button({
text : ' X ',
handler : function() {
datastore.clearFilter();
Ext.getCmp("filterField").setValue("");
datastore.clearFilter();
Ext.getCmp("filterField").setValue("");
datastore.setBaseParam( 'search', '');
datastore.load({params:{ start : 0 , limit : 100 }});
}
})
]);
function filterDataStore(btn, e) {
var filterVal = Ext.getCmp("filterField").getValue();
if (filterVal.length > 1) {
datastore.filter('name', eval('/' + filterVal + '/gi'));
} else {
datastore.clearFilter();
}
var filterVal = Ext.getCmp("filterField").getValue();
datastore.setBaseParam( 'search', filterVal);
datastore.load({params:{ start : 0 , limit : 100 }});
}
// add a paging toolbar to the grid's footer
var gridbb = new Ext.PagingToolbar({