[Tree extension] fixed other grid empty messages
authorAsier Lostalé <asier.lostale@openbravo.com>
Fri, 28 Feb 2014 17:00:40 +0100
changeset 22603 c0aaef98a544
parent 22602 24c3740bae78
child 22605 3349386cdc71
[Tree extension] fixed other grid empty messages
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-tree-filter.js
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-tree.js
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-tree-filter.js	Fri Feb 28 16:41:58 2014 +0100
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-tree-filter.js	Fri Feb 28 17:00:40 2014 +0100
@@ -78,6 +78,7 @@
         OB.Datasource.get(this.dataSourceId, this, null, true);
         this.copyFunctionsFromViewGrid();
         this.Super('init', arguments);
+        this.filterNoRecordsEmptyMessage = '<span class="' + this.emptyMessageStyle + '">' + OB.I18N.getLabel('OBUIAPP_GridFilterNoResults') + '</span>' + '<span onclick="window[\'' + this.ID + '\'].clearFilter();" class="' + this.emptyMessageLinkStyle + '">' + OB.I18N.getLabel('OBUIAPP_GridClearFilter') + '</span>';
       },
 
       copyFunctionsFromViewGrid: function () {
@@ -92,7 +93,6 @@
         this.loadingDataMessage = this.view.viewGrid.loadingDataMessage;
         this.emptyMessage = this.view.viewGrid.emptyMessage;
         this.noDataEmptyMessage = this.view.viewGrid.noDataEmptyMessage;
-        this.filterNoRecordsEmptyMessage = this.view.viewGrid.filterNoRecordsEmptyMessage;
       },
 
       onFetchData: function (criteria, requestProperties) {
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-tree.js	Fri Feb 28 16:41:58 2014 +0100
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-tree.js	Fri Feb 28 17:00:40 2014 +0100
@@ -409,6 +409,8 @@
         OB.Datasource.get(this.treeItem.dataSourceId, this, null, true);
         this.copyFunctionsFromViewGrid();
         this.Super('init', arguments);
+        this.filterNoRecordsEmptyMessage = '<span class="' + this.emptyMessageStyle + '">' + OB.I18N.getLabel('OBUIAPP_GridFilterNoResults') + '</span>' + '<span onclick="window[\'' + this.ID + '\'].clearFilter();" class="' + this.emptyMessageLinkStyle + '">' + OB.I18N.getLabel('OBUIAPP_GridClearFilter') + '</span>';
+        this.emptyMessage = this.filterNoRecordsEmptyMessage;
       },
 
       copyFunctionsFromViewGrid: function () {
@@ -421,9 +423,7 @@
         this.resetEmptyMessage = view.viewGrid.resetEmptyMessage;
         this.filterData = view.viewGrid.filterData;
         this.loadingDataMessage = view.viewGrid.loadingDataMessage;
-        this.emptyMessage = view.viewGrid.emptyMessage;
         this.noDataEmptyMessage = view.viewGrid.noDataEmptyMessage;
-        this.filterNoRecordsEmptyMessage = view.viewGrid.filterNoRecordsEmptyMessage;
       },
 
       convertCriteria: function (criteria) {