1 //<script type="text/javascript">
3 // Auto generated file - created by app.Builder.js- do not edit directly (at present!)
5 Pman.Dialog.MTrackMilestone = {
10 show : function(data, cb)
18 this.dialog.show(this.data._el);
21 this.form.setValues(data);
22 this.form.fireEvent('actioncomplete', this.form, { type: 'setdata', data: data });
30 this.dialog = Roo.factory({
31 xtype: 'LayoutDialog',
37 title : "Edit / Create mtrack_milestone",
41 xtype: 'ContentPanel',
49 actioncomplete : function(_self,action)
51 if (action.type == 'setdata') {
54 this.load({ method: 'GET', params: { '_id' : _this.data.id }});
59 if (action.type == 'load') {
63 if (action.type =='submit') {
69 _this.callback.call(_this, _this.form.getValues());
75 rendered : function (form)
81 style : 'margin:10px;',
82 url : baseURL + '/Roo/mtrack_milestone.php',
88 displayField : 'name',
90 emptyText : "Select Project",
91 fieldLabel : 'Project',
92 forceSelection : true,
93 hiddenName : 'project_id',
95 loadingText : "Searching...",
97 name : 'project_id_name',
99 qtip : "Select Projects",
100 queryParam : 'query[name]',
101 selectOnFocus : true,
102 tpl : '<div class="x-grid-cell-text x-btn button"><b>{CODE} - {name}</b> </div>',
103 triggerAction : 'all',
111 beforeload : function (_self, o){
112 o.params = o.params || {};
117 sortInfo : { direction : 'ASC', field: 'name' },
122 url : baseURL + '/Roo/Projects.php'
129 totalProperty : 'total',
130 fields : [{"name":"id","type":"int"},{"name":"name","type":"string"}]
144 fieldLabel : 'Description',
146 name : 'description',
150 xtype: 'ComboBoxLister',
152 allowBlank : 'false',
154 displayField : 'name',
156 emptyText : "Select Milestones",
157 fieldLabel : 'Depends On',
158 forceSelection : true,
159 hiddenName : 'depends_on',
161 loadingText : "Searching...",
163 name : 'depends_on_list',
165 qtip : "Select Milestones",
166 queryParam : 'query[name]',
167 selectOnFocus : true,
168 tpl : '<div class="x-grid-cell-text x-btn button"><b>{name}</b> </div>',
169 triggerAction : 'all',
177 beforeload : function (_self, o){
178 o.params = o.params || {};
183 sortInfo : { direction : 'ASC', field: 'name' },
188 url : baseURL + '/Roo/Mtrack_milestone.php'
195 totalProperty : 'total',
196 fields : [{"name":"id","type":"int"},{"name":"name","type":"string"}]
207 fieldLabel : 'Startdate',
211 value : (function() { (new Date()).format('Y-m-d')})()
216 fieldLabel : 'Duedate',
226 fieldLabel : 'Completed',
242 xtype: 'LayoutRegion',
250 click : function (_self, e)
261 click : function (_self, e)
266 _this.dialog.el.mask("Saving");
267 _this.form.doAction("submit");