php warnings
[Pman.MTrack] / Pman.Dialog.MTrackTime.bjs
1 {
2  "name" : "Pman.Dialog.MTrackTime",
3  "parent" : "",
4  "title" : "",
5  "path" : "/home/alan/gitlive/Pman.MTrack/Pman.Dialog.MTrackTime.bjs",
6  "permname" : "",
7  "modOrder" : "001",
8  "strings" : {
9   "9a221c25cceeb0d108ff6cb635dc8b8b" : "Open Tasks (Unassigned) / Select Project",
10   "9e727fdd3aec8274f46685441900280d" : "Project",
11   "6a58f977f2b623b695a340766f2a6843" : "Select Project",
12   "74cf22d20dea80f7bd8800a6da89a722" : "Select mtrack_ticket",
13   "c751439d0db3883ac1c8e816327adcab" : "Ticket",
14   "290612199861c31d1036b185b4e69b75" : "Summary",
15   "1fa1f1ccb57b2486b4c05122d64868d4" : "Not on Project work",
16   "6cca3734b44a6ae61b40c9a915d122f4" : "Task Queue",
17   "ed7b9312345d291c1ccf68096e65ca54" : "Ticket Details",
18   "1243daf593fa297e07ab03bf06d925af" : "Searching...",
19   "645fcdd1616f8c7dbb207f6802786431" : "Time Manager",
20   "329a87b3fae81c1c17a185c78d2e0e63" : "cash_invoice_entry",
21   "9deec6a3dfda06500b808d70875f0a8f" : "Log Time",
22   "40bed7cf9b3d4bb3a3d7a7e3eb18c5eb" : "Person",
23   "340c2ee497b85d5954b01c64de7f44f6" : "Select Person",
24   "f4c6f851b00d5518bf888815de279aba" : "Notes",
25   "24f27bda5dd2c488aa9bc7700ba98c34" : "Select Projects",
26   "07ca5050e697392c9ed47e6453f1453f" : "Completed",
27   "a76d4ef5f3f6a672bbfab2865563e530" : "Time",
28   "b5a7adde1af5c87d7fd797b6245c2a39" : "Description",
29   "642f8356fcf65868f037f92e0e10c3cd" : "Plan Time",
30   "9e51cf61fbb08a10c12619611dc818ad" : "Active / Logged Time",
31   "3efbc55730fd4af147b96183d8afbd3b" : "mtrack_ticket",
32   "b2439dea1dd89e6f694df484214e57cf" : "Working on this",
33   "f49f927095bb01b44c96d29c8c09f3a3" : "Assigned to  / Prioritized (all projects)"
34  },
35  "named_strings" : {
36   "description_fieldLabel" : "b5a7adde1af5c87d7fd797b6245c2a39",
37   "project_id_name_emptyText" : "6a58f977f2b623b695a340766f2a6843",
38   "project_id_name_loadingText" : "1243daf593fa297e07ab03bf06d925af",
39   "project_id_name_qtip" : "24f27bda5dd2c488aa9bc7700ba98c34",
40   "project_id_name_fieldLabel" : "9e727fdd3aec8274f46685441900280d"
41  },
42  "items" : [
43   {
44    "title" : "Time Manager",
45    "xtype" : "LayoutDialog",
46    "width" : 1000,
47    "$ xns" : "Roo",
48    "height" : 700,
49    "items" : [
50     {
51      "xtype" : "LayoutRegion",
52      "$ xns" : "Roo",
53      "tabPosition" : "top",
54      "* prop" : "center"
55     },
56     {
57      "region" : "center",
58      "title" : "Log Time",
59      "xtype" : "NestedLayoutPanel",
60      "$ xns" : "Roo",
61      "items" : [
62       {
63        "xtype" : "BorderLayout",
64        "$ xns" : "Roo",
65        "* prop" : "layout",
66        "items" : [
67         {
68          "xtype" : "LayoutRegion",
69          "$ xns" : "Roo",
70          "width" : 600,
71          "split" : true,
72          "* prop" : "west"
73         },
74         {
75          "xtype" : "LayoutRegion",
76          "title" : "Active / Logged Time",
77          "$ xns" : "Roo",
78          "* prop" : "center"
79         },
80         {
81          "collapsedTitle" : "Ticket Details",
82          "collapsible" : true,
83          "title" : "Ticket Details",
84          "xtype" : "LayoutRegion",
85          "collapsed" : true,
86          "width" : 350,
87          "$ xns" : "Roo",
88          "split" : true,
89          "* prop" : "east"
90         },
91         {
92          "listeners" : {
93           "|activate" : "function() {\n    _this.timepanel = this;\n    if (_this.timegrid) {\n       // _this.grid.footer.onClick('first');\n    }\n}"
94          },
95          "region" : "west",
96          "fitToframe" : true,
97          "background" : true,
98          "title" : "cash_invoice_entry",
99          "xtype" : "GridPanel",
100          "fitContainer" : true,
101          "$ xns" : "Roo",
102          "tableName" : "cash_invoice_entry",
103          "items" : [
104           {
105            "listeners" : {
106             "|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",
107             "|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}"
108            },
109            "autoExpandColumn" : "activity_ref",
110            "xtype" : "Grid",
111            "loadMask" : true,
112            "$ xns" : "Roo.grid",
113            "* prop" : "grid",
114            "items" : [
115             {
116              "xtype" : "Toolbar",
117              "$ xns" : "Roo",
118              "* prop" : "toolbar",
119              "items" : [
120               {
121                "listeners" : {
122                 "render" : "function (_self)\n{\n        _this.personSelect = _self;\n}"
123                },
124                "listWidth" : 400,
125                "triggerAction" : "all",
126                "fieldLabel" : "Person",
127                "forceSelection" : true,
128                "selectOnFocus" : true,
129                "pageSize" : 20,
130                "displayField" : "name",
131                "emptyText" : "Select Person",
132                "hiddenName" : "",
133                "minChars" : 2,
134                "valueField" : "id",
135                "xtype" : "ComboBox",
136                "allowBlank" : false,
137                "typeAhead" : true,
138                "editable" : false,
139                "width" : 300,
140                "$ xns" : "Roo.form",
141                "name" : "",
142                "qtip" : "Select Person",
143                "queryParam" : "",
144                "tpl" : "<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> {email} </div>",
145                "loadingText" : "Searching...",
146                "items" : [
147                 {
148                  "listeners" : {
149                   "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n    o.params.company_id_comptype = 'OWNER';\n}\n"
150                  },
151                  "xtype" : "Store",
152                  "remoteSort" : true,
153                  "$ sortInfo" : "{ direction : 'ASC', field: 'id' }",
154                  "$ xns" : "Roo.data",
155                  "* prop" : "store",
156                  "items" : [
157                   {
158                    "$ url" : "baseURL + '/Roo/Person.php'",
159                    "xtype" : "HttpProxy",
160                    "method" : "GET",
161                    "$ xns" : "Roo.data",
162                    "* prop" : "proxy"
163                   },
164                   {
165                    "id" : "id",
166                    "root" : "data",
167                    "xtype" : "JsonReader",
168                    "$ xns" : "Roo.data",
169                    "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]",
170                    "* prop" : "reader",
171                    "totalProperty" : "total"
172                   }
173                  ]
174                 }
175                ]
176               }
177              ]
178             },
179             {
180              "xtype" : "Store",
181              "remoteSort" : true,
182              "$ sortInfo" : "{ field : 'action_dt', direction: 'DESC' }",
183              "$ xns" : "Roo.data",
184              "* prop" : "dataSource",
185              "items" : [
186               {
187                "listeners" : {
188                 "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}"
189                },
190                "$ url" : "baseURL + '/Roo/cash_invoice_entry.php'",
191                "method" : "GET",
192                "xtype" : "HttpProxy",
193                "$ xns" : "Roo.data",
194                "* prop" : "proxy"
195               },
196               {
197                "id" : "id",
198                "root" : "data",
199                "xtype" : "JsonReader",
200                "$ xns" : "Roo.data",
201                "$ 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]",
202                "* prop" : "reader",
203                "totalProperty" : "total"
204               }
205              ]
206             },
207             {
208              "xtype" : "ColumnModel",
209              "width" : 100,
210              "header" : "Time",
211              "$ 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}-{2}',\n         v.format('D'), v.format('H:i'), end.format('H:i') );\n}",
212              "$ xns" : "Roo.grid",
213              "* prop" : "colModel[]",
214              "dataIndex" : "action_dt"
215             },
216             {
217              "xtype" : "ColumnModel",
218              "width" : 200,
219              "header" : "Ticket",
220              "$ renderer" : "function(v) { return String.format('{0}', v ? v.format('d/M/Y') : ''); }",
221              "$ xns" : "Roo.grid",
222              "* prop" : "colModel[]",
223              "dataIndex" : "ticket_id_summary"
224             },
225             {
226              "xtype" : "ColumnModel",
227              "width" : 300,
228              "header" : "Notes",
229              "$ renderer" : "function(v) { return String.format('{0}', v ? v.format('d/M/Y') : ''); }",
230              "$ xns" : "Roo.grid",
231              "* prop" : "colModel[]",
232              "dataIndex" : "notes"
233             }
234            ]
235           }
236          ]
237         },
238         {
239          "region" : "center",
240          "xtype" : "NestedLayoutPanel",
241          "$ xns" : "Roo",
242          "items" : [
243           {
244            "xtype" : "BorderLayout",
245            "$ xns" : "Roo",
246            "* prop" : "layout",
247            "items" : [
248             {
249              "xtype" : "LayoutRegion",
250              "$ xns" : "Roo",
251              "* prop" : "north",
252              "height" : 200
253             },
254             {
255              "xtype" : "LayoutRegion",
256              "title" : "Task Queue",
257              "$ xns" : "Roo",
258              "* prop" : "center"
259             },
260             {
261              "listeners" : {
262               "|activate" : "function() {\n    _this.queuepanel = this;\n    if (_this.queuegrid) {\n        //_this.queuegrid.footer.onClick('first');\n    }\n}"
263              },
264              "region" : "center",
265              "fitToframe" : true,
266              "background" : true,
267              "title" : "mtrack_ticket",
268              "xtype" : "GridPanel",
269              "fitContainer" : true,
270              "$ xns" : "Roo",
271              "tableName" : "mtrack_ticket",
272              "items" : [
273               {
274                "listeners" : {
275                 "|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",
276                 "|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}"
277                },
278                "autoExpandColumn" : "summary",
279                "xtype" : "Grid",
280                "loadMask" : true,
281                "$ xns" : "Roo.grid",
282                "* prop" : "grid",
283                "items" : [
284                 {
285                  "xtype" : "Toolbar",
286                  "$ xns" : "Roo",
287                  "* prop" : "toolbar",
288                  "items" : [
289                   {
290                    "listeners" : {
291                     "render" : "function (_self)\n{\n    _this.projectSel = _self;\n}",
292                     "beforeselect" : "function (combo, record, index)\n{\n\n     \n    _this.queuegrid.ds.load({});\n    \n      \n     \n}"
293                    },
294                    "listWidth" : 400,
295                    "triggerAction" : "all",
296                    "fieldLabel" : "Project",
297                    "forceSelection" : true,
298                    "selectOnFocus" : true,
299                    "pageSize" : 20,
300                    "displayField" : "name",
301                    "emptyText" : "Select Project",
302                    "hiddenName" : "project_id",
303                    "minChars" : 2,
304                    "valueField" : "id",
305                    "xtype" : "ComboBox",
306                    "allowBlank" : false,
307                    "typeAhead" : true,
308                    "editable" : false,
309                    "width" : 200,
310                    "$ xns" : "Roo.form",
311                    "name" : "project_id_name",
312                    "qtip" : "Select Projects",
313                    "queryParam" : "query[name]",
314                    "tpl" : "<div class=\"x-grid-cell-text x-btn button\"><b>{code}</b> - {name}</div>",
315                    "loadingText" : "Searching...",
316                    "items" : [
317                     {
318                      "listeners" : {
319                       "|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"
320                      },
321                      "xtype" : "Store",
322                      "remoteSort" : true,
323                      "$ sortInfo" : "{ field: 'code', direction: 'ASC' }",
324                      "$ xns" : "Roo.data",
325                      "* prop" : "store",
326                      "items" : [
327                       {
328                        "$ url" : "baseURL + '/Roo/Projects.php'",
329                        "xtype" : "HttpProxy",
330                        "method" : "GET",
331                        "$ xns" : "Roo.data",
332                        "* prop" : "proxy"
333                       },
334                       {
335                        "id" : "id",
336                        "root" : "data",
337                        "xtype" : "JsonReader",
338                        "$ xns" : "Roo.data",
339                        "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]",
340                        "* prop" : "reader",
341                        "totalProperty" : "total"
342                       }
343                      ]
344                     }
345                    ]
346                   }
347                  ]
348                 },
349                 {
350                  "remoteSort" : true,
351                  "xtype" : "Store",
352                  "$ sortInfo" : "{ field : 'summary', direction: 'ASC' }",
353                  "$ xns" : "Roo.data",
354                  "* prop" : "dataSource",
355                  "items" : [
356                   {
357                    "$ url" : "baseURL + '/Roo/mtrack_ticket.php'",
358                    "xtype" : "HttpProxy",
359                    "method" : "GET",
360                    "$ xns" : "Roo.data",
361                    "* prop" : "proxy"
362                   },
363                   {
364                    "id" : "id",
365                    "root" : "data",
366                    "xtype" : "JsonReader",
367                    "$ xns" : "Roo.data",
368                    "$ 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]",
369                    "* prop" : "reader",
370                    "totalProperty" : "total"
371                   }
372                  ]
373                 },
374                 {
375                  "xtype" : "ColumnModel",
376                  "header" : "Summary",
377                  "width" : 200,
378                  "$ renderer" : "function(v) { return String.format('{0}', v); }",
379                  "$ xns" : "Roo.grid",
380                  "* prop" : "colModel[]",
381                  "dataIndex" : "summary"
382                 }
383                ]
384               }
385              ]
386             },
387             {
388              "region" : "north",
389              "xtype" : "ContentPanel",
390              "$ xns" : "Roo",
391              "items" : [
392               {
393                "xtype" : "Toolbar",
394                "$ xns" : "Roo",
395                "* prop" : "toolbar",
396                "items" : [
397                 {
398                  "text" : "Working on this",
399                  "xtype" : "Button",
400                  "$ xns" : "Roo.Toolbar"
401                 },
402                 {
403                  "text" : "Completed",
404                  "xtype" : "Button",
405                  "$ xns" : "Roo.Toolbar"
406                 },
407                 {
408                  "text" : "Not on Project work",
409                  "xtype" : "Button",
410                  "$ xns" : "Roo.Toolbar"
411                 }
412                ]
413               },
414               {
415                "listeners" : {
416                 "|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",
417                 "|rendered" : "function (form)\n{\n    _this.form= form;\n}\n"
418                },
419                "$ url" : "baseURL + '/Roo/cash_invoice_entry.php'",
420                "$ 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",
421                "activeData" : false,
422                "style" : "margin-left:10px;",
423                "method" : "POST",
424                "xtype" : "Form",
425                "$ xns" : "Roo.form",
426                "items" : [
427                 {
428                  "listeners" : {
429                   "render" : "function (_self)\n{\n    _this.projectSel = _self;\n}",
430                   "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}"
431                  },
432                  "listWidth" : 400,
433                  "triggerAction" : "all",
434                  "fieldLabel" : "Project",
435                  "forceSelection" : true,
436                  "selectOnFocus" : true,
437                  "pageSize" : 20,
438                  "displayField" : "name",
439                  "emptyText" : "Select Project",
440                  "hiddenName" : "project_id",
441                  "minChars" : 2,
442                  "valueField" : "id",
443                  "xtype" : "ComboBox",
444                  "allowBlank" : false,
445                  "typeAhead" : true,
446                  "editable" : false,
447                  "width" : 200,
448                  "$ xns" : "Roo.form",
449                  "name" : "project_id_name",
450                  "qtip" : "Select Projects",
451                  "queryParam" : "query[name]",
452                  "tpl" : "<div class=\"x-grid-cell-text x-btn button\"><b>{code}</b> - {name}</div>",
453                  "loadingText" : "Searching...",
454                  "items" : [
455                   {
456                    "listeners" : {
457                     "|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"
458                    },
459                    "xtype" : "Store",
460                    "remoteSort" : true,
461                    "$ sortInfo" : "{ field: 'code', direction: 'ASC' }",
462                    "$ xns" : "Roo.data",
463                    "* prop" : "store",
464                    "items" : [
465                     {
466                      "$ url" : "baseURL + '/Roo/Projects.php'",
467                      "xtype" : "HttpProxy",
468                      "method" : "GET",
469                      "$ xns" : "Roo.data",
470                      "* prop" : "proxy"
471                     },
472                     {
473                      "id" : "id",
474                      "root" : "data",
475                      "xtype" : "JsonReader",
476                      "$ xns" : "Roo.data",
477                      "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]",
478                      "* prop" : "reader",
479                      "totalProperty" : "total"
480                     }
481                    ]
482                   }
483                  ]
484                 },
485                 {
486                  "labelAlign" : "top",
487                  "xtype" : "Column",
488                  "width" : 300,
489                  "$ xns" : "Roo.form",
490                  "items" : [
491                   {
492                    "listeners" : {
493                     "keyup" : "function (_self, e)\n{\n    _this.selectedRec.set('description',   this.getValue());\n    _this.grid.dataSource.updateBar(_this.selectedRec);\n \n}"
494                    },
495                    "fieldLabel" : "Description",
496                    "xtype" : "TextArea",
497                    "width" : 300,
498                    "$ xns" : "Roo.form",
499                    "name" : "description",
500                    "height" : 120
501                   }
502                  ]
503                 },
504                 {
505                  "xtype" : "Hidden",
506                  "$ xns" : "Roo.form",
507                  "name" : "action"
508                 },
509                 {
510                  "xtype" : "Hidden",
511                  "$ xns" : "Roo.form",
512                  "name" : "staff_id"
513                 },
514                 {
515                  "xtype" : "Hidden",
516                  "$ xns" : "Roo.form",
517                  "name" : "qtyvalue"
518                 },
519                 {
520                  "xtype" : "Hidden",
521                  "$ xns" : "Roo.form",
522                  "name" : "qtyvalue2"
523                 },
524                 {
525                  "xtype" : "Hidden",
526                  "$ xns" : "Roo.form",
527                  "name" : "entry_dt"
528                 },
529                 {
530                  "xtype" : "Hidden",
531                  "$ xns" : "Roo.form",
532                  "name" : "action_dt"
533                 },
534                 {
535                  "xtype" : "Hidden",
536                  "$ xns" : "Roo.form",
537                  "name" : "id"
538                 }
539                ]
540               }
541              ]
542             }
543            ]
544           }
545          ]
546         }
547        ]
548       }
549      ]
550     },
551     {
552      "region" : "center",
553      "title" : "Plan Time",
554      "xtype" : "NestedLayoutPanel",
555      "$ xns" : "Roo",
556      "items" : [
557       {
558        "xtype" : "BorderLayout",
559        "$ xns" : "Roo",
560        "* prop" : "layout",
561        "items" : [
562         {
563          "title" : "Open Tasks (Unassigned) / Select Project",
564          "xtype" : "LayoutRegion",
565          "width" : 450,
566          "$ xns" : "Roo",
567          "* prop" : "west"
568         },
569         {
570          "xtype" : "LayoutRegion",
571          "title" : "Assigned to  / Prioritized (all projects)",
572          "$ xns" : "Roo",
573          "* prop" : "center"
574         },
575         {
576          "listeners" : {
577           "|activate" : "function() {\n    _this.openpanel = this;\n    if (_this.opengrid) {\n   //    _this.opengrid.footer.onClick('first');\n    }\n}"
578          },
579          "region" : "west",
580          "fitToframe" : true,
581          "background" : false,
582          "title" : "mtrack_ticket",
583          "xtype" : "GridPanel",
584          "fitContainer" : true,
585          "$ xns" : "Roo",
586          "tableName" : "mtrack_ticket",
587          "items" : [
588           {
589            "listeners" : {
590             "|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",
591             "|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}"
592            },
593            "autoExpandColumn" : "summary",
594            "xtype" : "Grid",
595            "loadMask" : true,
596            "$ xns" : "Roo.grid",
597            "* prop" : "grid",
598            "items" : [
599             {
600              "xtype" : "Toolbar",
601              "$ xns" : "Roo",
602              "* prop" : "toolbar",
603              "items" : [
604               {
605                "listWidth" : 400,
606                "triggerAction" : "all",
607                "fieldLabel" : "mtrack_ticket",
608                "forceSelection" : true,
609                "selectOnFocus" : true,
610                "pageSize" : 20,
611                "emptyText" : "Select Project",
612                "displayField" : "",
613                "hiddenName" : "",
614                "minChars" : 2,
615                "valueField" : "id",
616                "xtype" : "ComboBox",
617                "typeAhead" : true,
618                "editable" : false,
619                "width" : 300,
620                "$ xns" : "Roo.form",
621                "name" : "",
622                "qtip" : "Select mtrack_ticket",
623                "queryParam" : "",
624                "tpl" : "<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> </div>",
625                "loadingText" : "Searching...",
626                "items" : [
627                 {
628                  "listeners" : {
629                   "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n}\n"
630                  },
631                  "xtype" : "Store",
632                  "remoteSort" : true,
633                  "$ xns" : "Roo.data",
634                  "$ sortInfo" : "{ direction : 'ASC', field: 'id' }",
635                  "* prop" : "store",
636                  "items" : [
637                   {
638                    "$ url" : "baseURL + '/Roo/mtrack_ticket.php'",
639                    "xtype" : "HttpProxy",
640                    "method" : "GET",
641                    "$ xns" : "Roo.data",
642                    "* prop" : "proxy"
643                   },
644                   {
645                    "id" : "id",
646                    "root" : "data",
647                    "xtype" : "JsonReader",
648                    "$ xns" : "Roo.data",
649                    "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"summary\",\"type\":\"string\"}]",
650                    "* prop" : "reader",
651                    "totalProperty" : "total"
652                   }
653                  ]
654                 }
655                ]
656               }
657              ]
658             },
659             {
660              "remoteSort" : true,
661              "xtype" : "Store",
662              "$ sortInfo" : "{ field : 'summary', direction: 'ASC' }",
663              "$ xns" : "Roo.data",
664              "* prop" : "dataSource",
665              "items" : [
666               {
667                "$ url" : "baseURL + '/Roo/mtrack_ticket.php'",
668                "xtype" : "HttpProxy",
669                "method" : "GET",
670                "$ xns" : "Roo.data",
671                "* prop" : "proxy"
672               },
673               {
674                "id" : "id",
675                "root" : "data",
676                "xtype" : "JsonReader",
677                "$ xns" : "Roo.data",
678                "$ 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]",
679                "* prop" : "reader",
680                "totalProperty" : "total"
681               }
682              ]
683             },
684             {
685              "xtype" : "ColumnModel",
686              "header" : "Summary",
687              "width" : 200,
688              "$ renderer" : "function(v) { return String.format('{0}', v); }",
689              "$ xns" : "Roo.grid",
690              "* prop" : "colModel[]",
691              "dataIndex" : "summary"
692             }
693            ]
694           }
695          ]
696         },
697         {
698          "listeners" : {
699           "|activate" : "function() {\n    _this.openpanel = this;\n    if (_this.opengrid) {\n   //    _this.opengrid.footer.onClick('first');\n    }\n}"
700          },
701          "region" : "center",
702          "fitToframe" : true,
703          "background" : false,
704          "title" : "mtrack_ticket",
705          "xtype" : "GridPanel",
706          "fitContainer" : true,
707          "$ xns" : "Roo",
708          "tableName" : "mtrack_ticket",
709          "items" : [
710           {
711            "listeners" : {
712             "|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",
713             "|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}"
714            },
715            "autoExpandColumn" : "summary",
716            "xtype" : "Grid",
717            "loadMask" : true,
718            "$ xns" : "Roo.grid",
719            "* prop" : "grid",
720            "items" : [
721             {
722              "xtype" : "Toolbar",
723              "$ xns" : "Roo",
724              "* prop" : "toolbar",
725              "items" : [
726               {
727                "listWidth" : 400,
728                "triggerAction" : "all",
729                "fieldLabel" : "mtrack_ticket",
730                "forceSelection" : true,
731                "selectOnFocus" : true,
732                "pageSize" : 20,
733                "emptyText" : "Select Person",
734                "displayField" : "",
735                "hiddenName" : "",
736                "minChars" : 2,
737                "valueField" : "id",
738                "xtype" : "ComboBox",
739                "typeAhead" : true,
740                "editable" : false,
741                "width" : 300,
742                "$ xns" : "Roo.form",
743                "name" : "",
744                "qtip" : "Select mtrack_ticket",
745                "queryParam" : "",
746                "tpl" : "<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> </div>",
747                "loadingText" : "Searching...",
748                "items" : [
749                 {
750                  "listeners" : {
751                   "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n}\n"
752                  },
753                  "xtype" : "Store",
754                  "remoteSort" : true,
755                  "$ xns" : "Roo.data",
756                  "$ sortInfo" : "{ direction : 'ASC', field: 'id' }",
757                  "* prop" : "store",
758                  "items" : [
759                   {
760                    "$ url" : "baseURL + '/Roo/mtrack_ticket.php'",
761                    "xtype" : "HttpProxy",
762                    "method" : "GET",
763                    "$ xns" : "Roo.data",
764                    "* prop" : "proxy"
765                   },
766                   {
767                    "id" : "id",
768                    "root" : "data",
769                    "xtype" : "JsonReader",
770                    "$ xns" : "Roo.data",
771                    "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"summary\",\"type\":\"string\"}]",
772                    "* prop" : "reader",
773                    "totalProperty" : "total"
774                   }
775                  ]
776                 }
777                ]
778               }
779              ]
780             },
781             {
782              "remoteSort" : true,
783              "xtype" : "Store",
784              "$ sortInfo" : "{ field : 'summary', direction: 'ASC' }",
785              "$ xns" : "Roo.data",
786              "* prop" : "dataSource",
787              "items" : [
788               {
789                "$ url" : "baseURL + '/Roo/mtrack_ticket.php'",
790                "xtype" : "HttpProxy",
791                "method" : "GET",
792                "$ xns" : "Roo.data",
793                "* prop" : "proxy"
794               },
795               {
796                "id" : "id",
797                "root" : "data",
798                "xtype" : "JsonReader",
799                "$ xns" : "Roo.data",
800                "$ 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]",
801                "* prop" : "reader",
802                "totalProperty" : "total"
803               }
804              ]
805             },
806             {
807              "xtype" : "ColumnModel",
808              "header" : "Summary",
809              "width" : 200,
810              "$ renderer" : "function(v) { return String.format('{0}', v); }",
811              "$ xns" : "Roo.grid",
812              "* prop" : "colModel[]",
813              "dataIndex" : "summary"
814             }
815            ]
816           }
817          ]
818         }
819        ]
820       }
821      ]
822     }
823    ]
824   }
825  ]
826 }