From: Alan Knowles Date: Wed, 28 Sep 2011 07:30:04 +0000 (+0800) Subject: Pman.Tab.AdminWatches.bjs X-Git-Url: http://git.roojs.org/?p=Pman.Admin;a=commitdiff_plain;h=46d4947a15fcdf6a9d43c452b3698ab6806a4281 Pman.Tab.AdminWatches.bjs Pman.Tab.AdminWatches.bjs Pman.Tab.AdminWatches.js Pman.Tab.AdminWatches.js --- diff --git a/Pman.Tab.AdminWatches.bjs b/Pman.Tab.AdminWatches.bjs index f5d40a6..1aa3e25 100644 --- a/Pman.Tab.AdminWatches.bjs +++ b/Pman.Tab.AdminWatches.bjs @@ -30,9 +30,12 @@ "|xns": "Roo.grid", "items": [ { + "listeners": { + "beforeload": "function (_self, options)\n{\n var val = _this.affectSel.getValue();\n if (val.length) {\n options.params.ontable = val;\n }\n \n}" + }, "*prop": "dataSource", - "xtype": "Store", "remoteSort": true, + "xtype": "Store", "|sortInfo": "{ field : 'ontable', direction: 'ASC' }", "|xns": "Roo.data", "items": [ diff --git a/Pman.Tab.AdminWatches.js b/Pman.Tab.AdminWatches.js index 5b9df23..70821a8 100644 --- a/Pman.Tab.AdminWatches.js +++ b/Pman.Tab.AdminWatches.js @@ -72,6 +72,16 @@ Pman.Tab.AdminWatches = new Roo.util.Observable({ dataSource : { xtype: 'Store', xns: Roo.data, + listeners : { + beforeload : function (_self, options) + { + var val = _this.affectSel.getValue(); + if (val.length) { + options.params.ontable = val; + } + + } + }, remoteSort : true, sortInfo : { field : 'ontable', direction: 'ASC' }, proxy : {