Better Layout for start case

This commit is contained in:
Hugo Loza
2011-01-12 19:04:35 +00:00
parent d9efc5d1e7
commit b3e45467e1
2 changed files with 90 additions and 63 deletions

View File

@@ -1,21 +1,27 @@
<?php
unset($_SESSION['__currentTabDashboard']);
if(isset($_GET['action'])){
$_SESSION['__currentTabDashboard']=$_GET['action'];
}
$page="";
if(isset($_GET['action'])){
$page=$_GET['action'];
}
unset($_SESSION['__currentTabDashboard']);
if(isset($_GET['action'])){
$_SESSION['__currentTabDashboard']=$_GET['action'];
}
$page="";
if(isset($_GET['action'])){
$page=$_GET['action'];
}
$oHeadPublisher =& headPublisher::getSingleton();
//$oHeadPublisher->setExtSkin( 'xtheme-gray');
//$oHeadPublisher->usingExtJs('ux/TabCloseMenu');
//$oHeadPublisher->usingExtJs('ux/ColumnHeaderGroup');
switch($page){
case "startCase":
$labels = G::getTranslations(Array(
$oHeadPublisher =& headPublisher::getSingleton();
//$oHeadPublisher->setExtSkin( 'xtheme-gray');
//$oHeadPublisher->usingExtJs('ux/TabCloseMenu');
//$oHeadPublisher->usingExtJs('ux/ColumnHeaderGroup');
//G::pr($TRANSLATIONS_STARTCASE);
print "<img src='/images/gears.gif' valign='absmiddle'>&nbsp;".G::LoadTranslation('ID_LOADING');
switch($page){
case "startCase":
$labels = G::getTranslations(Array(
'ID_FIND_A_PROCESS',
'ID_PROCESS_INFORMATION', 'ID_PROCESS', 'ID_TASK', 'ID_DESCRIPTION', 'ID_CATEGORY',
'ID_GENERAL_PROCESS_NUMBERS', 'ID_INBOX', 'ID_DRAFT', 'ID_COMPLETED', 'ID_CANCELLED', 'ID_TOTAL_CASES',
@@ -23,30 +29,43 @@
'ID_SUN', 'ID_MON', 'ID_TUE', 'ID_WEN', 'ID_THU', 'ID_FRI', 'ID_SAT',
'ID_TITLE_START_CASE', 'ID_STARTING_NEW_CASE', 'ID_ERROR_CREATING_NEW_CASE',
'ID_ERROR', 'ID_UNABLE_START_CASE'
));
$oHeadPublisher->assign('TRANSLATIONS', $labels);
));
$oHeadPublisher->assign('TRANSLATIONS', $labels);
$oHeadPublisher->usingExtJs('ux.treefilterx/Ext.ux.tree.TreeFilterX');
$oHeadPublisher->addExtJsScript('cases/casesStartCase', false); //adding a javascript file .js
$oHeadPublisher->addContent( 'cases/casesStartCase'); //adding a html file .html.
$oHeadPublisher->usingExtJs('ux.treefilterx/Ext.ux.tree.TreeFilterX');
$oHeadPublisher->addExtJsScript('cases/casesStartCase', false); //adding a javascript file .js
$oHeadPublisher->addContent( 'cases/casesStartCase'); //adding a html file .html.
break;
case "documents":
$labels = G::getTranslations(Array(
'ID_FIND_A_PROCESS',
'ID_PROCESS_INFORMATION', 'ID_PROCESS', 'ID_TASK', 'ID_DESCRIPTION', 'ID_CATEGORY',
'ID_GENERAL_PROCESS_NUMBERS', 'ID_INBOX', 'ID_DRAFT', 'ID_COMPLETED', 'ID_CANCELLED', 'ID_TOTAL_CASES',
'ID_CALENDAR', 'ID_CALENDAR_DESCRIPTION', 'ID_WORKING_DAYS', 'ID_DEBUG_MODE',
'ID_SUN', 'ID_MON', 'ID_TUE', 'ID_WEN', 'ID_THU', 'ID_FRI', 'ID_SAT',
'ID_TITLE_START_CASE', 'ID_STARTING_NEW_CASE', 'ID_ERROR_CREATING_NEW_CASE',
'ID_ERROR', 'ID_UNABLE_START_CASE'
));
$oHeadPublisher->assign('TRANSLATIONS', $labels);
$oHeadPublisher->usingExtJs('ux.locationbar/Ext.ux.LocationBar');
$oHeadPublisher->usingExtJs('ux.statusbar/ext-statusbar');
$oHeadPublisher->addExtJsScript('cases/casesDocuments', false); //adding a javascript file .js
$oHeadPublisher->addContent( 'cases/casesDocuments'); //adding a html file .html.
break;
default:
$oHeadPublisher->usingExtJs('ux.treefilterx/Ext.ux.tree.TreeFilterX');
$oHeadPublisher->usingExtJs('ux.locationbar/Ext.ux.LocationBar');
$oHeadPublisher->usingExtJs('ux.statusbar/ext-statusbar');
$oHeadPublisher->addExtJsScript('cases/casesStartPage', false); //adding a javascript file .js
$oHeadPublisher->addContent( 'cases/casesStartPage'); //adding a html file .html.
break;
case "documents":
$oHeadPublisher->usingExtJs('ux.locationbar/Ext.ux.LocationBar');
$oHeadPublisher->usingExtJs('ux.statusbar/ext-statusbar');
$oHeadPublisher->addExtJsScript('cases/casesDocuments', false); //adding a javascript file .js
$oHeadPublisher->addContent( 'cases/casesDocuments'); //adding a html file .html.
break;
default:
$oHeadPublisher->usingExtJs('ux.treefilterx/Ext.ux.tree.TreeFilterX');
$oHeadPublisher->usingExtJs('ux.locationbar/Ext.ux.LocationBar');
$oHeadPublisher->usingExtJs('ux.statusbar/ext-statusbar');
$oHeadPublisher->addExtJsScript('cases/casesStartPage', false); //adding a javascript file .js
$oHeadPublisher->addContent( 'cases/casesStartPage'); //adding a html file .html.
break;
}
G::RenderPage('publish', 'extJs');
}
G::RenderPage('publish', 'extJs');

View File

@@ -121,6 +121,32 @@ Ext.onReady(function() {
labelStyle: 'font-weight:bold;',
items: [
{
xtype : 'button',
id : 'starCaseButton',
disabled : true,
// cls :
// 'x-btn-icon',
// icon :
// '/images/refresh.gif',
iconCls : "ICON_CASES_START_CASE",
text : TRANSLATIONS.ID_TITLE_START_CASE, // "Start
// Case",
// margins:"5 5
// 5 5",
autoWidth : true,
handler : function() {
tree = Ext
.getCmp('startCaseTreePanel');
var selectedNode = tree
.getSelectionModel()
.getSelectedNode();
if (selectedNode) {
//mainPanel.openCase(selectedNode);
openCaseA(selectedNode);
}
}
},
{
xtype : 'displayfield',
@@ -133,26 +159,8 @@ Ext.onReady(function() {
width:200,
// disabled: true,
id:"taskName"
},
{
xtype : 'button',
id : 'starCaseButton',
disabled : true,
//cls : 'x-btn-icon',
//icon : '/images/refresh.gif',
iconCls: "ICON_CASES_START_CASE",
text: TRANSLATIONS.ID_TITLE_START_CASE, // "Start Case",
//margins:"5 5 5 5",
autoWidth:true,
handler : function() {
tree = Ext.getCmp('startCaseTreePanel');
var selectedNode = tree.getSelectionModel().getSelectedNode();
if(selectedNode){
//mainPanel.openCase(selectedNode);
openCaseA(selectedNode);
}
}
}
]
},
@@ -191,7 +199,7 @@ Ext.onReady(function() {
//autoExpandColumn: 'company',
//height: 350,
width: 355,
title: TRANSLATIONS.ID_GENERAL_PROCESS_NUMBERS, // 'General Process Numbers',
//title: TRANSLATIONS.ID_GENERAL_PROCESS_NUMBERS, // 'General Process Numbers',
border: true,
listeners: {
viewready: function(g) {
@@ -206,7 +214,7 @@ Ext.onReady(function() {
labelStyle: 'font-weight:bold;',
// disabled: true,
id:"calendarName"
},{
},/*{
xtype:'textarea',
fieldLabel: TRANSLATIONS.ID_CALENDAR_DESCRIPTION, // 'Calendar Description',
name: 'calendarDescription',
@@ -215,7 +223,7 @@ Ext.onReady(function() {
// disabled: true,
readOnly: true,
id:"calendarDescription"
},{
},*/{
xtype:'checkboxgroup',
fieldLabel: TRANSLATIONS.ID_WORKING_DAYS, // 'Working days',
name: 'calendarWorkDays',