Pman.Dialog.BuilderProp.bjs
[Pman.Builder] / Pman.Dialog.BuilderProp.bjs
1 {
2     "id": "roo-file-59",
3     "name": "Pman.Dialog.BuilderProp",
4     "parent": "",
5     "title": "",
6     "path": "/home/alan/gitlive/Pman.Builder/Pman.Dialog.BuilderProp.bjs",
7     "items": [
8         {
9             "listeners": {
10                 "show": "function (_self)\n{\n   _this.data.ds.load();\n}"
11             },
12             "closable": false,
13             "collapsible": false,
14             "height": 600,
15             "resizable": false,
16             "title": "Add Property",
17             "width": 600,
18             "xtype": "LayoutDialog",
19             "|xns": "Roo",
20             "items": [
21                 {
22                     "|xns": "Roo",
23                     "xtype": "LayoutRegion",
24                     "*prop": "center"
25                 },
26                 {
27                     "listeners": {
28                         "|activate": "function() {\n    _this.panel = this;\n    //if (_this.grid) {\n    //    _this.grid.ds.load({});\n    //}\n}"
29                     },
30                     "background": true,
31                     "fitContainer": true,
32                     "fitToframe": true,
33                     "region": "center",
34                     "tableName": "AutoAuth",
35                     "title": "AutoAuth",
36                     "xtype": "GridPanel",
37                     "|xns": "Roo",
38                     "items": [
39                         {
40                             "listeners": {
41                                 "|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}",
42                                 "|rowdblclick": "function (_self, rowIndex, e)\n{\n     \n     _this.callback(this.getDataSource().getAt(rowIndex).data.name);\n     _this.dialog.hide(); \n}\n"
43                             },
44                             "*prop": "grid",
45                             "autoExpandColumn": "desc",
46                             "loadMask": true,
47                             "xtype": "Grid",
48                             "|xns": "Roo.grid",
49                             "items": [
50                                 {
51                                     "listeners": {
52                                         "beforeload": "function (_self, options)\n{\n    // we should cache this!!!\n    options.params = options.params || {};\n    options.params.xtype = this.data.xtype;\n    options.params.xns = this.data.xns;\n    \n}"
53                                     },
54                                     "*prop": "dataSource",
55                                     "remoteSort": false,
56                                     "xtype": "Store",
57                                     "|sortInfo": "{ field : 'name', direction: 'ASC' }",
58                                     "|xns": "Roo.data",
59                                     "items": [
60                                         {
61                                             "*prop": "proxy",
62                                             "method": "GET",
63                                             "xtype": "HttpProxy",
64                                             "|url": "baseURL + '/Builder/Prop.php'",
65                                             "|xns": "Roo.data"
66                                         },
67                                         {
68                                             "|xns": "Roo.data",
69                                             "xtype": "JsonReader",
70                                             "totalProperty": "total",
71                                             "root": "data",
72                                             "*prop": "reader",
73                                             "id": "id",
74                                             "|fields": "[\n    {\n        'name': 'id',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id',\n        'type': 'int'\n    },\n    {\n        'name': 'url',\n        'type': 'string'\n    },\n    {\n        'name': 'ts',\n        'type': 'date',\n        'dateFormat': 'Y-m-d'\n    },\n    {\n        'name': 'checksum',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_title',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_company',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_address',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_email',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_telephone',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_fax',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_mobile',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_country',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_currency',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_shipping_method',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_shipping_acc',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_terms_agreed',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_passwd',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_is_buyer',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_is_seller',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_is_want_blind_rfq',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_buyer_type',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_is_verified',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_is_disabled',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_is_want_email',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_mail_newprod_freq',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_quotation_by',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_is_want_make_offer',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_mail_inventry_freq',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_max_rfq_per_day',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_is_approved',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_created',\n        'type': 'date'\n    },\n    {\n        'name': 'user_id_modified',\n        'type': 'date'\n    },\n    {\n        'name': 'user_id_modified_by',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_is_administrator',\n        'type': 'int'\n    },\n    {\n        'name': 'user_id_bank_name',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_bank_account',\n        'type': 'string'\n    },\n    {\n        'name': 'user_id_last_inventory_sent',\n        'type': 'date'\n    },\n    {\n        'name': 'user_id_last_rfq_report_sent',\n        'type': 'date'\n    },\n    {\n        'name': 'user_id_last_productlist_sent',\n        'type': 'date'\n    },\n    {\n        'name': 'user_id_company_id',\n        'type': 'int'\n    }\n]"
75                                         }
76                                     ]
77                                 },
78                                 {
79                                     "*prop": "colModel[]",
80                                     "dataIndex": "name",
81                                     "header": "name",
82                                     "width": 175,
83                                     "xtype": "ColumnModel",
84                                     "|renderer": "function(v) { return String.format('{0}', v ? v.format('d/M/Y') : ''); }",
85                                     "|xns": "Roo.grid"
86                                 },
87                                 {
88                                     "*prop": "colModel[]",
89                                     "dataIndex": "desc",
90                                     "header": "Description",
91                                     "width": 200,
92                                     "xtype": "ColumnModel",
93                                     "|renderer": "function(v) { return String.format('{0}', v); }",
94                                     "|xns": "Roo.grid"
95                                 }
96                             ]
97                         }
98                     ]
99                 },
100                 {
101                     "listeners": {
102                         "click": "function (_self, e)\n{\n    _this.dialog.hide();\n}"
103                     },
104                     "*prop": "buttons[]",
105                     "text": "Cancel",
106                     "xtype": "Button",
107                     "|xns": "Roo"
108                 },
109                 {
110                     "listeners": {
111                         "click": "function (_self, e)\n{\n    // do some checks?\n     \n    \n    _this.dialog.el.mask(\"Saving\");\n    _this.form.doAction(\"submit\");\n\n}"
112                     },
113                     "*prop": "buttons[]",
114                     "text": "Add",
115                     "xtype": "Button",
116                     "|xns": "Roo"
117                 }
118             ]
119         }
120     ],
121     "permname": "",
122     "modOrder": "001"
123 }