Pman.Dialog.CoreAutoSavePreview.bjs
[Pman.Core] / Pman.Dialog.CoreAutoSavePreview.js
index 7e2a6cd..b055388 100644 (file)
@@ -68,7 +68,7 @@ Pman.Dialog.CoreAutoSavePreview = {
                                 }
                             }
                         },
-                        autoExpandColumn : 'remarks',
+                        autoExpandColumn : 'event_when',
                         loadMask : true,
                         sm : {
                             xtype: 'RowSelectionModel',
@@ -76,14 +76,13 @@ Pman.Dialog.CoreAutoSavePreview = {
                             listeners : {
                                 afterselectionchange : function (_self)
                                 {
-                                    // load detail log in _this.viewPanel;
+                                    
                                     if (!this.getSelected()) {
-                                        this.viewPanel.setContent("Nothing Selected");
+                                        _this.viewPanel.setContent("Nothing Selected");
                                         return;
                                     }
-                                    var id = this.getSelected().data.id;
-                                    _this.viewPanel.load( { url : baseURL + "/Admin/EventView/" + id + ".html" });
                                     
+                                    _this.viewPanel.setContent("data");
                                 }
                             },
                             singleSelect : true
@@ -96,7 +95,8 @@ Pman.Dialog.CoreAutoSavePreview = {
                                 {
                                     Roo.log(_this.data);
                                     o.params = o.parmas || {};
-                                    o.action = 'AUTOSAVE'
+                                    o.params.action = 'AUTOSAVE';
+                                    
                                 }
                             },
                             remoteSort : true,
@@ -229,9 +229,7 @@ Pman.Dialog.CoreAutoSavePreview = {
                         footer : {
                             xtype: 'PagingToolbar',
                             xns: Roo,
-                            displayInfo : true,
-                            displayMsg : "{0} - {1} of {2}",
-                            emptyMsg : "Nothing found",
+                            displayInfo : false,
                             pageSize : 25
                         },
                         colModel : [
@@ -242,23 +240,23 @@ Pman.Dialog.CoreAutoSavePreview = {
                                 header : 'Date',
                                 width : 100,
                                 renderer : function(v) { return v ? v.dateFormat('d/m/Y H:i') : ''; }
-                            },
-                            {
-                                xtype: 'ColumnModel',
-                                xns: Roo.grid,
-                                dataIndex : 'on_table',
-                                header : 'Affected',
-                                width : 100,
-                                renderer : function(v) {                     
-                                    return String.format('{0})', v ? v : '');  
-                                }
                             }
                         ]
                     }
                 },
                 {
                     xtype: 'ContentPanel',
-                    xns: Roo
+                    xns: Roo,
+                    listeners : {
+                        render : function (_self)
+                        {
+                            _this.viewPanel = _self;
+                        }
+                    },
+                    background : false,
+                    fitContainer : true,
+                    fitToFrame : true,
+                    region : 'center'
                 }
             ],
             center : {
@@ -269,7 +267,7 @@ Pman.Dialog.CoreAutoSavePreview = {
                 xtype: 'LayoutRegion',
                 xns: Roo,
                 split : true,
-                width : 300
+                width : 200
             },
             buttons : [
                 {