3 "name": "Pman.Dialog.AdminCoreEnum",
6 "path": "/home/alan/gitlive/Pman.Admin/Pman.Dialog.AdminCoreEnum.bjs",
10 "show": "function (_self)\n{\n var name_hidden = false;\n\n if (typeof(_this.data._hide_name) != 'undefined') {\n name_hidden = true;\n \n }\n \n _this.grid.colModel.setHidden(1,name_hidden);\n}"
13 "title": "Pulldown Options",
15 "xtype": "LayoutDialog",
20 "xtype": "LayoutRegion",
25 "|activate": "function() {\n _this.panel = this;\n if (_this.grid) {\n // _this.grid.footer.onClick('first');\n }\n}"
31 "tableName": "core_enum",
32 "title": "Pulldown Options",
38 "|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}",
39 "afteredit": "function (e)\n{\n e.record.commit(); \n}",
40 "cellclick": "function (_self, rowIndex, columnIndex, e)\n{\n\n var di = this.colModel.getDataIndex(columnIndex);\n if (di != 'active') {\n return;\n }\n \n var rec = _this.grid.ds.getAt(rowIndex);\n \n rec.set('active', rec.data.active ? 0 : 1);\n rec.commit();\n \n \n}",
41 "beforeedit": "function (e)\n{\n if(e.field == 'name' && e.record.data.is_system_enum*1 == 1){\n return false;\n }\n}"
44 "autoExpandColumn": "display_name",
47 "xtype": "EditorGrid",
52 "beforeload": "function (_self, options)\n{\n\n options.params.etype = _this.data.etype;\n if (!options.params.etype.length) {\n return false;\n }\n}",
53 "update": "function (_self, record, operation)\n{\n if (operation != Roo.data.Record.COMMIT) {\n return;\n }\n // got commit..\n new Pman.Request({\n url : baseURL + '/Roo/Core_enum.php',\n method : 'POST',\n params : {\n id : record.data.id,\n etype : _this.data.etype,\n name : record.data.name,\n active : record.data.active,\n seqid : record.data.seqid,\n display_name : record.data.display_name\n }, \n success : function(res) {\n //Roo.log(data);\n // update the ID if it's not set..\n if (record.data.id * 1 < 1) {\n record.set('id', res.data.id);\n }\n }\n });\n \n}"
55 "*prop": "dataSource",
58 "|sortInfo": "{ field : 'etype', direction: 'ASC' }",
65 "|url": "baseURL + '/Roo/core_enum.php'",
70 "xtype": "JsonReader",
71 "totalProperty": "total",
75 "|fields": "[\n {\n 'name': 'id',\n 'type': 'int'\n },\n {\n 'name': 'etype',\n 'type': 'string'\n },\n {\n 'name': 'name',\n 'type': 'string'\n },\n {\n 'name': 'active',\n 'type': 'int'\n },\n {\n 'name': 'seqid',\n 'type': 'int'\n }\n]"
81 "xtype": "PagingToolbar",
84 "displayMsg": "Displaying core_enum{0} - {1} of {2}",
85 "emptyMsg": "No core_enum found",
95 "|click": "function()\n{\n \n // if we do not have a selected type... - what should we show..?\n var et = _this.data.etype;\n var ds = _this.grid.getDataSource();\n if (!et) {\n Roo.MessageBox.alert(\"Error\", \"Select a pulldown\");\n return;\n }\n\n var add = ds.reader.newRow({ \n id: 0, \n display_name : '', \n name : '', \n etype: et, \n active: 1, \n seqid: 0\n });\n var r = ds.data.length;\n ds.insert(r , add); \n _this.grid.startEditing(r, 1); // name... \n}\n"
97 "cls": "x-btn-text-icon",
100 "|icon": "Roo.rootURL + 'images/default/dd/drop-add.gif'",
101 "|xns": "Roo.Toolbar"
104 "|xns": "Roo.Toolbar",
110 "*prop": "colModel[]",
112 "header": "Internal #",
114 "xtype": "ColumnModel",
115 "|renderer": "function(v) { return String.format('{0}', v); }",
119 "xtype": "ColumnModel",
123 "|renderer": "function(v) { return String.format('{0}', v); }",
125 "*prop": "colModel[]",
129 "xtype": "GridEditor",
134 "xtype": "TextField",
142 "*prop": "colModel[]",
143 "dataIndex": "display_name",
144 "header": "Display Name",
146 "xtype": "ColumnModel",
147 "|renderer": "function(v) { return String.format('{0}', v); }",
152 "xtype": "GridEditor",
157 "xtype": "TextField",
165 "*prop": "colModel[]",
166 "dataIndex": "active",
169 "xtype": "ColumnModel",
170 "|renderer": "function(v) { \n var state = v> 0 ? '-checked' : '';\n\n return '<img class=\"x-grid-check-icon' + state + '\" src=\"' + Roo.BLANK_IMAGE_URL + '\"/>';\n \n }",
174 "*prop": "colModel[]",
175 "dataIndex": "seqid",
179 "xtype": "ColumnModel",
180 "|renderer": "function(v) { return String.format('{0}', v); }",
185 "xtype": "GridEditor",
190 "allowDecimals": false,
191 "allowNegative": true,
192 "decimalPrecision": 0,
193 "xtype": "NumberField",
206 "click": "function (_self, e)\n{\n _this.dialog.hide();\n}"
208 "*prop": "buttons[]",
214 "*prop": "buttons[]",