Pman.Dialog.XtupleVendorEdit.bjs
[Pman.Xtuple] / Pman.Dialog.XtupleVendorEdit.bjs
1 {
2     "id": "roo-file-358",
3     "name": "Pman.Dialog.XtupleVendorEdit",
4     "parent": "",
5     "title": "",
6     "path": "/home/alan/gitlive/web.xtuple/Pman/Xtuple/Pman.Dialog.XtupleVendorEdit.bjs",
7     "items": [
8         {
9             "listeners": {
10                 "show": "function (_self)\n{\n    this.layout.getRegion('center').showPanel(0);\n}"
11             },
12             "closable": false,
13             "collapsible": false,
14             "height": 550,
15             "modal": true,
16             "resizable": false,
17             "title": "Edit / Create Vendor",
18             "width": 550,
19             "xtype": "LayoutDialog",
20             "|xns": "Roo",
21             "items": [
22                 {
23                     "*prop": "center",
24                     "tabPosition": "top",
25                     "xtype": "LayoutRegion",
26                     "|xns": "Roo"
27                 },
28                 {
29                     "region": "center",
30                     "xtype": "ContentPanel",
31                     "|xns": "Roo",
32                     "items": [
33                         {
34                             "listeners": {
35                                 "|actioncomplete": "function(_self,action)\n{\n    if (action.type == 'setdata') {\n        if(_this.data.vend_id){\n            _this.dialog.el.mask(\"Loading\");\n            this.load({ method: 'GET', params: { '_id' : _this.data.vend_id }});     \n        }\n       \n       return;\n    }\n    if (action.type == 'load') {\n        _this.data = action.result.data;\n        _this.form.findField('addr_view').sync();\n        _this.dialog.el.unmask();\n        return;\n    }\n    if (action.type =='submit') {\n    \n        _this.dialog.el.unmask();\n        _this.dialog.hide();\n    \n         if (_this.callback) {\n            _this.callback.call(_this, _this.form.getValues());\n         }\n         _this.form.reset();\n         return;\n    }\n}\n",
36                                 "|rendered": "function (form)\n{\n    _this.form= form;\n}\n"
37                             },
38                             "method": "POST",
39                             "style": "margin:10px;",
40                             "xtype": "Form",
41                             "|url": "baseURL + '/Roo/vendinfo.php'",
42                             "|xns": "Roo.form",
43                             "items": [
44                                 {
45                                     "legend": "Basic Details",
46                                     "style": "width:450px",
47                                     "xtype": "FieldSet",
48                                     "|xns": "Roo.form",
49                                     "items": [
50                                         {
51                                             "listeners": {
52                                                 "keyup": "function (_self, e)\n{\n    if (!(_this.form.findField('vend_id').getValue() * 1)) {\n    \n        _this.form.findField('vend_number').setValue(this.getValue().replace(/[^a-z0-9]/ig, '').toUpperCase());\n    \n    }\n}"
53                                             },
54                                             "allowBlank": false,
55                                             "fieldLabel": "Name",
56                                             "name": "vend_name",
57                                             "width": 200,
58                                             "xtype": "TextField",
59                                             "|xns": "Roo.form"
60                                         },
61                                         {
62                                             "allowBlank": false,
63                                             "fieldLabel": "Vendor #",
64                                             "name": "vend_number",
65                                             "readOnly": true,
66                                             "width": 200,
67                                             "xtype": "TextField",
68                                             "|xns": "Roo.form"
69                                         },
70                                         {
71                                             "allowBlank": true,
72                                             "fieldLabel": "Ship Via",
73                                             "name": "vend_shipvia",
74                                             "width": 200,
75                                             "xtype": "TextField",
76                                             "|xns": "Roo.form"
77                                         },
78                                         {
79                                             "allowBlank": false,
80                                             "alwaysQuery": true,
81                                             "displayField": "curr_symbol",
82                                             "editable": false,
83                                             "emptyText": "Select Currency",
84                                             "fieldLabel": "Currency",
85                                             "forceSelection": true,
86                                             "hiddenName": "vend_curr_id",
87                                             "listWidth": 400,
88                                             "loadingText": "Searching...",
89                                             "minChars": 2,
90                                             "name": "vend_curr_id_curr_symbol",
91                                             "pageSize": 20,
92                                             "qtip": "Select Currency",
93                                             "queryParam": "query[curr_symbol]",
94                                             "selectOnFocus": true,
95                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{curr_symbol}</b> </div>",
96                                             "triggerAction": "all",
97                                             "typeAhead": true,
98                                             "valueField": "curr_id",
99                                             "width": 200,
100                                             "xtype": "ComboBox",
101                                             "|xns": "Roo.form",
102                                             "items": [
103                                                 {
104                                                     "listeners": {
105                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n}\n"
106                                                     },
107                                                     "*prop": "store",
108                                                     "remoteSort": true,
109                                                     "xtype": "Store",
110                                                     "|sortInfo": "{ direction : 'ASC', field: 'curr_symbol' }",
111                                                     "|xns": "Roo.data",
112                                                     "items": [
113                                                         {
114                                                             "*prop": "proxy",
115                                                             "xtype": "HttpProxy",
116                                                             "method": "GET",
117                                                             "|xns": "Roo.data",
118                                                             "|url": "baseURL + '/Roo/curr_symbol.php'"
119                                                         },
120                                                         {
121                                                             "*prop": "reader",
122                                                             "xtype": "JsonReader",
123                                                             "|xns": "Roo.data",
124                                                             "id": "curr_id",
125                                                             "root": "data",
126                                                             "totalProperty": "total",
127                                                             "|fields": "[{\"name\":\"curr_id\",\"type\":\"int\"},\"curr_symbol\"]"
128                                                         }
129                                                     ]
130                                                 }
131                                             ]
132                                         },
133                                         {
134                                             "allowBlank": false,
135                                             "alwaysQuery": true,
136                                             "displayField": "terms_descrip",
137                                             "editable": false,
138                                             "emptyText": "Select Terms",
139                                             "fieldLabel": "Terms",
140                                             "forceSelection": true,
141                                             "hiddenName": "vend_terms_id",
142                                             "listWidth": 400,
143                                             "loadingText": "Searching...",
144                                             "minChars": 2,
145                                             "name": "vend_terms_id_terms_descrip",
146                                             "pageSize": 20,
147                                             "qtip": "Select Terms",
148                                             "queryParam": "query[terms_descrip]",
149                                             "selectOnFocus": true,
150                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{terms_descrip}</b> </div>",
151                                             "triggerAction": "all",
152                                             "typeAhead": true,
153                                             "valueField": "terms_id",
154                                             "width": 200,
155                                             "xtype": "ComboBox",
156                                             "|xns": "Roo.form",
157                                             "items": [
158                                                 {
159                                                     "listeners": {
160                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n}\n"
161                                                     },
162                                                     "*prop": "store",
163                                                     "remoteSort": true,
164                                                     "xtype": "Store",
165                                                     "|sortInfo": "{ direction : 'ASC', field: 'terms_descrip' }",
166                                                     "|xns": "Roo.data",
167                                                     "items": [
168                                                         {
169                                                             "*prop": "proxy",
170                                                             "xtype": "HttpProxy",
171                                                             "method": "GET",
172                                                             "|xns": "Roo.data",
173                                                             "|url": "baseURL + '/Roo/terms.php'"
174                                                         },
175                                                         {
176                                                             "*prop": "reader",
177                                                             "xtype": "JsonReader",
178                                                             "|xns": "Roo.data",
179                                                             "id": "terms_id",
180                                                             "root": "data",
181                                                             "totalProperty": "total",
182                                                             "|fields": "[{\"name\":\"terms_id\",\"type\":\"int\"},\"terms_descrip\"]"
183                                                         }
184                                                     ]
185                                                 }
186                                             ]
187                                         },
188                                         {
189                                             "allowBlank": false,
190                                             "alwaysQuery": true,
191                                             "displayField": "taxzone_descrip",
192                                             "editable": false,
193                                             "emptyText": "Select Taxzone",
194                                             "fieldLabel": "Tax Zone",
195                                             "forceSelection": true,
196                                             "hiddenName": "vend_taxzone_id",
197                                             "listWidth": 400,
198                                             "loadingText": "Searching...",
199                                             "minChars": 2,
200                                             "name": "vend_taxzone_id_taxzone_descrip",
201                                             "pageSize": 20,
202                                             "qtip": "Select Taxzone",
203                                             "queryParam": "query[taxzone_descrip]",
204                                             "selectOnFocus": true,
205                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{taxzone_descrip}</b> </div>",
206                                             "triggerAction": "all",
207                                             "typeAhead": true,
208                                             "valueField": "taxzone_id",
209                                             "width": 200,
210                                             "xtype": "ComboBox",
211                                             "|xns": "Roo.form",
212                                             "items": [
213                                                 {
214                                                     "listeners": {
215                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n}\n"
216                                                     },
217                                                     "*prop": "store",
218                                                     "remoteSort": true,
219                                                     "xtype": "Store",
220                                                     "|sortInfo": "{ direction : 'ASC', field: 'taxzone_descrip' }",
221                                                     "|xns": "Roo.data",
222                                                     "items": [
223                                                         {
224                                                             "*prop": "proxy",
225                                                             "xtype": "HttpProxy",
226                                                             "method": "GET",
227                                                             "|xns": "Roo.data",
228                                                             "|url": "baseURL + '/Roo/taxzone.php'"
229                                                         },
230                                                         {
231                                                             "*prop": "reader",
232                                                             "xtype": "JsonReader",
233                                                             "|xns": "Roo.data",
234                                                             "id": "taxzone_id",
235                                                             "root": "data",
236                                                             "totalProperty": "total",
237                                                             "|fields": "[{\"name\":\"taxzone_id\",\"type\":\"int\"},\"taxzone_descrip\"]"
238                                                         }
239                                                     ]
240                                                 }
241                                             ]
242                                         },
243                                         {
244                                             "listeners": {
245                                                 "add": "function (combo)\n{\n    Pman.Dialog.XtupleVendTypeEdit.show({vendtype_id : 0}, function(res){\n        _this.form.findField('vend_vendtype_id').setFromData(res);\n    \n    });\n}",
246                                                 "edit": "function (combo, record)\n{\n    var s = _this.form.findField('vend_vendtype_id').getValue() * 1;\n    if(s < 1){\n        Roo.MessageBox.alert('Error','Please select a type');\n        return;\n    }\n\n    Pman.Dialog.XtupleVendTypeEdit.show({vendtype_id : s}, function(res){\n\n        _this.form.findField('vend_vendtype_id').setFromData(res);\n    \n    });\n}"
247                                             },
248                                             "allowBlank": false,
249                                             "alwaysQuery": true,
250                                             "displayField": "vendtype_descrip",
251                                             "editable": false,
252                                             "emptyText": "Select Vendor Type",
253                                             "fieldLabel": "Type",
254                                             "forceSelection": true,
255                                             "hiddenName": "vend_vendtype_id",
256                                             "listWidth": 400,
257                                             "loadingText": "Searching...",
258                                             "minChars": 2,
259                                             "name": "vend_vendtype_id_vendtype_descrip",
260                                             "pageSize": 20,
261                                             "qtip": "Select Vendor Type",
262                                             "queryParam": "query[vendtype_descrip]",
263                                             "selectOnFocus": true,
264                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{vendtype_descrip}</b> </div>",
265                                             "triggerAction": "all",
266                                             "typeAhead": true,
267                                             "valueField": "vendtype_id",
268                                             "width": 200,
269                                             "xtype": "ComboBox",
270                                             "|xns": "Roo.form",
271                                             "items": [
272                                                 {
273                                                     "listeners": {
274                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n}\n"
275                                                     },
276                                                     "*prop": "store",
277                                                     "remoteSort": true,
278                                                     "xtype": "Store",
279                                                     "|sortInfo": "{ direction : 'ASC', field: 'vendtype_descrip' }",
280                                                     "|xns": "Roo.data",
281                                                     "items": [
282                                                         {
283                                                             "*prop": "proxy",
284                                                             "method": "GET",
285                                                             "xtype": "HttpProxy",
286                                                             "|url": "baseURL + '/Roo/vendtype.php'",
287                                                             "|xns": "Roo.data"
288                                                         },
289                                                         {
290                                                             "*prop": "reader",
291                                                             "id": "vendtype_id",
292                                                             "root": "data",
293                                                             "totalProperty": "total",
294                                                             "xtype": "JsonReader",
295                                                             "|fields": "[{\"name\":\"vendtype_id\",\"type\":\"int\"},\"vendtype_descrip\"]",
296                                                             "|xns": "Roo.data"
297                                                         }
298                                                     ]
299                                                 }
300                                             ]
301                                         },
302                                         {
303                                             "fieldLabel": "Active",
304                                             "inputValue": "true",
305                                             "name": "vend_active",
306                                             "valueOff": 0,
307                                             "xtype": "Checkbox",
308                                             "|xns": "Roo.form"
309                                         },
310                                         {
311                                             "allowBlank": true,
312                                             "fieldLabel": "Comments",
313                                             "name": "vend_comments",
314                                             "xtype": "TextArea",
315                                             "|xns": "Roo.form"
316                                         }
317                                     ]
318                                 },
319                                 {
320                                     "hideLabels": true,
321                                     "legend": "Address",
322                                     "style": "width:450px;",
323                                     "xtype": "FieldSet",
324                                     "|xns": "Roo.form",
325                                     "items": [
326                                         {
327                                             "listeners": {
328                                                 "add": "function (combo)\n{\n    Pman.Dialog.XtupleAddress.show({addr_id : 0});\n}",
329                                                 "edit": "function (combo, record)\n{\n    var s = _this.form.findField('vend_addr_id').getValue() * 1;\n    if(s < 1){\n        Roo.MessageBox.alert('Error','Please select a address');\n        return;\n    }\n    Pman.Dialog.XtupleAddress.show({addr_id : s});\n}",
330                                                 "select": "function (combo, record, index)\n{\n    for(var i in record.data) {\n        _this.data['vend_addr_id_' + i] = record.data[i];\n    }\n\n    _this.form.findField('addr_view').sync();\n}"
331                                             },
332                                             "allowBlank": false,
333                                             "alwaysQuery": true,
334                                             "displayField": "addr_number",
335                                             "editable": true,
336                                             "emptyText": "Select Address",
337                                             "fieldLabel": "Address",
338                                             "forceSelection": true,
339                                             "hiddenName": "vend_addr_id",
340                                             "listWidth": 400,
341                                             "loadingText": "Searching...",
342                                             "minChars": 2,
343                                             "name": "vend_addr_id_addr_number",
344                                             "pageSize": 20,
345                                             "qtip": "Select Address",
346                                             "queryParam": "query[address]",
347                                             "selectOnFocus": true,
348                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>#{addr_id} - {addr_number}</b> </div>",
349                                             "triggerAction": "all",
350                                             "typeAhead": true,
351                                             "valueField": "addr_id",
352                                             "width": 400,
353                                             "xtype": "ComboBox",
354                                             "|xns": "Roo.form",
355                                             "items": [
356                                                 {
357                                                     "listeners": {
358                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n    addr_active = 1;\n}\n"
359                                                     },
360                                                     "*prop": "store",
361                                                     "remoteSort": true,
362                                                     "xtype": "Store",
363                                                     "|sortInfo": "{ direction : 'DESC', field: 'addr_id' }",
364                                                     "|xns": "Roo.data",
365                                                     "items": [
366                                                         {
367                                                             "*prop": "proxy",
368                                                             "method": "GET",
369                                                             "xtype": "HttpProxy",
370                                                             "|url": "baseURL + '/Roo/addr.php'",
371                                                             "|xns": "Roo.data"
372                                                         },
373                                                         {
374                                                             "*prop": "reader",
375                                                             "id": "addr_id",
376                                                             "root": "data",
377                                                             "totalProperty": "total",
378                                                             "xtype": "JsonReader",
379                                                             "|fields": "[{\"name\":\"addr_id\",\"type\":\"int\"},\"addr_number\"]",
380                                                             "|xns": "Roo.data"
381                                                         }
382                                                     ]
383                                                 }
384                                             ]
385                                         },
386                                         {
387                                             "allowBlank": true,
388                                             "fieldLabel": "Notes",
389                                             "name": "addr_view",
390                                             "readOnly": true,
391                                             "width": 400,
392                                             "xtype": "TextArea",
393                                             "|sync": "function() {\n    var a = [ 'line1', 'line2', 'line3', 'city', 'state', 'country' ];\n    var v = [];\n    \n    Roo.each(a, function(e) {\n        if (_this.data['vend_addr_id_addr_' +e].length) {\n            v.push(_this.data['vend_addr_id_addr_' +e]);\n        }\n    });\n    \n    this.setValue(v.join(\"\\n\"));\n}\n",
394                                             "|xns": "Roo.form"
395                                         }
396                                     ]
397                                 },
398                                 {
399                                     "name": "vend_id",
400                                     "xtype": "Hidden",
401                                     "|xns": "Roo.form"
402                                 }
403                             ]
404                         }
405                     ]
406                 },
407                 {
408                     "listeners": {
409                         "|activate": "function() {\n    _this.panel = this;\n    if (_this.grid) {\n        _this.grid.footer.onClick('first');\n    }\n}"
410                     },
411                     "background": true,
412                     "fitContainer": true,
413                     "fitToframe": true,
414                     "region": "center",
415                     "tableName": "itemsrc",
416                     "title": "Supplier of",
417                     "xtype": "GridPanel",
418                     "|xns": "Roo",
419                     "items": [
420                         {
421                             "listeners": {
422                                 "|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}",
423                                 "|rowdblclick": "function (_self, rowIndex, e)\n{\n    if (!_this.dialog) return;\n    _this.dialog.show( this.getDataSource().getAt(rowIndex).data, function() {\n        _this.grid.footer.onClick('first');\n    }); \n}\n"
424                             },
425                             "*prop": "grid",
426                             "autoExpandColumn": "itemsrc_vend_item_descrip",
427                             "loadMask": true,
428                             "xtype": "Grid",
429                             "|xns": "Roo.grid",
430                             "items": [
431                                 {
432                                     "listeners": {
433                                         "beforeload": "function (_self, options)\n{\n    options.params.itemsrc_vend_id =   _this.form.findField('vend_id').getValue();\n}"
434                                     },
435                                     "*prop": "dataSource",
436                                     "remoteSort": true,
437                                     "xtype": "Store",
438                                     "|sortInfo": "{ field : 'itemsrc_id_item_number', direction: 'ASC' }",
439                                     "|xns": "Roo.data",
440                                     "items": [
441                                         {
442                                             "*prop": "proxy",
443                                             "xtype": "HttpProxy",
444                                             "method": "GET",
445                                             "|url": "baseURL + '/Roo/itemsrc.php'",
446                                             "|xns": "Roo.data"
447                                         },
448                                         {
449                                             "|xns": "Roo.data",
450                                             "xtype": "JsonReader",
451                                             "totalProperty": "total",
452                                             "root": "data",
453                                             "*prop": "reader",
454                                             "id": "id",
455                                             "|fields": "[\n    {\n        'name': 'itemsrc_id',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_item_id',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_item_id',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_vend_id',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_vend_id',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_vend_item_number',\n        'type': 'string'\n    },\n    {\n        'name': 'itemsrc_vend_item_descrip',\n        'type': 'string'\n    },\n    {\n        'name': 'itemsrc_comments',\n        'type': 'string'\n    },\n    {\n        'name': 'itemsrc_vend_uom',\n        'type': 'string'\n    },\n    {\n        'name': 'itemsrc_invvendoruomratio',\n        'type': 'float'\n    },\n    {\n        'name': 'itemsrc_minordqty',\n        'type': 'float'\n    },\n    {\n        'name': 'itemsrc_multordqty',\n        'type': 'float'\n    },\n    {\n        'name': 'itemsrc_leadtime',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_ranking',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_active',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_manuf_name',\n        'type': 'string'\n    },\n    {\n        'name': 'itemsrc_manuf_item_number',\n        'type': 'string'\n    },\n    {\n        'name': 'itemsrc_manuf_item_descrip',\n        'type': 'string'\n    },\n    {\n        'name': 'itemsrc_default',\n        'type': 'int'\n    },\n    {\n        'name': 'itemsrc_upccode',\n        'type': 'string'\n    }\n]"
456                                         }
457                                     ]
458                                 },
459                                 {
460                                     "*prop": "footer",
461                                     "xtype": "PagingToolbar",
462                                     "pageSize": 25,
463                                     "displayInfo": true,
464                                     "displayMsg": "Displaying itemsrc{0} - {1} of {2}",
465                                     "emptyMsg": "No itemsrc found",
466                                     "|xns": "Roo"
467                                 },
468                                 {
469                                     "*prop": "toolbar",
470                                     "xtype": "Toolbar",
471                                     "|xns": "Roo",
472                                     "items": [
473                                         {
474                                             "text": "Add",
475                                             "xtype": "Button",
476                                             "cls": "x-btn-text-icon",
477                                             "|icon": "Roo.rootURL + 'images/default/dd/drop-add.gif'",
478                                             "listeners": {
479                                                 "|click": "function()\n{\n    if (!_this.dialog) return;\n    _this.dialog.show( { id : 0 } , function() {\n        _this.grid.footer.onClick('first');\n   }); \n}\n"
480                                             },
481                                             "|xns": "Roo.Toolbar"
482                                         },
483                                         {
484                                             "|xns": "Roo.Toolbar",
485                                             "xtype": "Fill"
486                                         },
487                                         {
488                                             "text": "Delete",
489                                             "cls": "x-btn-text-icon",
490                                             "|icon": "rootURL + '/Pman/templates/images/trash.gif'",
491                                             "xtype": "Button",
492                                             "listeners": {
493                                                 "|click": "function()\n{\n     Pman.genericDelete(_this, 'itemsrc'); \n}\n        "
494                                             },
495                                             "|xns": "Roo.Toolbar"
496                                         }
497                                     ]
498                                 },
499                                 {
500                                     "*prop": "colModel[]",
501                                     "dataIndex": "itemsrc_id_item_number",
502                                     "header": "Item",
503                                     "width": 120,
504                                     "xtype": "ColumnModel",
505                                     "|renderer": "function(v) { return String.format('{0}', v); }",
506                                     "|xns": "Roo.grid"
507                                 },
508                                 {
509                                     "*prop": "colModel[]",
510                                     "dataIndex": "itemsrc_vend_item_number",
511                                     "header": "Vendor item number",
512                                     "width": 120,
513                                     "xtype": "ColumnModel",
514                                     "|renderer": "function(v) { return String.format('{0}', v); }",
515                                     "|xns": "Roo.grid"
516                                 },
517                                 {
518                                     "*prop": "colModel[]",
519                                     "dataIndex": "itemsrc_vend_item_descrip",
520                                     "header": "Vendor item description",
521                                     "width": 200,
522                                     "xtype": "ColumnModel",
523                                     "|renderer": "function(v) { return String.format('{0}', v); }",
524                                     "|xns": "Roo.grid"
525                                 },
526                                 {
527                                     "*prop": "colModel[]",
528                                     "dataIndex": "itemsrc_vend_uom",
529                                     "header": "Uom",
530                                     "width": 50,
531                                     "xtype": "ColumnModel",
532                                     "|renderer": "function(v) { return String.format('{0}', v); }",
533                                     "|xns": "Roo.grid"
534                                 },
535                                 {
536                                     "*prop": "colModel[]",
537                                     "dataIndex": "itemsrc_minordqty",
538                                     "header": "Min ord qty",
539                                     "width": 50,
540                                     "xtype": "ColumnModel",
541                                     "|renderer": "function(v) { return String.format('{0}', v); }",
542                                     "|xns": "Roo.grid"
543                                 },
544                                 {
545                                     "*prop": "colModel[]",
546                                     "dataIndex": "itemsrc_leadtime",
547                                     "header": "Lead time",
548                                     "width": 75,
549                                     "xtype": "ColumnModel",
550                                     "|renderer": "function(v) { return String.format('{0}', v); }",
551                                     "|xns": "Roo.grid"
552                                 },
553                                 {
554                                     "*prop": "colModel[]",
555                                     "dataIndex": "itemsrc_active",
556                                     "header": "Active",
557                                     "width": 75,
558                                     "xtype": "ColumnModel",
559                                     "|renderer": "function(v) { return String.format('{0}', v); }",
560                                     "|xns": "Roo.grid"
561                                 }
562                             ]
563                         }
564                     ]
565                 },
566                 {
567                     "listeners": {
568                         "click": "function (_self, e)\n{\n    _this.dialog.hide();\n}"
569                     },
570                     "*prop": "buttons[]",
571                     "text": "Cancel",
572                     "xtype": "Button",
573                     "|xns": "Roo"
574                 },
575                 {
576                     "listeners": {
577                         "click": "function (_self, e)\n{\n    _this.form.doAction(\"submit\");\n\n}"
578                     },
579                     "*prop": "buttons[]",
580                     "text": "Save",
581                     "xtype": "Button",
582                     "|xns": "Roo"
583                 }
584             ]
585         }
586     ],
587     "permname": "",
588     "modOrder": "001"
589 }