1 //<script type="text/javascript">
3 // Auto generated file - created by app.Builder.js- do not edit directly (at present!)
5 Roo.namespace('Pman.Dialog');
7 Pman.Dialog.MTrackTicket = {
10 'a02a8093b46b8e647c29727fb50d67e4' :"Select milestone",
11 '672caf27f5363dc833bda5099775e891' :"Developer",
12 '9e727fdd3aec8274f46685441900280d' :"Project",
13 '6a58f977f2b623b695a340766f2a6843' :"Select Project",
14 'a5ffb2a210f259195a75e5abca8db4a2' :"Select mtrack_milestone",
15 '6c768695a8efb18436d5b7b4374cdb45' :"Select core_enum",
16 '007cc9547ae8884ad597cd92ba505422' :"Severity",
17 '86e9400686e8e080ef3c8995afb5eb86' :"Select Priority",
18 'ddcf50c29294d4414f3f7c1bbc892cb5' :"Resources",
19 '290612199861c31d1036b185b4e69b75' :"Summary",
20 '1cb251ec0d568de6a929b520c4aed8d1' :"text",
21 '5c9335b28e6277ddbe0137f04e5e58a7' :"Classification",
22 '3c311fbd0f9e51ce27b984f55164cf83' :"Estimated",
23 '1243daf593fa297e07ab03bf06d925af' :"Searching...",
24 'c4ca4238a0b923820dcc509a6f75849b' :"1",
25 'ea4788705e6873b424c65e91c2846b19' :"Cancel",
26 '502996d9790340c5fd7b86a5b93b1c9f' :"Priority",
27 'b6f4a2ec6356bbd56d49f2096bf9d3d3' :"Owner",
28 'ff18c41b7689060c39934dbb74de1e9c' :"Edit or Create Ticket",
29 '24f27bda5dd2c488aa9bc7700ba98c34' :"Select Projects",
30 '340c2ee497b85d5954b01c64de7f44f6' :"Select Person",
31 '23e6bcd09b259e6de4cd972516cb4214' :"View as",
32 '590fc197fe73db0aa2ec03687a372eea' :"markdown",
33 'e9c626b8a8b62de7562dfbf51a576ae5' :"Milestone",
34 '43371ce8259ba854b1ae3543fd477874' :"Select Severity",
35 'a8dbd02aaca3948002718aeb2babeefe' :"Summary / Details",
36 '9fc2d28c05ed9eb1d75ba4465abf15a9' :"Properties",
37 'b5a7adde1af5c87d7fd797b6245c2a39' :"Description",
38 'c9cc8cce247e49bae79f15173ce97354' :"Save",
39 'fcb17935fd52e65b8f223778c9e70313' :"Select Classification"
42 'view_as_markdown_value' : 'c4ca4238a0b923820dcc509a6f75849b' /* 1 */ ,
43 'estimated_fieldLabel' : '3c311fbd0f9e51ce27b984f55164cf83' /* Estimated */ ,
44 'severity_id_name_loadingText' : '1243daf593fa297e07ab03bf06d925af' /* Searching... */ ,
45 'developer_id_name_qtip' : '340c2ee497b85d5954b01c64de7f44f6' /* Select Person */ ,
46 'milestone_id_name_fieldLabel' : 'e9c626b8a8b62de7562dfbf51a576ae5' /* Milestone */ ,
47 'priority_id_name_qtip' : '6c768695a8efb18436d5b7b4374cdb45' /* Select core_enum */ ,
48 'view_as_text_boxLabel' : '1cb251ec0d568de6a929b520c4aed8d1' /* text */ ,
49 'developer_id_name_fieldLabel' : '672caf27f5363dc833bda5099775e891' /* Developer */ ,
50 'severity_id_name_fieldLabel' : '007cc9547ae8884ad597cd92ba505422' /* Severity */ ,
51 'developer_id_name_emptyText' : '340c2ee497b85d5954b01c64de7f44f6' /* Select Person */ ,
52 'summary_fieldLabel' : '290612199861c31d1036b185b4e69b75' /* Summary */ ,
53 'classification_id_name_emptyText' : 'fcb17935fd52e65b8f223778c9e70313' /* Select Classification */ ,
54 'severity_id_name_qtip' : '6c768695a8efb18436d5b7b4374cdb45' /* Select core_enum */ ,
55 'description_fieldLabel' : 'b5a7adde1af5c87d7fd797b6245c2a39' /* Description */ ,
56 'owner_id_name_emptyText' : '340c2ee497b85d5954b01c64de7f44f6' /* Select Person */ ,
57 'project_id_name_qtip' : '24f27bda5dd2c488aa9bc7700ba98c34' /* Select Projects */ ,
58 'severity_id_name_emptyText' : '43371ce8259ba854b1ae3543fd477874' /* Select Severity */ ,
59 'milestone_id_name_qtip' : 'a5ffb2a210f259195a75e5abca8db4a2' /* Select mtrack_milestone */ ,
60 'priority_id_name_loadingText' : '1243daf593fa297e07ab03bf06d925af' /* Searching... */ ,
61 'classification_id_name_loadingText' : '1243daf593fa297e07ab03bf06d925af' /* Searching... */ ,
62 'milestone_id_name_emptyText' : 'a02a8093b46b8e647c29727fb50d67e4' /* Select milestone */ ,
63 'priority_id_name_emptyText' : '86e9400686e8e080ef3c8995afb5eb86' /* Select Priority */ ,
64 'developer_id_name_loadingText' : '1243daf593fa297e07ab03bf06d925af' /* Searching... */ ,
65 'milestone_id_name_loadingText' : '1243daf593fa297e07ab03bf06d925af' /* Searching... */ ,
66 'project_id_name_emptyText' : '6a58f977f2b623b695a340766f2a6843' /* Select Project */ ,
67 'owner_id_name_qtip' : '340c2ee497b85d5954b01c64de7f44f6' /* Select Person */ ,
68 'view_as_text_fieldLabel' : '23e6bcd09b259e6de4cd972516cb4214' /* View as */ ,
69 'priority_id_name_fieldLabel' : '502996d9790340c5fd7b86a5b93b1c9f' /* Priority */ ,
70 'project_id_name_loadingText' : '1243daf593fa297e07ab03bf06d925af' /* Searching... */ ,
71 'owner_id_name_fieldLabel' : 'b6f4a2ec6356bbd56d49f2096bf9d3d3' /* Owner */ ,
72 'view_as_text_value' : 'c4ca4238a0b923820dcc509a6f75849b' /* 1 */ ,
73 'owner_id_name_loadingText' : '1243daf593fa297e07ab03bf06d925af' /* Searching... */ ,
74 'view_as_markdown_boxLabel' : '590fc197fe73db0aa2ec03687a372eea' /* markdown */ ,
75 'project_id_name_fieldLabel' : '9e727fdd3aec8274f46685441900280d' /* Project */ ,
76 'classification_id_name_fieldLabel' : '5c9335b28e6277ddbe0137f04e5e58a7' /* Classification */ ,
77 'classification_id_name_qtip' : '6c768695a8efb18436d5b7b4374cdb45' /* Select core_enum */
83 show : function(data, cb)
91 this.dialog.show(this.data._el);
94 this.form.setValues(data);
95 this.form.fireEvent('actioncomplete', this.form, { type: 'setdata', data: data });
103 this.dialog = Roo.factory({
104 xtype : 'LayoutDialog',
110 title : _this._strings['ff18c41b7689060c39934dbb74de1e9c'] /* Edit or Create Ticket */,
113 resize : function (_self, width, height)
115 var bw = width - 320;
116 _this.form.findField('description').el.setWidth(bw);
117 _this.summaryBox.el.setWidth(bw+30);
118 _this.summaryCol.el.setWidth(bw+45);
119 _this.descCol.el.setWidth(bw+35);
126 xtype : 'LayoutRegion',
133 text : _this._strings['ea4788705e6873b424c65e91c2846b19'] /* Cancel */,
135 click : function (_self, e)
145 text : _this._strings['c9cc8cce247e49bae79f15173ce97354'] /* Save */,
147 click : function (_self, e)
153 _this.form.doAction("submit");
163 xtype : 'ContentPanel',
171 style : 'margin:10px;width:1000px;margin-top:0px;',
172 url : baseURL + '/Roo/mtrack_ticket.php',
174 actioncomplete : function(_self,action)
176 if (action.type == 'setdata') {
178 this.load({ method: 'GET', params: { '_id' : _this.data.id || 0}});
182 if (action.type == 'load') {
183 if (!_this.data.id) {
184 this.setValues(_this.data);
190 if (action.type =='submit') {
192 if (!_this.data.id * 1) {
193 Roo.MessageBox.confirm("Close?",
194 "The new ticket id is #" + action.result.data.id + ", Press yes to close, or no to keep editing",
201 if (_this.callback) {
202 _this.callback.call(_this, _this.form.getValues());
207 _this.data.id = action.result.data.id;
208 _this.form.fireEvent('actioncomplete', _this.form, { type : 'setdata', data : {}});
221 if (_this.callback) {
222 _this.callback.call(_this, _this.form.getValues());
229 rendered : function (form)
246 legend : _this._strings['9fc2d28c05ed9eb1d75ba4465abf15a9'] /* Properties */,
247 style : 'width:190px;',
254 displayField : 'name',
256 emptyText : _this._strings['6a58f977f2b623b695a340766f2a6843'] /* Select Project */,
257 fieldLabel : _this._strings['9e727fdd3aec8274f46685441900280d'] /* Project */,
258 forceSelection : true,
259 hiddenName : 'project_id',
261 loadingText : _this._strings['1243daf593fa297e07ab03bf06d925af'] /* Searching... */,
263 name : 'project_id_name',
265 qtip : _this._strings['24f27bda5dd2c488aa9bc7700ba98c34'] /* Select Projects */,
266 queryParam : 'query[name]',
267 selectOnFocus : true,
268 tpl : '<div class=\"x-grid-cell-text x-btn button \"><b>{name}</b> </div>',
269 triggerAction : 'all',
278 sortInfo : { direction : 'ASC', field: 'name' },
280 beforeload : function (_self, o){
281 o.params = o.params || {};
290 url : baseURL + '/Roo/core_project',
295 xtype : 'JsonReader',
296 fields : [{"name":"id","type":"int"},{"name":"name","type":"string"}],
299 totalProperty : 'total',
308 displayField : 'name',
310 emptyText : _this._strings['a02a8093b46b8e647c29727fb50d67e4'] /* Select milestone */,
311 fieldLabel : _this._strings['e9c626b8a8b62de7562dfbf51a576ae5'] /* Milestone */,
312 forceSelection : true,
313 hiddenName : 'milestone_id',
315 loadingText : _this._strings['1243daf593fa297e07ab03bf06d925af'] /* Searching... */,
317 name : 'milestone_id_name',
319 qtip : _this._strings['a5ffb2a210f259195a75e5abca8db4a2'] /* Select mtrack_milestone */,
320 queryParam : 'query[name]',
321 selectOnFocus : true,
322 tpl : '<div class=\"x-grid-cell-text x-btn button RdYlGn-q{seqid}-{seqmax}\"><b>{name}</b> </div>',
323 triggerAction : 'all',
332 sortInfo : { direction : 'ASC', field: 'startdate' },
334 beforeload : function (_self, o){
335 o.params = o.params || {};
337 o.params.etype = 'milestone';
338 o.params.project_id = _this.form.findField('project_id').getValue();
339 if (!o.params.project_id) {
340 Roo.MessageBox.alert("Error", "Select Project");
350 url : baseURL + '/Roo/mtrack_milestone.php',
355 xtype : 'JsonReader',
356 fields : [{"name":"id","type":"int"},{"name":"name","type":"string"}],
359 totalProperty : 'total',
369 displayField : 'name',
371 emptyText : _this._strings['86e9400686e8e080ef3c8995afb5eb86'] /* Select Priority */,
372 fieldLabel : _this._strings['502996d9790340c5fd7b86a5b93b1c9f'] /* Priority */,
373 forceSelection : true,
374 hiddenName : 'priority_id',
376 loadingText : _this._strings['1243daf593fa297e07ab03bf06d925af'] /* Searching... */,
378 name : 'priority_id_name',
380 qtip : _this._strings['6c768695a8efb18436d5b7b4374cdb45'] /* Select core_enum */,
381 queryParam : 'query[etype]',
382 selectOnFocus : true,
383 tpl : '<div class=\"x-grid-cell-text x-btn button RdYlGn-q{seqid}-{seqmax}\"><b>{name}</b> </div>',
384 triggerAction : 'all',
393 sortInfo : { direction : 'ASC', field: 'seqid' },
395 beforeload : function (_self, o){
396 o.params = o.params || {};
398 o.params.etype = 'priority';
406 url : baseURL + '/Roo/core_enum.php',
411 xtype : 'JsonReader',
412 fields : [{"name":"id","type":"int"},{"name":"etype","type":"string"}],
415 totalProperty : 'total',
425 displayField : 'name',
427 emptyText : _this._strings['43371ce8259ba854b1ae3543fd477874'] /* Select Severity */,
428 fieldLabel : _this._strings['007cc9547ae8884ad597cd92ba505422'] /* Severity */,
429 forceSelection : true,
430 hiddenName : 'severity_id',
432 loadingText : _this._strings['1243daf593fa297e07ab03bf06d925af'] /* Searching... */,
434 name : 'severity_id_name',
436 qtip : _this._strings['6c768695a8efb18436d5b7b4374cdb45'] /* Select core_enum */,
437 queryParam : 'query[etype]',
438 selectOnFocus : true,
439 tpl : '<div class=\"x-grid-cell-text x-btn button RdYlGn-q{seqid}-{seqmax}\"><b>{name}</b> </div>',
440 triggerAction : 'all',
449 sortInfo : { direction : 'ASC', field: 'seqid' },
451 beforeload : function (_self, o){
452 o.params = o.params || {};
454 o.params.etype = 'severity';
462 url : baseURL + '/Roo/core_enum.php',
467 xtype : 'JsonReader',
468 fields : [{"name":"id","type":"int"},{"name":"etype","type":"string"}],
471 totalProperty : 'total',
481 displayField : 'name',
483 emptyText : _this._strings['fcb17935fd52e65b8f223778c9e70313'] /* Select Classification */,
484 fieldLabel : _this._strings['5c9335b28e6277ddbe0137f04e5e58a7'] /* Classification */,
485 forceSelection : true,
486 hiddenName : 'classification_id',
488 loadingText : _this._strings['1243daf593fa297e07ab03bf06d925af'] /* Searching... */,
490 name : 'classification_id_name',
492 qtip : _this._strings['6c768695a8efb18436d5b7b4374cdb45'] /* Select core_enum */,
493 queryParam : 'query[etype]',
494 selectOnFocus : true,
495 tpl : '<div class=\"x-grid-cell-text x-btn button RdYlGn-q{seqid}-{seqmax}\"><b>{name}</b> </div>',
496 triggerAction : 'all',
505 sortInfo : { direction : 'ASC', field: 'seqid' },
507 beforeload : function (_self, o){
508 o.params = o.params || {};
510 o.params.etype = 'classification';
518 url : baseURL + '/Roo/core_enum.php',
523 xtype : 'JsonReader',
524 fields : [{"name":"id","type":"int"},{"name":"etype","type":"string"}],
527 totalProperty : 'total',
537 legend : _this._strings['ddcf50c29294d4414f3f7c1bbc892cb5'] /* Resources */,
538 style : 'width: 190px',
553 displayField : 'name',
555 emptyText : _this._strings['340c2ee497b85d5954b01c64de7f44f6'] /* Select Person */,
556 fieldLabel : _this._strings['672caf27f5363dc833bda5099775e891'] /* Developer */,
557 forceSelection : true,
558 hiddenName : 'developer_id',
560 loadingText : _this._strings['1243daf593fa297e07ab03bf06d925af'] /* Searching... */,
562 name : 'developer_id_name',
564 qtip : _this._strings['340c2ee497b85d5954b01c64de7f44f6'] /* Select Person */,
565 queryParam : 'query[name]',
566 selectOnFocus : true,
567 tpl : '<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> <{email}> </div>',
568 triggerAction : 'all',
577 sortInfo : { direction : 'ASC', field: 'name' },
579 beforeload : function (_self, o){
580 o.params = o.params || {};
583 o.params['query[project_id]'] = _this.form.findField('project_id').getValue();
584 if (!o.params['query[project_id]']) {
585 Roo.MessageBox.alert("Error", "Select Project");
588 o.params['query[role]'] = 'DEVELOPER';
596 url : baseURL + '/Roo/core_person',
601 xtype : 'JsonReader',
602 fields : [{"name":"id","type":"int"},{"name":"name","type":"string"}],
605 totalProperty : 'total',
615 displayField : 'name',
617 emptyText : _this._strings['340c2ee497b85d5954b01c64de7f44f6'] /* Select Person */,
618 fieldLabel : _this._strings['b6f4a2ec6356bbd56d49f2096bf9d3d3'] /* Owner */,
619 forceSelection : true,
620 hiddenName : 'owner_id',
622 loadingText : _this._strings['1243daf593fa297e07ab03bf06d925af'] /* Searching... */,
624 name : 'owner_id_name',
626 qtip : _this._strings['340c2ee497b85d5954b01c64de7f44f6'] /* Select Person */,
627 queryParam : 'query[name]',
628 selectOnFocus : true,
629 tpl : '<div class=\"x-grid-cell-text x-btn button\"><b>{name}</b> </div>',
630 triggerAction : 'all',
639 sortInfo : { direction : 'ASC', field: 'name' },
641 beforeload : function (_self, o){
642 o.params = o.params || {};
644 o.params['query[project_id]']= _this.form.findField('project_id').getValue();
645 if (!o.params['query[project_id]']) {
646 Roo.MessageBox.alert("Error", "Select Project");
656 url : baseURL + '/Roo/core_person',
661 xtype : 'JsonReader',
662 fields : [{"name":"id","type":"int"},{"name":"name","type":"string"}],
665 totalProperty : 'total',
675 labelAlign : 'right',
682 xtype : 'NumberField',
683 fieldLabel : _this._strings['3c311fbd0f9e51ce27b984f55164cf83'] /* Estimated */,
685 style : 'align:right;',
698 style : 'margin-left:10px',
701 render : function (_self)
703 _this.summaryCol = _self;
705 show : function (_self)
715 legend : _this._strings['a8dbd02aaca3948002718aeb2babeefe'] /* Summary / Details */,
716 style : 'width:410px',
718 render : function (_self)
720 _this.summaryBox = _self;
722 show : function (_self)
739 fieldLabel : _this._strings['290612199861c31d1036b185b4e69b75'] /* Summary */,
750 style : 'float:left; width:400px',
757 boxLabel : _this._strings['1cb251ec0d568de6a929b520c4aed8d1'] /* text */,
758 fieldLabel : _this._strings['23e6bcd09b259e6de4cd972516cb4214'] /* View as */,
759 name : 'view_as_text',
763 check : function (_self, checked)
771 _this.form.findField('view_as').setValue('text');
779 var md = _this.form.findField('view_as_markdown');
782 md.setValue(checked ? 0 : 1);
793 style : 'float: left',
800 boxLabel : _this._strings['590fc197fe73db0aa2ec03687a372eea'] /* markdown */,
801 name : 'view_as_markdown',
804 check : function (_self, checked)
812 _this.form.findField('view_as').setValue('markdown');
818 var md = _this.form.findField('view_as_text');
821 md.setValue(checked ? 0 : 1);
837 render : function (_self)
839 _this.descCol = _self;
841 show : function (_self)
851 fieldLabel : _this._strings['b5a7adde1af5c87d7fd797b6245c2a39'] /* Description */,
853 name : 'description',