BUG 0000 PM TABLES tweaks

- tweaks on Edit report
- icons size adjustment
- labels
This commit is contained in:
Erik Amaru Ortiz
2011-07-22 17:08:57 -04:00
parent d248f79754
commit 48f8a88adb
11 changed files with 52 additions and 76 deletions

View File

@@ -158,7 +158,7 @@ var processmap=function(){
}.extend(this),
reportTables:function(){
var panel = this.panels.buildingBlocks;
panel.addContentTitle(G_STRINGS.ID_PROCESSMAP_REPORT_TABLES);
panel.addContentTitle('');
panel.clearContent();
var iframe=document.createElement('iframe');
iframe.setAttribute('id','reportTablesIframe');

View File

@@ -208,7 +208,7 @@ Ext.onReady(function(){
})
}, {
xtype: 'booleancolumn',
header: 'Null',
header: _('ID_NULL'),
dataIndex: 'field_null',
align: 'center',
width: 50,
@@ -219,10 +219,10 @@ Ext.onReady(function(){
}
}, {
xtype: 'booleancolumn',
header: 'Primary Key',
header: _('ID_PRIMARY_KEY'),
dataIndex: 'field_key',
align: 'center',
width: 50,
width: 80,
trueText: 'Yes',
falseText: 'No',
editor: {

View File

@@ -144,7 +144,7 @@ Ext.onReady(function(){
autoWidth : true,
stripeRows : true,
height : 100,
width : '25%',
width : 290,
stateful : true,
stateId : 'grid',
enableHdMenu : false,
@@ -158,13 +158,12 @@ Ext.onReady(function(){
rowdblclick: AssignFieldsAction
},
tbar: [
'->',
{
xtype: 'textfield',
id: 'searchTxt',
ctCls:'pm_search_text_field',
allowBlank: true,
width: 150,
width: 220,
emptyText: _('ID_ENTER_SEARCH_TERM'),
listeners: {
specialkey: function(f,e){
@@ -454,10 +453,6 @@ Ext.onReady(function(){
}
});
assignedGrid.getSelectionModel().on('selectionchange', function(sm){
//alert('s');
});
// (vertical) selection buttons
buttonsPanel = new Ext.Panel({
width : 40,
@@ -755,19 +750,6 @@ Ext.onReady(function(){
}
});
var tbar = new Array();
//if (_plugin_permissions !== false) {
if (TABLE !== false && TABLE.ADD_TAB_TAG == 'plugin@simplereport') {
tbar = [
{
text: _plugin_permissions.label,
handler: function(){
setTimeout(_plugin_permissions.fn, 0);
}
}
]
}
var items = new Array();
if (PRO_UID === false)
items.push(processComboBox);
@@ -812,7 +794,7 @@ Ext.onReady(function(){
items.push(comboDbConnections);
var frmDetails = new Ext.FormPanel({
var frmDetailsConfig = {
id:'frmDetails',
region: 'north',
labelWidth: 120,
@@ -827,10 +809,19 @@ Ext.onReady(function(){
msgTarget: 'side',
align:'center'
},
items: items,
tbar: tbar
});
items: items
}
if (TABLE !== false && TABLE.ADD_TAB_TAG == 'plugin@simplereport') {
frmDetailsConfig.tbar = [{
text: _plugin_permissions.label,
handler: function(){
setTimeout(_plugin_permissions.fn, 0);
}
}]
}
var frmDetails = new Ext.FormPanel(frmDetailsConfig);
southPanel = new Ext.FormPanel({
region: 'south',
@@ -869,10 +860,7 @@ Ext.onReady(function(){
if (TABLE === false) {
if(TABLE.ADD_TAB_TYPE != 'GRID')
loadFieldNormal();
} //else if(typeof avFieldsList != 'undefined')
//loadAvFieldsFromArray(avFieldsList);
} else {
}
}

View File

@@ -1,5 +1,8 @@
var checkColumn;
/**
* Export PM Tables
* developed on date 2011-07-20
* @author Erik Amaru Ortiz <erik@colosa.com>
*/
var Export = function() {
return {
@@ -10,6 +13,7 @@ var Export = function() {
// defining components
targetGrid : {},
window : {},
// init
init : function() {
Ext.form.Field.prototype.msgTarget = 'side';
@@ -24,7 +28,9 @@ var Export = function() {
}
}();
/**
* CONFIGURE ROUTINES
*/
Export.configure = function()
{
/**
@@ -32,7 +38,7 @@ Export.configure = function()
*/
this.targetGridConfig = {
id : 'targetGrid',
title : 'To Export tables',
title : _('ID_TABLES_TO_EXPORT'),
region: 'east',
width : 450,
split : true,
@@ -50,16 +56,15 @@ Export.configure = function()
]
});
schemaColumn = new Ext.grid.CheckColumn({
header: 'Schema',
header: _('ID_SCHEMA'),
dataIndex: '_SCHEMA',
width: 55,
checked: true
});
dataColumn = new Ext.grid.CheckColumn({
header: 'Data',
header: _('ID_DATA'),
dataIndex: '_DATA',
width: 55
});
@@ -72,8 +77,8 @@ Export.configure = function()
columns: [
new Ext.grid.RowNumberer(),
{id:'ADD_TAB_UID', dataIndex: 'ADD_TAB_UID', hidden:true, hideable:false},
{header: _('ID_TABLE'), dataIndex: 'ADD_TAB_NAME', width: 300},
{header: _('ID_TYPE'), dataIndex: '_TYPE', width:70},
{header: _('ID_PMTABLE'), dataIndex: 'ADD_TAB_NAME', width: 300},
{header: _('ID_TYPE'), dataIndex: '_TYPE', width:100},
schemaColumn,
dataColumn
]
@@ -87,19 +92,14 @@ Export.configure = function()
this.windowConfig = {
title: '',
layout: 'fit',
width: 550,
width: 570,
height: 400,
modal: true,
autoScroll: true,
maximizable: true,
closeAction: 'hide',
maximizable : false,
items: [],
listeners:{
show:function() {
this.loadMask = new Ext.LoadMask(this.body, { msg:'Loading. Please wait...' });
}
}
items: []
}
this.windowConfig.buttons = [{
@@ -114,24 +114,26 @@ Export.configure = function()
} //end configure
/**
* EXPORT ROUTINE
*/
Export.submit = function()
{
var rows = Export.targetGrid.getStore();
var rowsData = new Array();
for (i=0; i < rows.getCount(); i++) {
row = rows.getAt(i);
if ( row.data._SCHEMA == false && row.data._DATA == false) {
PMExt.info('INFO', 'From each table you should select Schema/Data to export at least one.');
PMExt.info(_('ID_INFO'), _('ID_PMTABLES_NOTICE_EXPORT'));
return false;
}
rowsData.push(row.data);
}
Ext.Msg.show({
title : '', //TRANSLATIONS.ID_TITLE_START_CASE, //'Start Case',
msg : 'Processing...',
title : '',
msg : _('ID_PROCESSING'),
wait: true,
waitConfig: {interval:500}
});

View File

@@ -41,19 +41,19 @@ Ext.onReady(function(){
var newMenuOptions = new Array();
if (PRO_UID == false) {
newMenuOptions.push({
text: 'New Table',
text: _('ID_NEW_PMATBLE'),
handler: newPMTable
});
}
newMenuOptions.push({
text: 'New Report Table',
text: _('ID_NEW_REPORT_TABLE'),
handler: NewReportTable
});
if (PRO_UID !== false) {
newMenuOptions.push({
text: 'New Report Table (Old Version)',
text: _('ID_NEW_REPORT_TABLE_OLD'),
handler: NewReportTableOld
});
}
@@ -61,7 +61,6 @@ Ext.onReady(function(){
newButton = new Ext.Action({
text: _('ID_NEW'),
icon: '/images/add-table.png',
menu: newMenuOptions
});
@@ -79,13 +78,6 @@ Ext.onReady(function(){
disabled: true
});
// importButton = new Ext.Action({
// text: _('ID_IMPORT'),
// iconCls: 'silk-add',
// icon: '/images/import.gif',
// handler: importOption
// });
importButton = new Ext.Action({
text: _('ID_IMPORT'),
iconCls: 'silk-add',
@@ -114,10 +106,6 @@ Ext.onReady(function(){
handler: DoSearch
});
// contextMenu = new Ext.menu.Menu({
// items: [editButton, deleteButton,'-',dataButton,'-',exportButton]
// });
var contextMenuItems = new Array();
contextMenuItems.push(editButton);
contextMenuItems.push(deleteButton);
@@ -142,7 +130,6 @@ Ext.onReady(function(){
items: contextMenuItems
});
searchText = new Ext.form.TextField ({
id: 'searchTxt',
ctCls:'pm_search_text_field',
@@ -156,9 +143,9 @@ Ext.onReady(function(){
}
},
focus: function(f,e) {
var row = infoGrid.getSelectionModel().getSelected();
infoGrid.getSelectionModel().deselectRow(infoGrid.getStore().indexOf(row));
}
var row = infoGrid.getSelectionModel().getSelected();
infoGrid.getSelectionModel().deselectRow(infoGrid.getStore().indexOf(row));
}
}
});
@@ -194,8 +181,6 @@ Ext.onReady(function(){
comboPageSize.setValue(pageSize);
store = new Ext.data.GroupingStore( {
proxy : new Ext.data.HttpProxy({
url: 'pmTablesProxy/getList' + (PRO_UID? '?pro_uid='+PRO_UID: '')
@@ -264,7 +249,7 @@ Ext.onReady(function(){
cmodelColumns.push({header: 'Table Type', dataIndex: 'PRO_UID', width: 120, align:'left', renderer: function(v,p,r){
color = r.get('PRO_UID') ? 'blue' : 'green';
value = r.get('PRO_UID') ? 'Report' : 'Table';
value = r.get('PRO_UID') ? _('ID_REPORT_TABLE') : _('ID_PMTABLE');
return '<span style="color:'+color+'">'+value+'</span> ';
}});
@@ -547,7 +532,7 @@ ExportPMTable = function(){
toExportRows.push([
rows[i].get('ADD_TAB_UID'),
rows[i].get('ADD_TAB_NAME'),
(rows[i].get('PRO_UID') == ''? 'Table': 'Report'),
(rows[i].get('PRO_UID') ? _('ID_REPORT_TABLE'): _('ID_PMTABLE')),
true,
false
]);
@@ -557,6 +542,7 @@ ExportPMTable = function(){
Export.window.show();
return;
iGrid = Ext.getCmp('infoGrid');
rowsSelected = iGrid.getSelectionModel().getSelections();
//location.href = 'additionalTablesToExport?sUID='+RetrieveRowsID(rowsSelected)+'&rand='+Math.random();

Binary file not shown.

Before

Width:  |  Height:  |  Size: 404 B

After

Width:  |  Height:  |  Size: 374 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 606 B

After

Width:  |  Height:  |  Size: 568 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 371 B

After

Width:  |  Height:  |  Size: 343 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 612 B

After

Width:  |  Height:  |  Size: 512 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 726 B

After

Width:  |  Height:  |  Size: 703 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 700 B

After

Width:  |  Height:  |  Size: 667 B