3 "name": "Pman.Tab.CoreOAuthClient",
4 "parent": "Pman.Tab.Admin",
6 "path": "/home/edward/gitlive/Pman.Core/Pman.Tab.CoreOAuthClient.bjs",
10 "title": "Oauth2 Clients",
11 "xtype": "NestedLayoutPanel",
16 "xtype": "BorderLayout",
23 "xtype": "LayoutRegion",
28 "|activate": "function() {\n _this.panel = this;\n \n if (_this.grid) {\n _this.grid.footer.onClick('first');\n }\n}"
34 "tableName": "core_oauth_clients",
35 "title": "Oauth2 Clients",
41 "|render": "function() \n{\n _this.grid = this; \n if (_this.panel.active) {\n this.footer.onClick('first');\n }\n}",
42 "afteredit": "function (e)\n{\n if(e.originalValue == e.value || !e.value.length){\n return false;\n }\n \n Roo.log('commit');\n}"
45 "autoExpandColumn": "redirect_uri",
48 "xtype": "EditorGrid",
53 "beforeload": "function (_self, o){\n o.params = o.params || {};\n\n}\n"
55 "*prop": "dataSource",
58 "|sortInfo": "{ field : 'client_id', direction: 'ASC' }",
65 "|url": "baseURL + '/Roo/Core_oauth_clients'",
72 "totalProperty": "total",
73 "xtype": "JsonReader",
74 "|fields": "[\n {\n 'name': 'client_id',\n 'type': 'string'\n },\n {\n 'name': 'client_secret',\n 'type': 'string'\n },\n {\n 'name': 'redirect_uri',\n 'type': 'string'\n }\n]",
86 "|click": "function()\n{\n var status = _this.form.findField('pohead_status').getValue();\n \n if(status == 'C'){\n Roo.MessageBox.alert(\"Error\", \"This PO has been closed\");\n return;\n }\n \n var ct = _this.grid.ds.getCount();\n \n var last = ct ? _this.grid.ds.getAt(ct-1).data.poitem_linenumber * 1 + 1 : 1;\n \n var dt = _this.form.findField('pohead_orderdate').getValue();\n \n var nr = _this.grid.ds.reader.newRow({\n poitem_id : 0,\n poitem_linenumber : last,\n item_number : '',\n item_descrip1 : '',\n poitem_duedate : dt,\n poitem_qty_ordered : 1,\n poitem_unitprice : 0\n });\n \n _this.grid.stopEditing();\n _this.grid.ds.insert(_this.grid.ds.getCount(), nr); \n _this.grid.startEditing(_this.grid.ds.getCount()-1, 1);\n}\n"
88 "cls": "x-btn-text-icon",
91 "|icon": "Roo.rootURL + 'images/default/dd/drop-add.gif'",
96 "|click": "function ()\n{\n var status = _this.form.findField('pohead_status').getValue();\n \n if(status == 'C'){\n Roo.MessageBox.alert(\"Error\", \"This PO has been closed\");\n return;\n }\n \n var cs = _this.grid.getSelectionModel().getSelectedCell();\n if (!cs) {\n Roo.MessageBox.alert(\"Error\", \"Select a cell\");\n return;\n }\n _this.grid.stopEditing();\n var r = _this.grid.ds.getAt(cs[0]);\n \n if(r.data.poitem_qty_received * 1 > 0){\n Roo.MessageBox.alert(\"Error\", \"This item has been receipted\");\n return;\n }\n \n \n _this.grid.ds.remove(r);\n \n}"
98 "cls": "x-btn-text-icon",
101 "|icon": "rootURL + '/Pman/templates/images/trash.gif'",
102 "|xns": "Roo.Toolbar"
109 "emptyMsg": "No Clients found",
111 "xtype": "PagingToolbar",
115 "*prop": "colModel[]",
116 "dataIndex": "client_id",
117 "header": "Client ID",
119 "xtype": "ColumnModel",
120 "|renderer": "function(v) { \n return String.format('{0}', v ? v : '');\n}",
125 "xtype": "GridEditor",
130 "xtype": "TextField",
138 "*prop": "colModel[]",
139 "dataIndex": "client_secret",
140 "header": "Client Secret",
142 "xtype": "ColumnModel",
143 "|renderer": "function(v) { \n return String.format('{0}', v ? v : '');\n}",
148 "xtype": "GridEditor",
153 "xtype": "TextField",
161 "*prop": "colModel[]",
162 "dataIndex": "redirect_uri",
163 "header": "Redirect URI",
165 "xtype": "ColumnModel",
166 "|renderer": "function(v) { \n return String.format('{0}', v ? v : '');\n}",
171 "xtype": "GridEditor",
176 "xtype": "TextField",