Fix #7468 - updating template scanner
[Pman.Cms] / Pman.Dialog.CmsCategory.js
index 18fc28f..ee7908f 100644 (file)
@@ -69,13 +69,23 @@ Pman.Dialog.CmsCategory = {
                                         _this.form.reset();
                                         return;
                                     }
-                                    if (action.type = 'setdata') {
-                                    
-                                        _this.fo
-                                    
+                                     if (action.type == 'setdata') {
+                                         if (_this.data.id) {
+                                           _this.dialog.el.mask("Loading");
+                                           this.load({ method: 'GET', params: { '_id' : _this.data.id }});
+                                            return;
+                                       }
+                                      _this.grid.getDataSource().load();
+                                       return;
+                                    }
+                                    if (action.type == 'load') {
                                        _this.grid.getDataSource().load();
-                                    
+                                        _this.dialog.el.unmask();
+                                        return;
                                     }
+                                    
+                                  
+                                    
                                 },
                                 rendered : function (_self)
                                 {
@@ -94,6 +104,14 @@ Pman.Dialog.CmsCategory = {
                                     readOnly : true,
                                     width : 450
                                 },
+                                {
+                                    xtype: 'NumberField',
+                                    xns: Roo.form,
+                                    decimalPrecision : 0,
+                                    fieldLabel : 'Order (1 first)',
+                                    name : 'display_order',
+                                    width : 50
+                                },
                                 {
                                     xtype: 'TextField',
                                     xns: Roo.form,
@@ -289,9 +307,9 @@ Pman.Dialog.CmsCategory = {
                             {
                                 xtype: 'ColumnModel',
                                 xns: Roo.grid,
+                                dataIndex : 'id',
                                 header : '',
                                 width : 110,
-                                dataIndex : 'id',
                                 renderer : function(v,x,r) { return String.format('<img src="{0}/Images/Thumb/100/{1}/{2}">', baseURL, v, r.data.filename); }
                             },
                             {