3 "name": "Pman.Tab.XtupleApAging",
4 "parent": "Pman.Tab.XtupleAccountsTab",
6 "path": "/home/edward/gitlive/web.xtuple/Pman/Xtuple/Pman.Tab.XtupleApAging.bjs",
13 "title": "Accounts Payable",
14 "xtype": "NestedLayoutPanel",
19 "xtype": "BorderLayout",
24 "xtype": "LayoutRegion",
29 "|activate": "function() {\n _this.panel = this;\n if (_this.grid) {\n _this.grid.footer.onClick('first');\n }\n}"
35 "tableName": "apopen",
42 "|render": "function() \n{\n _this.grid = this; \n //_this.dialog = Pman.Dialog.FILL_IN\n if (_this.panel.active) {\n this.footer.onClick('first');\n }\n}"
45 "autoExpandColumn": "araging_cust_name",
52 "beforeload": "function (_self, o)\n{\n o.params = o.params || {};\n \n\n \n var dt = _this.relDate.getValue();\n \n var params = {\n _group : 'apAging',\n _name : 'bydate',\n 'relDate:text' : typeof(dt) == 'string' ? dt : dt.format('Y-m-d'),\n 'useDocDate:text' : false\n };\n \n var cs = _this.customerSel.getValue();\n if (cs*1) {\n params['cust_id:number'] = cs;\n \n }\n \n \n Roo.apply(o.params,params);\n}"
54 "*prop": "dataSource",
64 "|url": "baseURL + '/Roo/Metasql.php'",
71 "totalProperty": "total",
72 "xtype": "JsonReader",
73 "|fields": "[\n {\n 'name': 'apaging_doctype',\n 'type': 'string'\n }\n]",
85 "render": "function (_self)\n{\n _this.customerSel = _self;\n}",
86 "select": "function (combo, record, index)\n{\n _this.grid.footer.onClick('first');\n}"
89 "displayField": "cust_name",
91 "emptyText": "Select customer",
92 "fieldLabel": "cust_name",
93 "forceSelection": true,
94 "hiddenName": "cust_id",
96 "loadingText": "Searching...",
100 "qtip": "Select Customer",
101 "queryParam": "cust_name:text",
102 "selectOnFocus": true,
103 "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{cust_name}</b> </div>",
104 "triggerAction": "all",
106 "valueField": "cust_id",
113 "|beforeload": "function (_self, o){\n o.params = o.params || {};\n\n if (!_this.relDate) {\n return false;\n }\n var dt = _this.relDate.getValue(); \n // set more here\n o.params['_group'] = 'apAging';\n o.params['_name'] = 'customers';\n o.params['relDate:text'] = typeof(dt) == 'string' ? dt : dt.format('Y-m-d');\n o.params['useDocDate:text'] = false \n}\n"
118 "|sortInfo": "{ direction : 'ASC', field: 'cust_name' }",
124 "xtype": "HttpProxy",
125 "|url": "baseURL + '/Roo/metasql.php'",
130 "xtype": "JsonReader",
134 "totalProperty": "total",
135 "|fields": "[{\"name\":\"cust_id\",\"type\":\"int\"},\"cust_name\"]"
144 "|xns": "Roo.Toolbar"
148 "render": "function (_self)\r\n{\r\n _this.relDate = _self;\r\n _self.setValue( new Date() );\r\n}",
149 "select": "function (combo, date)\n{\n _this.grid.footer.onClick('first');\n}"
154 "xtype": "DateField",
162 "displayMsg": "Displaying araging{0} - {1} of {2}",
163 "emptyMsg": "Nothing found",
165 "xtype": "PagingToolbar",
169 "*prop": "colModel[]",
170 "dataIndex": "apaging_docdate",
173 "xtype": "ColumnModel",
174 "|renderer": "function(v) { \n var d = Date.parseDate(v, 'Y-m-d');\n\n return String.format('{0}', d.format('d/M/Y')); \n}",
178 "*prop": "colModel[]",
179 "dataIndex": "apaging_vend_name",
182 "xtype": "ColumnModel",
183 "|renderer": "function(v) { return String.format('{0}', v); }",
187 "*prop": "colModel[]",
188 "dataIndex": "apaging_doctype",
189 "header": "Doc Type",
191 "xtype": "ColumnModel",
192 "|renderer": "function(v) {\n switch(v) {\n case 'I':\n return \"Invoice\";\n case 'C':\n return \"Credit Memo\"; \n case 'D':\n return \"Debit Memo\"; \n case 'R':\n return \"Cash Receipt\"; \n default:\n return String.format('{0}', v); \n }\n }",
196 "*prop": "colModel[]",
197 "dataIndex": "apaging_docnumber",
198 "header": "Docnumber",
200 "xtype": "ColumnModel",
201 "|renderer": "function(v) {\n \n return String.format('{0}', v); \n \n }",
205 "*prop": "colModel[]",
206 "dataIndex": "araging_curr_symbol",
207 "header": "Currency",
209 "xtype": "ColumnModel",
210 "|renderer": "function(v) {\n \n return String.format('{0}', v); \n \n }",
214 "*prop": "colModel[]",
216 "dataIndex": "apaging_aropen_amount",
219 "xtype": "ColumnModel",
220 "|renderer": "function(v) { \n\n return String.format(v*1 < 0 ? '<span style=\"color:red\">{0}</span>' : '{0}', \n Roo.util.Format.usMoney(v)); \n }",
224 "*prop": "colModel[]",
226 "dataIndex": "araging_cur_val",
229 "xtype": "ColumnModel",
230 "|renderer": "function(v) { \n\n return String.format(v*1 < 0 ? '<span style=\"color:red\">{0}</span>' : '{0}', \n Roo.util.Format.usMoney(v)); \n }",
234 "*prop": "colModel[]",
236 "dataIndex": "araging_sixty_val",
239 "xtype": "ColumnModel",
240 "|renderer": "function(v) { \n\n return String.format(v*1 < 0 ? '<span style=\"color:red\">{0}</span>' : '{0}', \n Roo.util.Format.usMoney(v)); \n }",
244 "*prop": "colModel[]",
246 "dataIndex": "araging_ninety_val",
249 "xtype": "ColumnModel",
250 "|renderer": "function(v) { \n\n return String.format(v*1 < 0 ? '<span style=\"color:red\">{0}</span>' : '{0}', \n Roo.util.Format.usMoney(v)); \n }",
254 "*prop": "colModel[]",
256 "dataIndex": "araging_plus_val",
257 "header": "Over 90 days",
259 "xtype": "ColumnModel",
260 "|renderer": "function(v) { \n\n return String.format(v*1 < 0 ? '<span style=\"color:red\">{0}</span>' : '{0}', \n Roo.util.Format.usMoney(v)); \n }",
264 "*prop": "colModel[]",
266 "dataIndex": "araging_total_val",
269 "xtype": "ColumnModel",
270 "|renderer": "function(v) { \n\n return String.format(v*1 < 0 ? '<span style=\"color:red\">{0}</span>' : '{0}', \n Roo.util.Format.usMoney(v)); \n }",
274 "*prop": "colModel[]",
276 "dataIndex": "araging_base_total",
277 "header": "Total (BASE)",
279 "xtype": "ColumnModel",
280 "|renderer": "function(v) { \n\n return String.format(v*1 < 0 ? '<span style=\"color:red\">{0}</span>' : '{0}', \n Roo.util.Format.usMoney(v)); \n }",