php warnings
[Pman.MTrack] / Pman.Dialog.MTrackTicket.bjs
1 {
2  "name" : "Pman.Dialog.MTrackTicket",
3  "parent" : "",
4  "title" : "",
5  "path" : "/home/alan/gitlive/Pman.MTrack/Pman.Dialog.MTrackTicket.bjs",
6  "permname" : "",
7  "modOrder" : "001",
8  "strings" : {
9   "a02a8093b46b8e647c29727fb50d67e4" : "Select milestone",
10   "672caf27f5363dc833bda5099775e891" : "Developer",
11   "9e727fdd3aec8274f46685441900280d" : "Project",
12   "6a58f977f2b623b695a340766f2a6843" : "Select Project",
13   "a5ffb2a210f259195a75e5abca8db4a2" : "Select mtrack_milestone",
14   "6c768695a8efb18436d5b7b4374cdb45" : "Select core_enum",
15   "007cc9547ae8884ad597cd92ba505422" : "Severity",
16   "86e9400686e8e080ef3c8995afb5eb86" : "Select Priority",
17   "ddcf50c29294d4414f3f7c1bbc892cb5" : "Resources",
18   "290612199861c31d1036b185b4e69b75" : "Summary",
19   "1cb251ec0d568de6a929b520c4aed8d1" : "text",
20   "5c9335b28e6277ddbe0137f04e5e58a7" : "Classification",
21   "3c311fbd0f9e51ce27b984f55164cf83" : "Estimated",
22   "1243daf593fa297e07ab03bf06d925af" : "Searching...",
23   "c4ca4238a0b923820dcc509a6f75849b" : "1",
24   "ea4788705e6873b424c65e91c2846b19" : "Cancel",
25   "502996d9790340c5fd7b86a5b93b1c9f" : "Priority",
26   "b6f4a2ec6356bbd56d49f2096bf9d3d3" : "Owner",
27   "ff18c41b7689060c39934dbb74de1e9c" : "Edit or Create Ticket",
28   "24f27bda5dd2c488aa9bc7700ba98c34" : "Select Projects",
29   "340c2ee497b85d5954b01c64de7f44f6" : "Select Person",
30   "23e6bcd09b259e6de4cd972516cb4214" : "View as",
31   "590fc197fe73db0aa2ec03687a372eea" : "markdown",
32   "e9c626b8a8b62de7562dfbf51a576ae5" : "Milestone",
33   "43371ce8259ba854b1ae3543fd477874" : "Select Severity",
34   "a8dbd02aaca3948002718aeb2babeefe" : "Summary / Details",
35   "9fc2d28c05ed9eb1d75ba4465abf15a9" : "Properties",
36   "b5a7adde1af5c87d7fd797b6245c2a39" : "Description",
37   "c9cc8cce247e49bae79f15173ce97354" : "Save",
38   "fcb17935fd52e65b8f223778c9e70313" : "Select Classification"
39  },
40  "named_strings" : {
41   "view_as_markdown_value" : "c4ca4238a0b923820dcc509a6f75849b",
42   "estimated_fieldLabel" : "3c311fbd0f9e51ce27b984f55164cf83",
43   "severity_id_name_loadingText" : "1243daf593fa297e07ab03bf06d925af",
44   "developer_id_name_qtip" : "340c2ee497b85d5954b01c64de7f44f6",
45   "milestone_id_name_fieldLabel" : "e9c626b8a8b62de7562dfbf51a576ae5",
46   "priority_id_name_qtip" : "6c768695a8efb18436d5b7b4374cdb45",
47   "view_as_text_boxLabel" : "1cb251ec0d568de6a929b520c4aed8d1",
48   "developer_id_name_fieldLabel" : "672caf27f5363dc833bda5099775e891",
49   "severity_id_name_fieldLabel" : "007cc9547ae8884ad597cd92ba505422",
50   "developer_id_name_emptyText" : "340c2ee497b85d5954b01c64de7f44f6",
51   "summary_fieldLabel" : "290612199861c31d1036b185b4e69b75",
52   "classification_id_name_emptyText" : "fcb17935fd52e65b8f223778c9e70313",
53   "severity_id_name_qtip" : "6c768695a8efb18436d5b7b4374cdb45",
54   "description_fieldLabel" : "b5a7adde1af5c87d7fd797b6245c2a39",
55   "owner_id_name_emptyText" : "340c2ee497b85d5954b01c64de7f44f6",
56   "project_id_name_qtip" : "24f27bda5dd2c488aa9bc7700ba98c34",
57   "severity_id_name_emptyText" : "43371ce8259ba854b1ae3543fd477874",
58   "milestone_id_name_qtip" : "a5ffb2a210f259195a75e5abca8db4a2",
59   "priority_id_name_loadingText" : "1243daf593fa297e07ab03bf06d925af",
60   "classification_id_name_loadingText" : "1243daf593fa297e07ab03bf06d925af",
61   "milestone_id_name_emptyText" : "a02a8093b46b8e647c29727fb50d67e4",
62   "priority_id_name_emptyText" : "86e9400686e8e080ef3c8995afb5eb86",
63   "developer_id_name_loadingText" : "1243daf593fa297e07ab03bf06d925af",
64   "milestone_id_name_loadingText" : "1243daf593fa297e07ab03bf06d925af",
65   "project_id_name_emptyText" : "6a58f977f2b623b695a340766f2a6843",
66   "owner_id_name_qtip" : "340c2ee497b85d5954b01c64de7f44f6",
67   "view_as_text_fieldLabel" : "23e6bcd09b259e6de4cd972516cb4214",
68   "priority_id_name_fieldLabel" : "502996d9790340c5fd7b86a5b93b1c9f",
69   "project_id_name_loadingText" : "1243daf593fa297e07ab03bf06d925af",
70   "owner_id_name_fieldLabel" : "b6f4a2ec6356bbd56d49f2096bf9d3d3",
71   "view_as_text_value" : "c4ca4238a0b923820dcc509a6f75849b",
72   "owner_id_name_loadingText" : "1243daf593fa297e07ab03bf06d925af",
73   "view_as_markdown_boxLabel" : "590fc197fe73db0aa2ec03687a372eea",
74   "project_id_name_fieldLabel" : "9e727fdd3aec8274f46685441900280d",
75   "classification_id_name_fieldLabel" : "5c9335b28e6277ddbe0137f04e5e58a7",
76   "classification_id_name_qtip" : "6c768695a8efb18436d5b7b4374cdb45"
77  },
78  "items" : [
79   {
80    "listeners" : {
81     "resize" : "function (_self, width, height)\n{\n    var bw = width - 320;\n    _this.form.findField('description').el.setWidth(bw);\n    _this.summaryBox.el.setWidth(bw+30);\n        _this.summaryCol.el.setWidth(bw+45);\n          _this.descCol.el.setWidth(bw+35);\n          \n}"
82    },
83    "modal" : true,
84    "collapsible" : false,
85    "title" : "Edit or Create Ticket",
86    "xtype" : "LayoutDialog",
87    "width" : 700,
88    "$ xns" : "Roo",
89    "closable" : false,
90    "resizable" : true,
91    "height" : 450,
92    "items" : [
93     {
94      "xtype" : "LayoutRegion",
95      "$ xns" : "Roo",
96      "* prop" : "center"
97     },
98     {
99      "region" : "center",
100      "xtype" : "ContentPanel",
101      "$ xns" : "Roo",
102      "items" : [
103       {
104        "listeners" : {
105         "|actioncomplete" : "function(_self,action)\n{\n    if (action.type == 'setdata') {\n  \n       this.load({ method: 'GET', params: { '_id' : _this.data.id  || 0}});\n          \n       return;\n    }\n    if (action.type == 'load') {\n       if (!_this.data.id) {\n            this.setValues(_this.data);\n        }\n        return;\n    }\n    \n    \n    if (action.type =='submit') {\n    \n        if (!_this.data.id * 1) {\n            Roo.MessageBox.confirm(\"Close?\", \n                \"The new ticket id is #\" + action.result.data.id + \", Press yes to close, or no to keep editing\",\n                function (res) {\n                    if (res == 'yes') {\n                    \n                    \n                        _this.dialog.hide();\n                    \n                         if (_this.callback) {\n                            _this.callback.call(_this, _this.form.getValues());\n                         }\n                         _this.form.reset();            \n                         return;\n                     }\n                     _this.data.id = action.result.data.id;\n                     _this.form.fireEvent('actioncomplete', _this.form, { type : 'setdata', data : {}});\n                     return;\n                 }\n             );\n        \n        \n        \n        \n            return;\n        }\n        \n        _this.dialog.hide();\n    \n         if (_this.callback) {\n            _this.callback.call(_this, _this.form.getValues());\n         }\n         _this.form.reset();        \n\n         return;\n    }\n}\n",
106         "|rendered" : "function (form)\n{\n    _this.form= form;\n}\n"
107        },
108        "$ url" : "baseURL + '/Roo/mtrack_ticket.php'",
109        "method" : "POST",
110        "xtype" : "Form",
111        "style" : "margin:10px;width:1000px;margin-top:0px;",
112        "$ xns" : "Roo.form",
113        "items" : [
114         {
115          "xtype" : "Column",
116          "width" : 210,
117          "$ xns" : "Roo.form",
118          "items" : [
119           {
120            "labelAlign" : "top",
121            "legend" : "Properties",
122            "style" : "width:190px;",
123            "xtype" : "FieldSet",
124            "$ xns" : "Roo.form",
125            "items" : [
126             {
127              "listWidth" : 400,
128              "triggerAction" : "all",
129              "fieldLabel" : "Project",
130              "forceSelection" : true,
131              "selectOnFocus" : true,
132              "pageSize" : 20,
133              "displayField" : "name",
134              "emptyText" : "Select Project",
135              "hiddenName" : "project_id",
136              "minChars" : 2,
137              "valueField" : "id",
138              "xtype" : "ComboBox",
139              "allowBlank" : false,
140              "typeAhead" : true,
141              "editable" : false,
142              "width" : 180,
143              "$ xns" : "Roo.form",
144              "name" : "project_id_name",
145              "qtip" : "Select Projects",
146              "queryParam" : "query[name]",
147              "tpl" : "<div class=\"x-grid-cell-text x-btn button \"><b>{name}</b> </div>",
148              "loadingText" : "Searching...",
149              "items" : [
150               {
151                "listeners" : {
152                 "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n}\n"
153                },
154                "xtype" : "Store",
155                "remoteSort" : true,
156                "$ sortInfo" : "{ direction : 'ASC', field: 'name' }",
157                "$ xns" : "Roo.data",
158                "* prop" : "store",
159                "items" : [
160                 {
161                  "$ url" : "baseURL + '/Roo/core_project'",
162                  "xtype" : "HttpProxy",
163                  "method" : "GET",
164                  "$ xns" : "Roo.data",
165                  "* prop" : "proxy"
166                 },
167                 {
168                  "id" : "id",
169                  "root" : "data",
170                  "xtype" : "JsonReader",
171                  "$ xns" : "Roo.data",
172                  "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]",
173                  "* prop" : "reader",
174                  "totalProperty" : "total"
175                 }
176                ]
177               }
178              ]
179             },
180             {
181              "alwaysQuery" : true,
182              "listWidth" : 400,
183              "triggerAction" : "all",
184              "fieldLabel" : "Milestone",
185              "forceSelection" : true,
186              "selectOnFocus" : true,
187              "pageSize" : 20,
188              "displayField" : "name",
189              "emptyText" : "Select milestone",
190              "hiddenName" : "milestone_id",
191              "minChars" : 2,
192              "valueField" : "id",
193              "xtype" : "ComboBox",
194              "typeAhead" : true,
195              "editable" : false,
196              "width" : 180,
197              "$ xns" : "Roo.form",
198              "name" : "milestone_id_name",
199              "qtip" : "Select mtrack_milestone",
200              "queryParam" : "query[name]",
201              "tpl" : "<div class=\"x-grid-cell-text x-btn button  RdYlGn-q{seqid}-{seqmax}\"><b>{name}</b> </div>",
202              "loadingText" : "Searching...",
203              "items" : [
204               {
205                "listeners" : {
206                 "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n    o.params.etype = 'milestone';\n    o.params.project_id = _this.form.findField('project_id').getValue();\n    if (!o.params.project_id) {\n        Roo.MessageBox.alert(\"Error\", \"Select Project\");\n        return false;\n    }\n}\n"
207                },
208                "xtype" : "Store",
209                "remoteSort" : true,
210                "$ sortInfo" : "{ direction : 'ASC', field: 'startdate' }",
211                "$ xns" : "Roo.data",
212                "* prop" : "store",
213                "items" : [
214                 {
215                  "$ url" : "baseURL + '/Roo/mtrack_milestone.php'",
216                  "xtype" : "HttpProxy",
217                  "method" : "GET",
218                  "$ xns" : "Roo.data",
219                  "* prop" : "proxy"
220                 },
221                 {
222                  "id" : "id",
223                  "root" : "data",
224                  "xtype" : "JsonReader",
225                  "$ xns" : "Roo.data",
226                  "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]",
227                  "* prop" : "reader",
228                  "totalProperty" : "total"
229                 }
230                ]
231               }
232              ]
233             },
234             {
235              "alwaysQuery" : true,
236              "listWidth" : 400,
237              "triggerAction" : "all",
238              "fieldLabel" : "Priority",
239              "forceSelection" : true,
240              "selectOnFocus" : true,
241              "pageSize" : 20,
242              "displayField" : "name",
243              "emptyText" : "Select Priority",
244              "hiddenName" : "priority_id",
245              "minChars" : 2,
246              "valueField" : "id",
247              "xtype" : "ComboBox",
248              "allowBlank" : false,
249              "typeAhead" : true,
250              "editable" : false,
251              "width" : 180,
252              "$ xns" : "Roo.form",
253              "name" : "priority_id_name",
254              "qtip" : "Select core_enum",
255              "queryParam" : "query[etype]",
256              "tpl" : "<div class=\"x-grid-cell-text x-btn button  RdYlGn-q{seqid}-{seqmax}\"><b>{name}</b> </div>",
257              "loadingText" : "Searching...",
258              "items" : [
259               {
260                "listeners" : {
261                 "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n        o.params.etype = 'priority';\n}\n"
262                },
263                "xtype" : "Store",
264                "remoteSort" : true,
265                "$ sortInfo" : "{ direction : 'ASC', field: 'seqid' }",
266                "$ xns" : "Roo.data",
267                "* prop" : "store",
268                "items" : [
269                 {
270                  "$ url" : "baseURL + '/Roo/core_enum.php'",
271                  "xtype" : "HttpProxy",
272                  "method" : "GET",
273                  "$ xns" : "Roo.data",
274                  "* prop" : "proxy"
275                 },
276                 {
277                  "id" : "id",
278                  "root" : "data",
279                  "xtype" : "JsonReader",
280                  "$ xns" : "Roo.data",
281                  "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"etype\",\"type\":\"string\"}]",
282                  "* prop" : "reader",
283                  "totalProperty" : "total"
284                 }
285                ]
286               }
287              ]
288             },
289             {
290              "alwaysQuery" : true,
291              "listWidth" : 400,
292              "triggerAction" : "all",
293              "fieldLabel" : "Severity",
294              "forceSelection" : true,
295              "selectOnFocus" : true,
296              "pageSize" : 20,
297              "displayField" : "name",
298              "emptyText" : "Select Severity",
299              "hiddenName" : "severity_id",
300              "minChars" : 2,
301              "valueField" : "id",
302              "xtype" : "ComboBox",
303              "allowBlank" : false,
304              "typeAhead" : true,
305              "editable" : false,
306              "width" : 180,
307              "$ xns" : "Roo.form",
308              "name" : "severity_id_name",
309              "qtip" : "Select core_enum",
310              "queryParam" : "query[etype]",
311              "tpl" : "<div class=\"x-grid-cell-text x-btn button RdYlGn-q{seqid}-{seqmax}\"><b>{name}</b> </div>",
312              "loadingText" : "Searching...",
313              "items" : [
314               {
315                "listeners" : {
316                 "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n        o.params.etype = 'severity';\n}\n"
317                },
318                "xtype" : "Store",
319                "remoteSort" : true,
320                "$ sortInfo" : "{ direction : 'ASC', field: 'seqid' }",
321                "$ xns" : "Roo.data",
322                "* prop" : "store",
323                "items" : [
324                 {
325                  "$ url" : "baseURL + '/Roo/core_enum.php'",
326                  "xtype" : "HttpProxy",
327                  "method" : "GET",
328                  "$ xns" : "Roo.data",
329                  "* prop" : "proxy"
330                 },
331                 {
332                  "id" : "id",
333                  "root" : "data",
334                  "xtype" : "JsonReader",
335                  "$ xns" : "Roo.data",
336                  "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"etype\",\"type\":\"string\"}]",
337                  "* prop" : "reader",
338                  "totalProperty" : "total"
339                 }
340                ]
341               }
342              ]
343             },
344             {
345              "alwaysQuery" : true,
346              "listWidth" : 400,
347              "triggerAction" : "all",
348              "fieldLabel" : "Classification",
349              "forceSelection" : true,
350              "selectOnFocus" : true,
351              "pageSize" : 20,
352              "displayField" : "name",
353              "emptyText" : "Select Classification",
354              "hiddenName" : "classification_id",
355              "minChars" : 2,
356              "valueField" : "id",
357              "xtype" : "ComboBox",
358              "allowBlank" : false,
359              "typeAhead" : true,
360              "editable" : false,
361              "width" : 180,
362              "$ xns" : "Roo.form",
363              "name" : "classification_id_name",
364              "qtip" : "Select core_enum",
365              "queryParam" : "query[etype]",
366              "tpl" : "<div class=\"x-grid-cell-text x-btn button RdYlGn-q{seqid}-{seqmax}\"><b>{name}</b> </div>",
367              "loadingText" : "Searching...",
368              "items" : [
369               {
370                "listeners" : {
371                 "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n        o.params.etype = 'classification';\n}\n"
372                },
373                "xtype" : "Store",
374                "remoteSort" : true,
375                "$ sortInfo" : "{ direction : 'ASC', field: 'seqid' }",
376                "$ xns" : "Roo.data",
377                "* prop" : "store",
378                "items" : [
379                 {
380                  "$ url" : "baseURL + '/Roo/core_enum.php'",
381                  "xtype" : "HttpProxy",
382                  "method" : "GET",
383                  "$ xns" : "Roo.data",
384                  "* prop" : "proxy"
385                 },
386                 {
387                  "id" : "id",
388                  "root" : "data",
389                  "xtype" : "JsonReader",
390                  "$ xns" : "Roo.data",
391                  "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"etype\",\"type\":\"string\"}]",
392                  "* prop" : "reader",
393                  "totalProperty" : "total"
394                 }
395                ]
396               }
397              ]
398             }
399            ]
400           },
401           {
402            "style" : "width: 190px",
403            "xtype" : "FieldSet",
404            "legend" : "Resources",
405            "$ xns" : "Roo.form",
406            "items" : [
407             {
408              "labelAlign" : "top",
409              "xtype" : "Column",
410              "width" : 190,
411              "$ xns" : "Roo.form",
412              "items" : [
413               {
414                "alwaysQuery" : true,
415                "listWidth" : 400,
416                "triggerAction" : "all",
417                "fieldLabel" : "Developer",
418                "forceSelection" : true,
419                "selectOnFocus" : true,
420                "pageSize" : 20,
421                "displayField" : "name",
422                "emptyText" : "Select Person",
423                "hiddenName" : "developer_id",
424                "minChars" : 2,
425                "valueField" : "id",
426                "xtype" : "ComboBox",
427                "allowBlank" : false,
428                "typeAhead" : true,
429                "editable" : true,
430                "width" : 180,
431                "$ xns" : "Roo.form",
432                "name" : "developer_id_name",
433                "qtip" : "Select Person",
434                "queryParam" : "query[name]",
435                "tpl" : "<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> &lt;{email}&gt; </div>",
436                "loadingText" : "Searching...",
437                "items" : [
438                 {
439                  "listeners" : {
440                   "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    \n    // set more here\n    o.params['query[project_id]'] = _this.form.findField('project_id').getValue();\n    if (!o.params['query[project_id]']) {\n        Roo.MessageBox.alert(\"Error\", \"Select Project\");\n        return false;\n    }\n    o.params['query[role]'] = 'DEVELOPER';\n}\n"
441                  },
442                  "xtype" : "Store",
443                  "remoteSort" : true,
444                  "$ sortInfo" : "{ direction : 'ASC', field: 'name' }",
445                  "$ xns" : "Roo.data",
446                  "* prop" : "store",
447                  "items" : [
448                   {
449                    "$ url" : "baseURL + '/Roo/core_person'",
450                    "xtype" : "HttpProxy",
451                    "method" : "GET",
452                    "$ xns" : "Roo.data",
453                    "* prop" : "proxy"
454                   },
455                   {
456                    "id" : "id",
457                    "root" : "data",
458                    "xtype" : "JsonReader",
459                    "$ xns" : "Roo.data",
460                    "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]",
461                    "* prop" : "reader",
462                    "totalProperty" : "total"
463                   }
464                  ]
465                 }
466                ]
467               },
468               {
469                "alwaysQuery" : true,
470                "listWidth" : 400,
471                "triggerAction" : "all",
472                "fieldLabel" : "Owner",
473                "forceSelection" : true,
474                "selectOnFocus" : true,
475                "pageSize" : 20,
476                "displayField" : "name",
477                "emptyText" : "Select Person",
478                "hiddenName" : "owner_id",
479                "minChars" : 2,
480                "valueField" : "id",
481                "xtype" : "ComboBox",
482                "allowBlank" : false,
483                "typeAhead" : true,
484                "editable" : false,
485                "width" : 180,
486                "$ xns" : "Roo.form",
487                "name" : "owner_id_name",
488                "qtip" : "Select Person",
489                "queryParam" : "query[name]",
490                "tpl" : "<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> </div>",
491                "loadingText" : "Searching...",
492                "items" : [
493                 {
494                  "listeners" : {
495                   "|beforeload" : "function (_self, o){\n    o.params = o.params || {};\n    // set more here\n    o.params['query[project_id]']= _this.form.findField('project_id').getValue();\n    if (!o.params['query[project_id]'])  {\n        Roo.MessageBox.alert(\"Error\", \"Select Project\");\n        return false;\n    }\n}\n"
496                  },
497                  "xtype" : "Store",
498                  "remoteSort" : true,
499                  "$ sortInfo" : "{ direction : 'ASC', field: 'name' }",
500                  "$ xns" : "Roo.data",
501                  "* prop" : "store",
502                  "items" : [
503                   {
504                    "$ url" : "baseURL + '/Roo/core_person'",
505                    "xtype" : "HttpProxy",
506                    "method" : "GET",
507                    "$ xns" : "Roo.data",
508                    "* prop" : "proxy"
509                   },
510                   {
511                    "id" : "id",
512                    "root" : "data",
513                    "xtype" : "JsonReader",
514                    "$ xns" : "Roo.data",
515                    "$ fields" : "[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"name\",\"type\":\"string\"}]",
516                    "* prop" : "reader",
517                    "totalProperty" : "total"
518                   }
519                  ]
520                 }
521                ]
522               }
523              ]
524             },
525             {
526              "labelAlign" : "right",
527              "xtype" : "Column",
528              "labelWidth" : 100,
529              "width" : 190,
530              "$ xns" : "Roo.form",
531              "items" : [
532               {
533                "fieldLabel" : "Estimated",
534                "xtype" : "NumberField",
535                "style" : "align:right;",
536                "width" : 75,
537                "$ xns" : "Roo.form",
538                "name" : "estimated"
539               }
540              ]
541             }
542            ]
543           }
544          ]
545         },
546         {
547          "listeners" : {
548           "show" : "function (_self)\n{\n\n}",
549           "render" : "function (_self)\n{\n  _this.summaryCol = _self;\n}"
550          },
551          "xtype" : "Column",
552          "style" : "margin-left:10px",
553          "width" : 430,
554          "$ xns" : "Roo.form",
555          "items" : [
556           {
557            "listeners" : {
558             "show" : "function (_self)\n{\n\n}",
559             "render" : "function (_self)\n{\n  _this.summaryBox = _self;\n}"
560            },
561            "style" : "width:410px",
562            "xtype" : "FieldSet",
563            "legend" : "Summary / Details",
564            "$ xns" : "Roo.form",
565            "items" : [
566             {
567              "labelAlign" : "top",
568              "xtype" : "Column",
569              "width" : 400,
570              "$ xns" : "Roo.form",
571              "items" : [
572               {
573                "fieldLabel" : "Summary",
574                "xtype" : "TextField",
575                "width" : 400,
576                "$ xns" : "Roo.form",
577                "name" : "summary"
578               }
579              ]
580             },
581             {
582              "style" : "float:left; width:400px",
583              "xtype" : "Row",
584              "labelWidth" : 70,
585              "width" : 400,
586              "$ xns" : "Roo.form",
587              "items" : [
588               {
589                "listeners" : {
590                 "check" : "function (_self, checked)\n{\n\n    if (!_this.form) {\n        return;\n    }\n    if (checked) {\n    \n         _this.form.findField('view_as').setValue('text');\n     }\n         \n    \n    \n     if (this.radio) {\n        return;\n    }\n     var md = _this.form.findField('view_as_markdown');\n\n    md.radio = true;\n    md.setValue(checked ? 0 : 1);\n    \n    md.radio = false;\n}"
591                },
592                "fieldLabel" : "View as",
593                "xtype" : "Checkbox",
594                "value" : 1,
595                "boxLabel" : "text",
596                "width" : 100,
597                "$ xns" : "Roo.form",
598                "name" : "view_as_text"
599               },
600               {
601                "hideLabels" : true,
602                "xtype" : "Row",
603                "style" : "float: left",
604                "width" : 100,
605                "$ xns" : "Roo.form",
606                "items" : [
607                 {
608                  "listeners" : {
609                   "check" : "function (_self, checked)\n{\n       if (!_this.form) {\n        return;\n    }\n    \n        if (checked) {\n    \n         _this.form.findField('view_as').setValue('markdown');\n     }\n    \n     if (this.radio) {\n        return;\n    }\n     var md = _this.form.findField('view_as_text');\n\n    md.radio = true;\n    md.setValue(checked ? 0 : 1);\n    md.radio = false;\n}"
610                  },
611                  "value" : 1,
612                  "xtype" : "Checkbox",
613                  "boxLabel" : "markdown",
614                  "$ xns" : "Roo.form",
615                  "name" : "view_as_markdown"
616                 }
617                ]
618               }
619              ]
620             },
621             {
622              "listeners" : {
623               "show" : "function (_self)\n{\n\n}",
624               "render" : "function (_self)\n{\n  _this.descCol = _self;\n}"
625              },
626              "labelAlign" : "top",
627              "xtype" : "Column",
628              "width" : 400,
629              "$ xns" : "Roo.form",
630              "items" : [
631               {
632                "fieldLabel" : "Description",
633                "xtype" : "TextArea",
634                "width" : 400,
635                "$ xns" : "Roo.form",
636                "name" : "description",
637                "height" : 250
638               }
639              ]
640             }
641            ]
642           }
643          ]
644         },
645         {
646          "xtype" : "Hidden",
647          "$ xns" : "Roo.form",
648          "name" : "id"
649         },
650         {
651          "xtype" : "Hidden",
652          "$ xns" : "Roo.form",
653          "name" : "view_as"
654         }
655        ]
656       }
657      ]
658     },
659     {
660      "listeners" : {
661       "click" : "function (_self, e)\n{\n    _this.dialog.hide();\n}"
662      },
663      "text" : "Cancel",
664      "xtype" : "Button",
665      "$ xns" : "Roo",
666      "* prop" : "buttons[]"
667     },
668     {
669      "listeners" : {
670       "click" : "function (_self, e)\n{\n    // do some checks?\n     \n    \n \n    _this.form.doAction(\"submit\");\n\n}"
671      },
672      "text" : "Save",
673      "xtype" : "Button",
674      "$ xns" : "Roo",
675      "* prop" : "buttons[]"
676     }
677    ]
678   }
679  ]
680 }