[Tree extension] force refresh when moving to tree view
authorAsier Lostalé <asier.lostale@openbravo.com>
Fri, 28 Feb 2014 12:23:46 +0100
changeset 22594 56250da17af1
parent 22593 469384f8bd93
child 22595 33670bdfa484
[Tree extension] force refresh when moving to tree view
this forces new/modified records to be reloaded
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-toolbar.js
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-toolbar.js	Fri Feb 28 11:59:21 2014 +0100
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-toolbar.js	Fri Feb 28 12:23:46 2014 +0100
@@ -1731,6 +1731,7 @@
     view.isShowingTree = false;
   } else {
     treeGrid.copyCriteriaFromViewGrid();
+    treeGrid.setData([]); // forcing refresh
     treeGrid.fetchData(treeGrid.getCriteria());
     treeGrid.checkShowFilterFunnelIcon(treeGrid.getCriteria());
     treeGrid.show();