Pman.Dialog.MTrackTime.bjs
[Pman.MTrack] / Pman.Dialog.MTrackTime.bjs
1 {
2     "id": "roo-file-194",
3     "name": "Pman.Dialog.MTrackTime",
4     "parent": "",
5     "title": "",
6     "path": "/home/alan/gitlive/Pman.MTrack/Pman.Dialog.MTrackTime.bjs",
7     "items": [
8         {
9             "height": 700,
10             "title": "Time Manager",
11             "width": 1000,
12             "xtype": "LayoutDialog",
13             "|xns": "Roo",
14             "items": [
15                 {
16                     "*prop": "center",
17                     "tabPosition": "top",
18                     "xtype": "LayoutRegion",
19                     "|xns": "Roo"
20                 },
21                 {
22                     "region": "center",
23                     "title": "Log Time",
24                     "xtype": "NestedLayoutPanel",
25                     "|xns": "Roo",
26                     "items": [
27                         {
28                             "|xns": "Roo",
29                             "xtype": "BorderLayout",
30                             "*prop": "layout",
31                             "items": [
32                                 {
33                                     "*prop": "west",
34                                     "split": true,
35                                     "width": 600,
36                                     "xtype": "LayoutRegion",
37                                     "|xns": "Roo"
38                                 },
39                                 {
40                                     "*prop": "center",
41                                     "title": "Active / Logged Time",
42                                     "xtype": "LayoutRegion",
43                                     "|xns": "Roo"
44                                 },
45                                 {
46                                     "*prop": "east",
47                                     "collapsed": true,
48                                     "collapsedTitle": "Ticket Details",
49                                     "collapsible": true,
50                                     "split": true,
51                                     "title": "Ticket Details",
52                                     "width": 350,
53                                     "xtype": "LayoutRegion",
54                                     "|xns": "Roo"
55                                 },
56                                 {
57                                     "listeners": {
58                                         "|activate": "function() {\n    _this.timepanel = this;\n    if (_this.timegrid) {\n       // _this.grid.footer.onClick('first');\n    }\n}"
59                                     },
60                                     "background": true,
61                                     "fitContainer": true,
62                                     "fitToframe": true,
63                                     "region": "west",
64                                     "tableName": "cash_invoice_entry",
65                                     "title": "cash_invoice_entry",
66                                     "xtype": "GridPanel",
67                                     "|xns": "Roo",
68                                     "items": [
69                                         {
70                                             "listeners": {
71                                                 "|render": "function() \n{\n    _this.timegrid = this; \n    //_this.dialog = Pman.Dialog.FILL_IN\n    if (_this.timepanel.active) {\n      // this.footer.onClick('first');\n    }\n}",
72                                                 "|rowdblclick": "function (_self, rowIndex, e)\n{\n    if (!_this.dialog) return;\n    _this.dialog.show( this.getDataSource().getAt(rowIndex), function() {\n        _this.grid.footer.onClick('first');\n    }); \n}\n"
73                                             },
74                                             "*prop": "grid",
75                                             "autoExpandColumn": "activity_ref",
76                                             "loadMask": true,
77                                             "xtype": "Grid",
78                                             "|xns": "Roo.grid",
79                                             "items": [
80                                                 {
81                                                     "|xns": "Roo",
82                                                     "xtype": "Toolbar",
83                                                     "*prop": "toolbar",
84                                                     "items": [
85                                                         {
86                                                             "listeners": {
87                                                                 "render": "function (_self)\n{\n        _this.personSelect = _self;\n}"
88                                                             },
89                                                             "allowBlank": "false",
90                                                             "displayField": "name",
91                                                             "editable": "false",
92                                                             "emptyText": "Select Person",
93                                                             "fieldLabel": "Person",
94                                                             "forceSelection": true,
95                                                             "hiddenName": "",
96                                                             "listWidth": 400,
97                                                             "loadingText": "Searching...",
98                                                             "minChars": 2,
99                                                             "name": "",
100                                                             "pageSize": 20,
101                                                             "qtip": "Select Person",
102                                                             "queryParam": "",
103                                                             "selectOnFocus": true,
104                                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> {email} </div>",
105                                                             "triggerAction": "all",
106                                                             "typeAhead": true,
107                                                             "valueField": "id",
108                                                             "width": 300,
109                                                             "xtype": "ComboBox",
110                                                             "|xns": "Roo.form",
111                                                             "items": [
112                                                                 {
113                                                                     "listeners": {
114                                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n    o.params.company_id_comptype = 'OWNER';\n}\n"
115                                                                     },
116                                                                     "*prop": "store",
117                                                                     "remoteSort": true,
118                                                                     "xtype": "Store",
119                                                                     "|sortInfo": "{ direction : 'ASC', field: 'id' }",
120                                                                     "|xns": "Roo.data",
121                                                                     "items": [
122                                                                         {
123                                                                             "*prop": "proxy",
124                                                                             "xtype": "HttpProxy",
125                                                                             "method": "GET",
126                                                                             "|xns": "Roo.data",
127                                                                             "|url": "baseURL + '/Roo/Person.php'"
128                                                                         },
129                                                                         {
130                                                                             "*prop": "reader",
131                                                                             "xtype": "JsonReader",
132                                                                             "|xns": "Roo.data",
133                                                                             "id": "id",
134                                                                             "root": "data",
135                                                                             "totalProperty": "total",
136                                                                             "|fields": "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]"
137                                                                         }
138                                                                     ]
139                                                                 }
140                                                             ]
141                                                         }
142                                                     ]
143                                                 },
144                                                 {
145                                                     "*prop": "dataSource",
146                                                     "remoteSort": true,
147                                                     "xtype": "Store",
148                                                     "|sortInfo": "{ field : 'action_dt', direction: 'DESC' }",
149                                                     "|xns": "Roo.data",
150                                                     "items": [
151                                                         {
152                                                             "listeners": {
153                                                                 "beforeload": "function (This, params)\n{\n   if (_this.personSelect.getValue()) {\n        params.person_id = _this.personSelect.getValue();\n    } else {\n        params.person_id = Pman.Login.authUser.id;\n    }\n    \n    \n}"
154                                                             },
155                                                             "*prop": "proxy",
156                                                             "method": "GET",
157                                                             "xtype": "HttpProxy",
158                                                             "|url": "baseURL + '/Roo/cash_invoice_entry.php'",
159                                                             "|xns": "Roo.data"
160                                                         },
161                                                         {
162                                                             "|xns": "Roo.data",
163                                                             "xtype": "JsonReader",
164                                                             "totalProperty": "total",
165                                                             "root": "data",
166                                                             "*prop": "reader",
167                                                             "id": "id",
168                                                             "|fields": "[\n    {\n        'name': 'id',\n        'type': 'int'\n    },\n    {\n        'name': 'entry_dt',\n        'type': 'date',\n        'dateFormat': 'Y-m-d'\n    },\n    {\n        'name': 'entered_dt',\n        'type': 'date',\n        'dateFormat': 'Y-m-d'\n    },\n    {\n        'name': 'description',\n        'type': 'string'\n    },\n    {\n        'name': 'action',\n        'type': 'string'\n    },\n    {\n        'name': 'qty',\n        'type': 'string'\n    },\n    {\n        'name': 'invoice_id',\n        'type': 'int'\n    },\n    {\n        'name': 'pricevalue',\n        'type': 'float'\n    },\n    {\n        'name': 'qtyvalue',\n        'type': 'float'\n    },\n    {\n        'name': 'to_account_id',\n        'type': 'int'\n    },\n    {\n        'name': 'discount',\n        'type': 'float'\n    },\n    {\n        'name': 'action_dt',\n        'type': 'date',\n        'dateFormat': 'Y-m-d'\n    },\n    {\n        'name': 'staff_id',\n        'type': 'int'\n    },\n    {\n        'name': 'invoice_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'invoice_id_idtxt',\n        'type': 'string'\n    },\n    {\n        'name': 'invoice_id_project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'invoice_id_opened_dt',\n        'type': 'date'\n    },\n    {\n        'name': 'invoice_id_posted',\n        'type': 'date'\n    },\n    {\n        'name': 'invoice_id_post_transaction_id',\n        'type': 'int'\n    },\n    {\n        'name': 'invoice_id_post_account_id',\n        'type': 'int'\n    },\n    {\n        'name': 'invoice_id_paid',\n        'type': 'float'\n    },\n    {\n        'name': 'invoice_id_total',\n        'type': 'float'\n    },\n    {\n        'name': 'invoice_id_duedate',\n        'type': 'date'\n    },\n    {\n        'name': 'to_account_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'to_account_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'to_account_id_type',\n        'type': 'string'\n    },\n    {\n        'name': 'to_account_id_commodity',\n        'type': 'string'\n    },\n    {\n        'name': 'to_account_id_scu',\n        'type': 'string'\n    },\n    {\n        'name': 'to_account_id_description',\n        'type': 'string'\n    },\n    {\n        'name': 'to_account_id_parent',\n        'type': 'int'\n    },\n    {\n        'name': 'to_account_id_fullname',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'staff_id_office_id',\n        'type': 'int'\n    },\n    {\n        'name': 'staff_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_phone',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_fax',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_email',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_company_id',\n        'type': 'int'\n    },\n    {\n        'name': 'staff_id_role',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'staff_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_passwd',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'staff_id_lang',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_no_reset_sent',\n        'type': 'int'\n    },\n    {\n        'name': 'staff_id_action_type',\n        'type': 'string'\n    },\n    {\n        'name': 'staff_id_project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'staff_id_deleted_by',\n        'type': 'int'\n    },\n    {\n        'name': 'staff_id_deleted_dt',\n        'type': 'date'\n    }\n]"
169                                                         }
170                                                     ]
171                                                 },
172                                                 {
173                                                     "*prop": "colModel[]",
174                                                     "dataIndex": "action_dt",
175                                                     "header": "Time",
176                                                     "width": 100,
177                                                     "xtype": "ColumnModel",
178                                                     "|renderer": "function(v,x,r) { \n    var s = r.data.qtyvalue;\n    var end = v.add(Date.HOUR, s);\n    return String.format('{0}-{1}', v.format('H:i'), end.format('H:i') );\n}",
179                                                     "|xns": "Roo.grid"
180                                                 },
181                                                 {
182                                                     "*prop": "colModel[]",
183                                                     "dataIndex": "ticket_id_summary",
184                                                     "header": "Ticket",
185                                                     "width": 200,
186                                                     "xtype": "ColumnModel",
187                                                     "|renderer": "function(v) { return String.format('{0}', v ? v.format('d/M/Y') : ''); }",
188                                                     "|xns": "Roo.grid"
189                                                 },
190                                                 {
191                                                     "*prop": "colModel[]",
192                                                     "dataIndex": "notes",
193                                                     "header": "Notes",
194                                                     "width": 300,
195                                                     "xtype": "ColumnModel",
196                                                     "|renderer": "function(v) { return String.format('{0}', v ? v.format('d/M/Y') : ''); }",
197                                                     "|xns": "Roo.grid"
198                                                 }
199                                             ]
200                                         }
201                                     ]
202                                 },
203                                 {
204                                     "region": "center",
205                                     "xtype": "NestedLayoutPanel",
206                                     "|xns": "Roo",
207                                     "items": [
208                                         {
209                                             "|xns": "Roo",
210                                             "xtype": "BorderLayout",
211                                             "*prop": "layout",
212                                             "items": [
213                                                 {
214                                                     "*prop": "north",
215                                                     "height": 200,
216                                                     "title": "Details",
217                                                     "xtype": "LayoutRegion",
218                                                     "|xns": "Roo"
219                                                 },
220                                                 {
221                                                     "*prop": "center",
222                                                     "title": "Task Queue",
223                                                     "xtype": "LayoutRegion",
224                                                     "|xns": "Roo"
225                                                 },
226                                                 {
227                                                     "listeners": {
228                                                         "|activate": "function() {\n    _this.queuepanel = this;\n    if (_this.queuegrid) {\n        //_this.queuegrid.footer.onClick('first');\n    }\n}"
229                                                     },
230                                                     "background": true,
231                                                     "fitContainer": true,
232                                                     "fitToframe": true,
233                                                     "region": "center",
234                                                     "tableName": "mtrack_ticket",
235                                                     "title": "mtrack_ticket",
236                                                     "xtype": "GridPanel",
237                                                     "|xns": "Roo",
238                                                     "items": [
239                                                         {
240                                                             "listeners": {
241                                                                 "|render": "function() \n{\n    _this.queuegrid = this; \n    //_this.dialog = Pman.Dialog.FILL_IN\n    if (_this.queuepanel.active) {\n       //this.footer.onClick('first');\n    }\n}",
242                                                                 "|rowdblclick": "function (_self, rowIndex, e)\n{\n    if (!_this.dialog) return;\n    _this.dialog.show( this.getDataSource().getAt(rowIndex), function() {\n        _this.grid.footer.onClick('first');\n    }); \n}\n"
243                                                             },
244                                                             "*prop": "grid",
245                                                             "autoExpandColumn": "summary",
246                                                             "loadMask": true,
247                                                             "xtype": "Grid",
248                                                             "|xns": "Roo.grid",
249                                                             "items": [
250                                                                 {
251                                                                     "|xns": "Roo",
252                                                                     "xtype": "Toolbar",
253                                                                     "*prop": "toolbar",
254                                                                     "items": [
255                                                                         {
256                                                                             "listeners": {
257                                                                                 "render": "function (_self)\n{\n    _this.projectSel = _self;\n}",
258                                                                                 "beforeselect": "function (combo, record, index)\n{\n\n     \n    _this.queuegrid.ds.load({});\n    \n      \n     \n}"
259                                                                             },
260                                                                             "allowBlank": "false",
261                                                                             "displayField": "name",
262                                                                             "editable": "false",
263                                                                             "emptyText": "Select Project",
264                                                                             "fieldLabel": "Project",
265                                                                             "forceSelection": true,
266                                                                             "hiddenName": "project_id",
267                                                                             "listWidth": 400,
268                                                                             "loadingText": "Searching...",
269                                                                             "minChars": 2,
270                                                                             "name": "project_id_name",
271                                                                             "pageSize": 20,
272                                                                             "qtip": "Select Projects",
273                                                                             "queryParam": "query[name]",
274                                                                             "selectOnFocus": true,
275                                                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{code}</b> - {name}</div>",
276                                                                             "triggerAction": "all",
277                                                                             "typeAhead": true,
278                                                                             "valueField": "id",
279                                                                             "width": 200,
280                                                                             "xtype": "ComboBox",
281                                                                             "|xns": "Roo.form",
282                                                                             "items": [
283                                                                                 {
284                                                                                     "listeners": {
285                                                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n    o.params['query[project_filter]'] = 'P,N,U'; // actually this is the default.\n    \n    // set more here\n}\n"
286                                                                                     },
287                                                                                     "*prop": "store",
288                                                                                     "remoteSort": true,
289                                                                                     "xtype": "Store",
290                                                                                     "|sortInfo": "{ field: 'code', direction: 'ASC' }",
291                                                                                     "|xns": "Roo.data",
292                                                                                     "items": [
293                                                                                         {
294                                                                                             "*prop": "proxy",
295                                                                                             "xtype": "HttpProxy",
296                                                                                             "method": "GET",
297                                                                                             "|xns": "Roo.data",
298                                                                                             "|url": "baseURL + '/Roo/Projects.php'"
299                                                                                         },
300                                                                                         {
301                                                                                             "*prop": "reader",
302                                                                                             "xtype": "JsonReader",
303                                                                                             "|xns": "Roo.data",
304                                                                                             "id": "id",
305                                                                                             "root": "data",
306                                                                                             "totalProperty": "total",
307                                                                                             "|fields": "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]"
308                                                                                         }
309                                                                                     ]
310                                                                                 }
311                                                                             ]
312                                                                         }
313                                                                     ]
314                                                                 },
315                                                                 {
316                                                                     "*prop": "dataSource",
317                                                                     "xtype": "Store",
318                                                                     "remoteSort": true,
319                                                                     "|sortInfo": "{ field : 'summary', direction: 'ASC' }",
320                                                                     "|xns": "Roo.data",
321                                                                     "items": [
322                                                                         {
323                                                                             "*prop": "proxy",
324                                                                             "xtype": "HttpProxy",
325                                                                             "method": "GET",
326                                                                             "|url": "baseURL + '/Roo/mtrack_ticket.php'",
327                                                                             "|xns": "Roo.data"
328                                                                         },
329                                                                         {
330                                                                             "|xns": "Roo.data",
331                                                                             "xtype": "JsonReader",
332                                                                             "totalProperty": "total",
333                                                                             "root": "data",
334                                                                             "*prop": "reader",
335                                                                             "id": "id",
336                                                                             "|fields": "[\n    {\n        'name': 'id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'summary',\n        'type': 'string'\n    },\n    {\n        'name': 'description',\n        'type': 'string'\n    },\n    {\n        'name': 'changelog',\n        'type': 'string'\n    },\n    {\n        'name': 'created',\n        'type': 'int'\n    },\n    {\n        'name': 'updated',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id',\n        'type': 'int'\n    },\n    {\n        'name': 'cc',\n        'type': 'string'\n    },\n    {\n        'name': 'status',\n        'type': 'int'\n    },\n    {\n        'name': 'estimated',\n        'type': 'float'\n    },\n    {\n        'name': 'spent',\n        'type': 'float'\n    },\n    {\n        'name': 'x_fieldname',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_person_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_ontable',\n        'type': 'string'\n    },\n    {\n        'name': 'updated_onid',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_changedate',\n        'type': 'date'\n    },\n    {\n        'name': 'updated_reason',\n        'type': 'string'\n    },\n    {\n        'name': 'created_id',\n        'type': 'int'\n    },\n    {\n        'name': 'created_person_id',\n        'type': 'int'\n    },\n    {\n        'name': 'created_ontable',\n        'type': 'string'\n    },\n    {\n        'name': 'created_onid',\n        'type': 'int'\n    },\n    {\n        'name': 'created_changedate',\n        'type': 'date'\n    },\n    {\n        'name': 'created_reason',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_office_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_phone',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_fax',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_email',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_company_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_role',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_passwd',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_lang',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_no_reset_sent',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_action_type',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_deleted_by',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_deleted_dt',\n        'type': 'date'\n    },\n    {\n        'name': 'developer_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_office_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_phone',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_fax',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_email',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_company_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_role',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_passwd',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_lang',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_no_reset_sent',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_action_type',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_deleted_by',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_deleted_dt',\n        'type': 'date'\n    },\n    {\n        'name': 'priority_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'priority_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'priority_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'severity_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'severity_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'classification_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'classification_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'resolution_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'resolution_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'status_id',\n        'type': 'int'\n    },\n    {\n        'name': 'status_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'status_name',\n        'type': 'string'\n    },\n    {\n        'name': 'status_active',\n        'type': 'int'\n    },\n    {\n        'name': 'status_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_code',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_type',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_client_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_team_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_file_location',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_open_date',\n        'type': 'date'\n    },\n    {\n        'name': 'project_id_open_by',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_close_date',\n        'type': 'date'\n    },\n    {\n        'name': 'project_id_countries',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_languages',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_agency_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'milestone_id_description',\n        'type': 'string'\n    },\n    {\n        'name': 'milestone_id_startdate',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_duedate',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_completed',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_deleted',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_created',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_updated',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_project_id',\n        'type': 'int'\n    }\n]"
337                                                                         }
338                                                                     ]
339                                                                 },
340                                                                 {
341                                                                     "xtype": "ColumnModel",
342                                                                     "header": "Summary",
343                                                                     "width": 200,
344                                                                     "dataIndex": "summary",
345                                                                     "|renderer": "function(v) { return String.format('{0}', v); }",
346                                                                     "|xns": "Roo.grid",
347                                                                     "*prop": "colModel[]"
348                                                                 }
349                                                             ]
350                                                         }
351                                                     ]
352                                                 },
353                                                 {
354                                                     "region": "north",
355                                                     "xtype": "ContentPanel",
356                                                     "|xns": "Roo",
357                                                     "items": [
358                                                         {
359                                                             "listeners": {
360                                                                 "|actioncomplete": "function(_self,action)\n{\n    \n \n    Roo.log('action complete');\n    Roo .log(action);\n    if (action.type == 'setdata') {\n\n        _this.isClose = false; // force flag..\n        \n        if (this.activeRecord) {\n             this.saveActive( this.activeRecord);\n        }\n        \n        \n         \n        // show form..\n        if (!action.data || !action.data.action) {\n            _this.form.el.mask('select something'); \n            this.activeRecord  = false;\n            _this.form.reset(); \n            return;\n        }\n        _this.form.el.unmask();   \n        \n        this.activeRecord = action.rec;\n         \n        \n\n            \n        \n        // should save here if we are 'dirty!';\n        _this.form.reset();\n        _this.form.setValues(action.data);\n        // set the dates so they are correct..\n         _this.form.setValues( { \n \n                action_dt : action.data.action_dt.format('Y-m-d H:i:s'),\n                entry_dt: action.data.action_dt.format('Y-m-d'),\n                qtyvalue2 : action.data.qtyvalue\n            });\n        // set the default values..\n        // for dirty test...\n        _this.form.items.each(function(f) {\n            f.originalValue = f.getValue();\n        });\n        \n        \n        \n        \n        // form is set to an event.\n        \n                \n        \n       return;\n    }\n    \n    \n    if (action.type == 'load') {\n \n        return;\n    }\n    if (action.type =='submit') {\n        // set this on the close button..\n         if (_this.isClose) {\n            _this.dialog.hide();\n         }\n        \n         if (_this.callback) {\n            _this.callback.call(_this, _this.form.getValues());\n         }\n\n         return;\n    }\n}\n",
361                                                                 "|rendered": "function (form)\n{\n    _this.form= form;\n}\n"
362                                                             },
363                                                             "activeData": false,
364                                                             "method": "POST",
365                                                             "style": "margin-left:10px;",
366                                                             "xtype": "Form",
367                                                             "|saveActive": "function(rec, effort) {\n    \n     effort = effort || 0;\n    \n\n    if (!rec) {\n        Roo.log(\"ERROR: saveActive: record not set \");\n        return;\n    }\n\n     var d = Roo.apply({}, rec.data); // copy it so changes do not affect crap...\n     \n     var upd = (new Date()).format('Y-m-d H:i:s');\n     \n \n     \n     \n     //Roo.log(\"SAVE IT: \" + Roo.encode(d) );\n     \n     //     return;\n     var at = typeof(d.action_dt) == 'string' ? Date.parseDate(d.action_dt, 'Y-m-d H:i:s') : d.action_dt\n     \n     new Pman.Request({\n        url : baseURL + '/Roo/Cash_invoice_entry.php',\n        method : 'POST',\n        params : {\n            id : d.id,\n            entry_dt: at.format('Y-m-d'),  // this should not change for posted entries really...\n            entered_dt: upd,            \n            action_dt : at.format('Y-m-d H:i:s'),\n            qtyvalue : d.qtyvalue,\n            action: 'Hours',\n            description: d.description,\n            pricevalue: d.pricevalue,  \n            project_id : d.project_id,\n            staff_id : d.staff_id * 1 ? d.staff_id : Pman.Login.authUser.id,\n            ticket_id : d.ticket_id ? d.ticket_id : 0\n            \n        },\n        success : function(res)\n        {\n            // everythings fine..\n            \n            // we have to update the view object... now...\n            // we can not reload as that may blank out data..\n            if (!rec.data.id) {\n                Roo.log(\"Setting data id to \" + res.data.id);\n                rec.set('id', res.data.id);\n\n            }\n\n            \n        },\n        failure : function()\n        {\n            effort++;\n            if (effort > 3) {\n                Roo.MessageBox.alert(\"Error\", \"Saving timesheet failed\");\n                return;\n            }\n            _this.form.saveActive(rec, effort);\n        }\n        \n     });\n}\n",
368                                                             "|url": "baseURL + '/Roo/cash_invoice_entry.php'",
369                                                             "|xns": "Roo.form",
370                                                             "items": [
371                                                                 {
372                                                                     "listeners": {
373                                                                         "render": "function (_self)\n{\n    _this.projectSel = _self;\n}",
374                                                                         "beforeselect": "function (combo, record, index)\n{\n\n    Roo.log('save it');\n    var sel = _this.grid.ds.selectedBar();\n \n    if (!sel) {\n        Roo.log(\"nothing selected?\");\n        return;\n    }\n     \n    // active record should be the same thing.\n    sel.set('project_id', record.data.id);\n    sel.set('project_id_code',     record.data.code);\n    sel.set('project_id_name',   record.data.name);\n    \n    \n    _this.grid.ds.updateBar(sel);\n    \n      \n     \n}"
375                                                                     },
376                                                                     "allowBlank": "false",
377                                                                     "displayField": "name",
378                                                                     "editable": "false",
379                                                                     "emptyText": "Select Project",
380                                                                     "fieldLabel": "Project",
381                                                                     "forceSelection": true,
382                                                                     "hiddenName": "project_id",
383                                                                     "listWidth": 400,
384                                                                     "loadingText": "Searching...",
385                                                                     "minChars": 2,
386                                                                     "name": "project_id_name",
387                                                                     "pageSize": 20,
388                                                                     "qtip": "Select Projects",
389                                                                     "queryParam": "query[name]",
390                                                                     "selectOnFocus": true,
391                                                                     "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{code}</b> - {name}</div>",
392                                                                     "triggerAction": "all",
393                                                                     "typeAhead": true,
394                                                                     "valueField": "id",
395                                                                     "width": 200,
396                                                                     "xtype": "ComboBox",
397                                                                     "|xns": "Roo.form",
398                                                                     "items": [
399                                                                         {
400                                                                             "listeners": {
401                                                                                 "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n    o.params['query[project_filter]'] = 'P,N,U'; // actually this is the default.\n    \n    // set more here\n}\n"
402                                                                             },
403                                                                             "*prop": "store",
404                                                                             "remoteSort": true,
405                                                                             "xtype": "Store",
406                                                                             "|sortInfo": "{ field: 'code', direction: 'ASC' }",
407                                                                             "|xns": "Roo.data",
408                                                                             "items": [
409                                                                                 {
410                                                                                     "*prop": "proxy",
411                                                                                     "xtype": "HttpProxy",
412                                                                                     "method": "GET",
413                                                                                     "|xns": "Roo.data",
414                                                                                     "|url": "baseURL + '/Roo/Projects.php'"
415                                                                                 },
416                                                                                 {
417                                                                                     "*prop": "reader",
418                                                                                     "xtype": "JsonReader",
419                                                                                     "|xns": "Roo.data",
420                                                                                     "id": "id",
421                                                                                     "root": "data",
422                                                                                     "totalProperty": "total",
423                                                                                     "|fields": "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]"
424                                                                                 }
425                                                                             ]
426                                                                         }
427                                                                     ]
428                                                                 },
429                                                                 {
430                                                                     "labelAlign": "top",
431                                                                     "width": 300,
432                                                                     "xtype": "Column",
433                                                                     "|xns": "Roo.form",
434                                                                     "items": [
435                                                                         {
436                                                                             "listeners": {
437                                                                                 "keyup": "function (_self, e)\n{\n    _this.selectedRec.set('description',   this.getValue());\n    _this.grid.dataSource.updateBar(_this.selectedRec);\n \n}"
438                                                                             },
439                                                                             "fieldLabel": "Description",
440                                                                             "height": 120,
441                                                                             "name": "description",
442                                                                             "width": 300,
443                                                                             "xtype": "TextArea",
444                                                                             "|xns": "Roo.form"
445                                                                         }
446                                                                     ]
447                                                                 },
448                                                                 {
449                                                                     "name": "action",
450                                                                     "xtype": "Hidden",
451                                                                     "|xns": "Roo.form"
452                                                                 },
453                                                                 {
454                                                                     "name": "staff_id",
455                                                                     "xtype": "Hidden",
456                                                                     "|xns": "Roo.form"
457                                                                 },
458                                                                 {
459                                                                     "name": "qtyvalue",
460                                                                     "xtype": "Hidden",
461                                                                     "|xns": "Roo.form"
462                                                                 },
463                                                                 {
464                                                                     "name": "qtyvalue2",
465                                                                     "xtype": "Hidden",
466                                                                     "|xns": "Roo.form"
467                                                                 },
468                                                                 {
469                                                                     "name": "entry_dt",
470                                                                     "xtype": "Hidden",
471                                                                     "|xns": "Roo.form"
472                                                                 },
473                                                                 {
474                                                                     "name": "action_dt",
475                                                                     "xtype": "Hidden",
476                                                                     "|xns": "Roo.form"
477                                                                 },
478                                                                 {
479                                                                     "name": "id",
480                                                                     "|xns": "Roo.form",
481                                                                     "xtype": "Hidden"
482                                                                 }
483                                                             ]
484                                                         }
485                                                     ]
486                                                 }
487                                             ]
488                                         }
489                                     ]
490                                 }
491                             ]
492                         }
493                     ]
494                 },
495                 {
496                     "region": "center",
497                     "title": "Plan Time",
498                     "xtype": "NestedLayoutPanel",
499                     "|xns": "Roo",
500                     "items": [
501                         {
502                             "|xns": "Roo",
503                             "xtype": "BorderLayout",
504                             "*prop": "layout",
505                             "items": [
506                                 {
507                                     "*prop": "west",
508                                     "title": "Open Tasks (Unassigned) / Select Project",
509                                     "width": 450,
510                                     "xtype": "LayoutRegion",
511                                     "|xns": "Roo"
512                                 },
513                                 {
514                                     "*prop": "center",
515                                     "title": "Assigned to  / Prioritized (all projects)",
516                                     "xtype": "LayoutRegion",
517                                     "|xns": "Roo"
518                                 },
519                                 {
520                                     "listeners": {
521                                         "|activate": "function() {\n    _this.openpanel = this;\n    if (_this.opengrid) {\n   //    _this.opengrid.footer.onClick('first');\n    }\n}"
522                                     },
523                                     "background": false,
524                                     "fitContainer": true,
525                                     "fitToframe": true,
526                                     "region": "west",
527                                     "tableName": "mtrack_ticket",
528                                     "title": "mtrack_ticket",
529                                     "xtype": "GridPanel",
530                                     "|xns": "Roo",
531                                     "items": [
532                                         {
533                                             "listeners": {
534                                                 "|render": "function() \n{\n    _this.opengrid = this; \n    //_this.dialog = Pman.Dialog.FILL_IN\n    if (_this.openpanel.active) {\n       //this.footer.onClick('first');\n    }\n}",
535                                                 "|rowdblclick": "function (_self, rowIndex, e)\n{\n    if (!_this.dialog) return;\n    _this.dialog.show( this.getDataSource().getAt(rowIndex), function() {\n        _this.grid.footer.onClick('first');\n    }); \n}\n"
536                                             },
537                                             "*prop": "grid",
538                                             "autoExpandColumn": "summary",
539                                             "loadMask": true,
540                                             "xtype": "Grid",
541                                             "|xns": "Roo.grid",
542                                             "items": [
543                                                 {
544                                                     "|xns": "Roo",
545                                                     "xtype": "Toolbar",
546                                                     "*prop": "toolbar",
547                                                     "items": [
548                                                         {
549                                                             "displayField": "",
550                                                             "editable": "false",
551                                                             "emptyText": "Select Project",
552                                                             "fieldLabel": "mtrack_ticket",
553                                                             "forceSelection": true,
554                                                             "hiddenName": "",
555                                                             "listWidth": 400,
556                                                             "loadingText": "Searching...",
557                                                             "minChars": 2,
558                                                             "name": "",
559                                                             "pageSize": 20,
560                                                             "qtip": "Select mtrack_ticket",
561                                                             "queryParam": "",
562                                                             "selectOnFocus": true,
563                                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> </div>",
564                                                             "triggerAction": "all",
565                                                             "typeAhead": true,
566                                                             "valueField": "id",
567                                                             "width": 300,
568                                                             "xtype": "ComboBox",
569                                                             "|xns": "Roo.form",
570                                                             "items": [
571                                                                 {
572                                                                     "*prop": "store",
573                                                                     "xtype": "Store",
574                                                                     "|xns": "Roo.data",
575                                                                     "remoteSort": true,
576                                                                     "|sortInfo": "{ direction : 'ASC', field: 'id' }",
577                                                                     "listeners": {
578                                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n}\n"
579                                                                     },
580                                                                     "items": [
581                                                                         {
582                                                                             "*prop": "proxy",
583                                                                             "xtype": "HttpProxy",
584                                                                             "method": "GET",
585                                                                             "|xns": "Roo.data",
586                                                                             "|url": "baseURL + '/Roo/mtrack_ticket.php'"
587                                                                         },
588                                                                         {
589                                                                             "*prop": "reader",
590                                                                             "xtype": "JsonReader",
591                                                                             "|xns": "Roo.data",
592                                                                             "id": "id",
593                                                                             "root": "data",
594                                                                             "totalProperty": "total",
595                                                                             "|fields": "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"summary\",\"type\":\"string\"}]"
596                                                                         }
597                                                                     ]
598                                                                 }
599                                                             ]
600                                                         }
601                                                     ]
602                                                 },
603                                                 {
604                                                     "*prop": "dataSource",
605                                                     "xtype": "Store",
606                                                     "remoteSort": true,
607                                                     "|sortInfo": "{ field : 'summary', direction: 'ASC' }",
608                                                     "|xns": "Roo.data",
609                                                     "items": [
610                                                         {
611                                                             "*prop": "proxy",
612                                                             "xtype": "HttpProxy",
613                                                             "method": "GET",
614                                                             "|url": "baseURL + '/Roo/mtrack_ticket.php'",
615                                                             "|xns": "Roo.data"
616                                                         },
617                                                         {
618                                                             "|xns": "Roo.data",
619                                                             "xtype": "JsonReader",
620                                                             "totalProperty": "total",
621                                                             "root": "data",
622                                                             "*prop": "reader",
623                                                             "id": "id",
624                                                             "|fields": "[\n    {\n        'name': 'id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'summary',\n        'type': 'string'\n    },\n    {\n        'name': 'description',\n        'type': 'string'\n    },\n    {\n        'name': 'changelog',\n        'type': 'string'\n    },\n    {\n        'name': 'created',\n        'type': 'int'\n    },\n    {\n        'name': 'updated',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id',\n        'type': 'int'\n    },\n    {\n        'name': 'cc',\n        'type': 'string'\n    },\n    {\n        'name': 'status',\n        'type': 'int'\n    },\n    {\n        'name': 'estimated',\n        'type': 'float'\n    },\n    {\n        'name': 'spent',\n        'type': 'float'\n    },\n    {\n        'name': 'x_fieldname',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_person_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_ontable',\n        'type': 'string'\n    },\n    {\n        'name': 'updated_onid',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_changedate',\n        'type': 'date'\n    },\n    {\n        'name': 'updated_reason',\n        'type': 'string'\n    },\n    {\n        'name': 'created_id',\n        'type': 'int'\n    },\n    {\n        'name': 'created_person_id',\n        'type': 'int'\n    },\n    {\n        'name': 'created_ontable',\n        'type': 'string'\n    },\n    {\n        'name': 'created_onid',\n        'type': 'int'\n    },\n    {\n        'name': 'created_changedate',\n        'type': 'date'\n    },\n    {\n        'name': 'created_reason',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_office_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_phone',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_fax',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_email',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_company_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_role',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_passwd',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_lang',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_no_reset_sent',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_action_type',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_deleted_by',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_deleted_dt',\n        'type': 'date'\n    },\n    {\n        'name': 'developer_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_office_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_phone',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_fax',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_email',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_company_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_role',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_passwd',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_lang',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_no_reset_sent',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_action_type',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_deleted_by',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_deleted_dt',\n        'type': 'date'\n    },\n    {\n        'name': 'priority_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'priority_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'priority_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'severity_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'severity_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'classification_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'classification_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'resolution_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'resolution_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'status_id',\n        'type': 'int'\n    },\n    {\n        'name': 'status_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'status_name',\n        'type': 'string'\n    },\n    {\n        'name': 'status_active',\n        'type': 'int'\n    },\n    {\n        'name': 'status_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_code',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_type',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_client_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_team_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_file_location',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_open_date',\n        'type': 'date'\n    },\n    {\n        'name': 'project_id_open_by',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_close_date',\n        'type': 'date'\n    },\n    {\n        'name': 'project_id_countries',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_languages',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_agency_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'milestone_id_description',\n        'type': 'string'\n    },\n    {\n        'name': 'milestone_id_startdate',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_duedate',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_completed',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_deleted',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_created',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_updated',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_project_id',\n        'type': 'int'\n    }\n]"
625                                                         }
626                                                     ]
627                                                 },
628                                                 {
629                                                     "xtype": "ColumnModel",
630                                                     "header": "Summary",
631                                                     "width": 200,
632                                                     "dataIndex": "summary",
633                                                     "|renderer": "function(v) { return String.format('{0}', v); }",
634                                                     "|xns": "Roo.grid",
635                                                     "*prop": "colModel[]"
636                                                 }
637                                             ]
638                                         }
639                                     ]
640                                 },
641                                 {
642                                     "listeners": {
643                                         "|activate": "function() {\n    _this.openpanel = this;\n    if (_this.opengrid) {\n   //    _this.opengrid.footer.onClick('first');\n    }\n}"
644                                     },
645                                     "background": false,
646                                     "fitContainer": true,
647                                     "fitToframe": true,
648                                     "region": "center",
649                                     "tableName": "mtrack_ticket",
650                                     "title": "mtrack_ticket",
651                                     "xtype": "GridPanel",
652                                     "|xns": "Roo",
653                                     "items": [
654                                         {
655                                             "listeners": {
656                                                 "|render": "function() \n{\n    _this.opengrid = this; \n    //_this.dialog = Pman.Dialog.FILL_IN\n    if (_this.openpanel.active) {\n       //this.footer.onClick('first');\n    }\n}",
657                                                 "|rowdblclick": "function (_self, rowIndex, e)\n{\n    if (!_this.dialog) return;\n    _this.dialog.show( this.getDataSource().getAt(rowIndex), function() {\n        _this.grid.footer.onClick('first');\n    }); \n}\n"
658                                             },
659                                             "*prop": "grid",
660                                             "autoExpandColumn": "summary",
661                                             "loadMask": true,
662                                             "xtype": "Grid",
663                                             "|xns": "Roo.grid",
664                                             "items": [
665                                                 {
666                                                     "|xns": "Roo",
667                                                     "xtype": "Toolbar",
668                                                     "*prop": "toolbar",
669                                                     "items": [
670                                                         {
671                                                             "displayField": "",
672                                                             "editable": "false",
673                                                             "emptyText": "Select Person",
674                                                             "fieldLabel": "mtrack_ticket",
675                                                             "forceSelection": true,
676                                                             "hiddenName": "",
677                                                             "listWidth": 400,
678                                                             "loadingText": "Searching...",
679                                                             "minChars": 2,
680                                                             "name": "",
681                                                             "pageSize": 20,
682                                                             "qtip": "Select mtrack_ticket",
683                                                             "queryParam": "",
684                                                             "selectOnFocus": true,
685                                                             "tpl": "<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> </div>",
686                                                             "triggerAction": "all",
687                                                             "typeAhead": true,
688                                                             "valueField": "id",
689                                                             "width": 300,
690                                                             "xtype": "ComboBox",
691                                                             "|xns": "Roo.form",
692                                                             "items": [
693                                                                 {
694                                                                     "*prop": "store",
695                                                                     "xtype": "Store",
696                                                                     "|xns": "Roo.data",
697                                                                     "remoteSort": true,
698                                                                     "|sortInfo": "{ direction : 'ASC', field: 'id' }",
699                                                                     "listeners": {
700                                                                         "|beforeload": "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n}\n"
701                                                                     },
702                                                                     "items": [
703                                                                         {
704                                                                             "*prop": "proxy",
705                                                                             "xtype": "HttpProxy",
706                                                                             "method": "GET",
707                                                                             "|xns": "Roo.data",
708                                                                             "|url": "baseURL + '/Roo/mtrack_ticket.php'"
709                                                                         },
710                                                                         {
711                                                                             "*prop": "reader",
712                                                                             "xtype": "JsonReader",
713                                                                             "|xns": "Roo.data",
714                                                                             "id": "id",
715                                                                             "root": "data",
716                                                                             "totalProperty": "total",
717                                                                             "|fields": "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"summary\",\"type\":\"string\"}]"
718                                                                         }
719                                                                     ]
720                                                                 }
721                                                             ]
722                                                         }
723                                                     ]
724                                                 },
725                                                 {
726                                                     "*prop": "dataSource",
727                                                     "xtype": "Store",
728                                                     "remoteSort": true,
729                                                     "|sortInfo": "{ field : 'summary', direction: 'ASC' }",
730                                                     "|xns": "Roo.data",
731                                                     "items": [
732                                                         {
733                                                             "*prop": "proxy",
734                                                             "xtype": "HttpProxy",
735                                                             "method": "GET",
736                                                             "|url": "baseURL + '/Roo/mtrack_ticket.php'",
737                                                             "|xns": "Roo.data"
738                                                         },
739                                                         {
740                                                             "|xns": "Roo.data",
741                                                             "xtype": "JsonReader",
742                                                             "totalProperty": "total",
743                                                             "root": "data",
744                                                             "*prop": "reader",
745                                                             "id": "id",
746                                                             "|fields": "[\n    {\n        'name': 'id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'summary',\n        'type': 'string'\n    },\n    {\n        'name': 'description',\n        'type': 'string'\n    },\n    {\n        'name': 'changelog',\n        'type': 'string'\n    },\n    {\n        'name': 'created',\n        'type': 'int'\n    },\n    {\n        'name': 'updated',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id',\n        'type': 'int'\n    },\n    {\n        'name': 'cc',\n        'type': 'string'\n    },\n    {\n        'name': 'status',\n        'type': 'int'\n    },\n    {\n        'name': 'estimated',\n        'type': 'float'\n    },\n    {\n        'name': 'spent',\n        'type': 'float'\n    },\n    {\n        'name': 'x_fieldname',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_person_id',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_ontable',\n        'type': 'string'\n    },\n    {\n        'name': 'updated_onid',\n        'type': 'int'\n    },\n    {\n        'name': 'updated_changedate',\n        'type': 'date'\n    },\n    {\n        'name': 'updated_reason',\n        'type': 'string'\n    },\n    {\n        'name': 'created_id',\n        'type': 'int'\n    },\n    {\n        'name': 'created_person_id',\n        'type': 'int'\n    },\n    {\n        'name': 'created_ontable',\n        'type': 'string'\n    },\n    {\n        'name': 'created_onid',\n        'type': 'int'\n    },\n    {\n        'name': 'created_changedate',\n        'type': 'date'\n    },\n    {\n        'name': 'created_reason',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_office_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_phone',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_fax',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_email',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_company_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_role',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_passwd',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_lang',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_no_reset_sent',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_action_type',\n        'type': 'string'\n    },\n    {\n        'name': 'owner_id_project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_deleted_by',\n        'type': 'int'\n    },\n    {\n        'name': 'owner_id_deleted_dt',\n        'type': 'date'\n    },\n    {\n        'name': 'developer_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_office_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_phone',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_fax',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_email',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_company_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_role',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_passwd',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_lang',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_no_reset_sent',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_action_type',\n        'type': 'string'\n    },\n    {\n        'name': 'developer_id_project_id',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_deleted_by',\n        'type': 'int'\n    },\n    {\n        'name': 'developer_id_deleted_dt',\n        'type': 'date'\n    },\n    {\n        'name': 'priority_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'priority_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'priority_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'priority_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'severity_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'severity_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'severity_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'classification_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'classification_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'classification_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'resolution_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'resolution_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'resolution_id_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'status_id',\n        'type': 'int'\n    },\n    {\n        'name': 'status_etype',\n        'type': 'string'\n    },\n    {\n        'name': 'status_name',\n        'type': 'string'\n    },\n    {\n        'name': 'status_active',\n        'type': 'int'\n    },\n    {\n        'name': 'status_seqid',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_remarks',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_owner_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_code',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_active',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_type',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_client_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_team_id',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_file_location',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_open_date',\n        'type': 'date'\n    },\n    {\n        'name': 'project_id_open_by',\n        'type': 'int'\n    },\n    {\n        'name': 'project_id_close_date',\n        'type': 'date'\n    },\n    {\n        'name': 'project_id_countries',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_languages',\n        'type': 'string'\n    },\n    {\n        'name': 'project_id_agency_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_id',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_name',\n        'type': 'string'\n    },\n    {\n        'name': 'milestone_id_description',\n        'type': 'string'\n    },\n    {\n        'name': 'milestone_id_startdate',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_duedate',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_completed',\n        'type': 'date'\n    },\n    {\n        'name': 'milestone_id_deleted',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_created',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_updated',\n        'type': 'int'\n    },\n    {\n        'name': 'milestone_id_project_id',\n        'type': 'int'\n    }\n]"
747                                                         }
748                                                     ]
749                                                 },
750                                                 {
751                                                     "xtype": "ColumnModel",
752                                                     "header": "Summary",
753                                                     "width": 200,
754                                                     "dataIndex": "summary",
755                                                     "|renderer": "function(v) { return String.format('{0}', v); }",
756                                                     "|xns": "Roo.grid",
757                                                     "*prop": "colModel[]"
758                                                 }
759                                             ]
760                                         }
761                                     ]
762                                 }
763                             ]
764                         }
765                     ]
766                 }
767             ]
768         }
769     ],
770     "permname": "",
771     "modOrder": "001"
772 }