开发者

ExtJS Grid PagingToolbar refresh on store remove

开发者 https://www.devze.com 2023-01-20 18:47 出处:网络
I\'ve setup a ExtJS Grid, while using the Paging开发者_StackOverflowToolbar (with PagingMemoryProxy on an ArrayStore).

I've setup a ExtJS Grid, while using the Paging开发者_StackOverflowToolbar (with PagingMemoryProxy on an ArrayStore).

I have removed items from the store of the grid, but the PagingToolbar will not show that the items have been removed.

Any suggestions on how to do this?


Try unbinding and rebinding the store when you modify the items.

myGrid.store.on('remove', function() {
  var pager = myGrid.getBottomToolbar();
  if (pager) {
    pager.unbind(myGrid.store);
    pager.bind(myGrid.store);
  }
});
0

精彩评论

暂无评论...
验证码 换一张
取 消