BUG 0000 feature for PMExt main Object named PMExt.createInfoPanel() (tweaks)

- creates a new instance of infoPanel object
- PMExt.createInfoPanel(url, params)

Sample
 var sumaryInfPanel = PMExt.createInfoPanel('../sampleProxy/getSummary', {appUid: '43546...', index:1});
This commit is contained in:
Erik Amaru Ortiz
2011-09-21 10:33:48 -04:00
parent 67f88c0396
commit e2fc4779f8

View File

@@ -88,13 +88,13 @@ PMExtJSCommon = function() {
{ {
var labelColumnWidth = 170; var labelColumnWidth = 170;
var valueColumnWidth = 350; var valueColumnWidth = 350;
params = params || {};
if(typeof columnsSize != 'undefined') { if(typeof columnsSize != 'undefined') {
labelColumnWidth = columnsSize[0] || labelColumnWidth; labelColumnWidth = columnsSize[0] || labelColumnWidth;
valueColumnWidth = columnsSize[1] || valueColumnWidth; valueColumnWidth = columnsSize[1] || valueColumnWidth;
} }
return new Ext.grid.GridPanel({ return new Ext.grid.GridPanel({
store : new Ext.data.GroupingStore({ store : new Ext.data.GroupingStore({
autoLoad: true, autoLoad: true,
@@ -103,7 +103,7 @@ PMExtJSCommon = function() {
method : 'POST' method : 'POST'
}), }),
baseParams: params, baseParams: params,
reader : new Ext.data.JsonReader( { reader : new Ext.data.JsonReader({
fields : [{name : 'label'}, {name : 'value'}, {name : 'section'}] fields : [{name : 'label'}, {name : 'value'}, {name : 'section'}]
}), }),
groupField: 'section' groupField: 'section'
@@ -129,7 +129,8 @@ PMExtJSCommon = function() {
forceFit:true, forceFit:true,
headersDisabled : true, headersDisabled : true,
groupTextTpl: '{group}' groupTextTpl: '{group}'
}) }),
loadMask: true
}); });
} }
} }