BUG 0000 PM tables imporovements

- Setting order to available fields on report table edit UI
This commit is contained in:
Erik Amaru Ortiz
2011-07-12 12:32:14 -04:00
parent e3add14892
commit e09bba3706
4 changed files with 20 additions and 13 deletions

View File

@@ -84,6 +84,7 @@ class pmTables extends Controller
); );
} }
} }
sort($fieldsList);
$this->setJSVar('avFieldsList', $fieldsList); $this->setJSVar('avFieldsList', $fieldsList);
$repTabPluginPermissions = $this->_getSimpleReportPluginDef(); $repTabPluginPermissions = $this->_getSimpleReportPluginDef();
$this->setJSVar('_plugin_permissions', $repTabPluginPermissions); $this->setJSVar('_plugin_permissions', $repTabPluginPermissions);
@@ -103,7 +104,7 @@ class pmTables extends Controller
); );
} }
} }
sort($fieldsList);
$this->setJSVar('avFieldsList', $fieldsList); $this->setJSVar('avFieldsList', $fieldsList);
$repTabPluginPermissions = $this->_getSimpleReportPluginDef(); $repTabPluginPermissions = $this->_getSimpleReportPluginDef();
break; break;
@@ -189,3 +190,4 @@ class pmTables extends Controller
} }

View File

@@ -134,7 +134,7 @@ class pmTablesProxy extends HttpProxyController
); );
} }
} }
$resultList['processFields'] = $aProcessGridFields; $resultList = $aProcessGridFields;
} else { } else {
$aProcessFields = Array(); $aProcessFields = Array();
@@ -146,10 +146,12 @@ class pmTablesProxy extends HttpProxyController
'FIELD_NAME' => $dfield['name'] 'FIELD_NAME' => $dfield['name']
); );
} }
$resultList['processFields'] = $aProcessFields; $resultList = $aProcessFields;
} }
return $resultList; sort($resultList);
return array('processFields'=>$resultList);
} }
/** /**

View File

@@ -161,7 +161,7 @@ var processmap=function(){
panel.clearContent(); panel.clearContent();
var iframe=document.createElement('iframe'); var iframe=document.createElement('iframe');
iframe.setAttribute('id','reportTablesIframe'); iframe.setAttribute('id','reportTablesIframe');
iframe.src = '../reportTables/main?PRO_UID=' + this.options.uid; iframe.src = '../pmTables?PRO_UID=' + this.options.uid;
iframe.style.border='0px'; iframe.style.border='0px';
iframe.style.width='786px'; iframe.style.width='786px';
iframe.style.height='564px'; iframe.style.height='564px';

View File

@@ -38,15 +38,18 @@ Ext.onReady(function(){
pageSize = parseInt(CONFIG.pageSize); pageSize = parseInt(CONFIG.pageSize);
var newMenuOptions = [ var newMenuOptions = new Array();
{ if (PRO_UID == false) {
newMenuOptions.push({
text: 'New Table', text: 'New Table',
handler: newPMTable handler: newPMTable
}, { });
}
newMenuOptions.push({
text: 'New Report Table', text: 'New Report Table',
handler: NewReportTable handler: NewReportTable
} });
];
if (PRO_UID !== false) { if (PRO_UID !== false) {
newMenuOptions.push({ newMenuOptions.push({