Pman.Tab.XtupleMetric.bjs
authorEdward <edward@roojs.com>
Tue, 5 Aug 2014 05:21:26 +0000 (13:21 +0800)
committerEdward <edward@roojs.com>
Tue, 5 Aug 2014 05:21:26 +0000 (13:21 +0800)
Pman.Tab.XtupleMetric.js

Pman.Tab.XtupleMetric.bjs
Pman.Tab.XtupleMetric.js

index 810b9bb..cc9caef 100644 (file)
@@ -32,7 +32,7 @@
                     "items": [
                         {
                             "listeners": {
-                                "beforeload": "function (_self, o){\n    o.params = o.params || {};\n    \n}\n"
+                                "beforeload": "function (_self, o){\n    o.params = o.params || {};\n    \n    var s = _this.searchBox.getValue();\n    \n    if(!s || !s.length){\n        return;\n    }\n    \n    o.params['search[name]'] = s;\n}\n"
                             },
                             "*prop": "dataSource",
                             "remoteSort": true,
index dc530b4..43003c8 100644 (file)
@@ -71,6 +71,13 @@ Pman.Tab.XtupleMetric = new Roo.XComponent({
                         beforeload : function (_self, o){
                             o.params = o.params || {};
                             
+                            var s = _this.searchBox.getValue();
+                            
+                            if(!s || !s.length){
+                                return;
+                            }
+                            
+                            o.params['search[name]'] = s;
                         }
                     },
                     remoteSort : true,