CODE STYLE Formating workflow/engine/methods/cases
Change format files in workflow/engine/methods/cases
This commit is contained in:
@@ -167,3 +167,4 @@ catch ( Exception $e ){
|
|||||||
$G_PUBLISH->AddContent('xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
$G_PUBLISH->AddContent('xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
||||||
G::RenderPage('publish');
|
G::RenderPage('publish');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -20,19 +20,16 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
$actionAjax = isset( $_REQUEST['actionAjax'] ) ? $_REQUEST['actionAjax'] : null;
|
$actionAjax = isset( $_REQUEST['actionAjax'] ) ? $_REQUEST['actionAjax'] : null;
|
||||||
|
|
||||||
|
function casesShowOuputDocumentExist ($url)
|
||||||
function casesShowOuputDocumentExist($url){
|
{
|
||||||
|
|
||||||
$urlArray = explode( "?", $url );
|
$urlArray = explode( "?", $url );
|
||||||
$urlParametroString = $urlArray[1];
|
$urlParametroString = $urlArray[1];
|
||||||
|
|
||||||
parse_str( $urlParametroString, $_GET );
|
parse_str( $urlParametroString, $_GET );
|
||||||
|
|
||||||
|
|
||||||
require_once ("classes/model/AppDocumentPeer.php");
|
require_once ("classes/model/AppDocumentPeer.php");
|
||||||
|
|
||||||
$oAppDocument = new AppDocument();
|
$oAppDocument = new AppDocument();
|
||||||
@@ -42,12 +39,10 @@
|
|||||||
$info = pathinfo( $oAppDocument->getAppDocFilename() );
|
$info = pathinfo( $oAppDocument->getAppDocFilename() );
|
||||||
if (! isset( $_GET['ext'] )) {
|
if (! isset( $_GET['ext'] )) {
|
||||||
$ext = $info['extension'];
|
$ext = $info['extension'];
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
if ($_GET['ext'] != '') {
|
if ($_GET['ext'] != '') {
|
||||||
$ext = $_GET['ext'];
|
$ext = $_GET['ext'];
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$ext = $info['extension'];
|
$ext = $info['extension'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -82,7 +77,7 @@
|
|||||||
|
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
G::loadClass( 'configuration' );
|
G::loadClass( 'configuration' );
|
||||||
$conf = new Configurations;
|
$conf = new Configurations();
|
||||||
$oHeadPublisher->addExtJsScript( 'cases/casesGenerateDocumentPage', true ); //adding a javascript file .js
|
$oHeadPublisher->addExtJsScript( 'cases/casesGenerateDocumentPage', true ); //adding a javascript file .js
|
||||||
$oHeadPublisher->addContent( 'cases/casesGenerateDocumentPage' ); //adding a html file .html.
|
$oHeadPublisher->addContent( 'cases/casesGenerateDocumentPage' ); //adding a html file .html.
|
||||||
$oHeadPublisher->assign( 'pageSize', $conf->getEnvSetting( 'casesListRowNumber' ) );
|
$oHeadPublisher->assign( 'pageSize', $conf->getEnvSetting( 'casesListRowNumber' ) );
|
||||||
@@ -101,8 +96,7 @@
|
|||||||
$c = $oCase->getAllGeneratedDocumentsCriteria( $_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_SESSION['TASK'], $_SESSION['USER_LOGGED'] );
|
$c = $oCase->getAllGeneratedDocumentsCriteria( $_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_SESSION['TASK'], $_SESSION['USER_LOGGED'] );
|
||||||
if ($c->getDbName() == 'dbarray') {
|
if ($c->getDbName() == 'dbarray') {
|
||||||
$rs = ArrayBasePeer::doSelectRs( $c );
|
$rs = ArrayBasePeer::doSelectRs( $c );
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
$rs = GulliverBasePeer::doSelectRs( $c );
|
$rs = GulliverBasePeer::doSelectRs( $c );
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -118,7 +112,6 @@
|
|||||||
|
|
||||||
$aProcesses[] = $result;
|
$aProcesses[] = $result;
|
||||||
|
|
||||||
|
|
||||||
$rs->next();
|
$rs->next();
|
||||||
$totalCount ++;
|
$totalCount ++;
|
||||||
}
|
}
|
||||||
@@ -128,8 +121,7 @@
|
|||||||
$conf = new Configurations();
|
$conf = new Configurations();
|
||||||
try {
|
try {
|
||||||
$generalConfCasesList = $conf->getConfiguration( 'ENVIRONMENT_SETTINGS', '' );
|
$generalConfCasesList = $conf->getConfiguration( 'ENVIRONMENT_SETTINGS', '' );
|
||||||
}
|
} catch (Exception $e) {
|
||||||
catch (Exception $e){
|
|
||||||
$generalConfCasesList = array ();
|
$generalConfCasesList = array ();
|
||||||
}
|
}
|
||||||
$dateFormat = "";
|
$dateFormat = "";
|
||||||
@@ -137,8 +129,6 @@
|
|||||||
$dateFormat = $generalConfCasesList['casesListDateFormat'];
|
$dateFormat = $generalConfCasesList['casesListDateFormat'];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$newDir = '/tmp/test/directory';
|
$newDir = '/tmp/test/directory';
|
||||||
$r = G::verifyPath( $newDir );
|
$r = G::verifyPath( $newDir );
|
||||||
$r->data = $aProcesses;
|
$r->data = $aProcesses;
|
||||||
@@ -146,4 +136,4 @@
|
|||||||
$r->dataFormat = $dateFormat;
|
$r->dataFormat = $dateFormat;
|
||||||
echo G::json_encode( $r );
|
echo G::json_encode( $r );
|
||||||
}
|
}
|
||||||
?>
|
|
||||||
|
|||||||
@@ -20,17 +20,15 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$actionAjax = isset( $_REQUEST['actionAjax'] ) ? $_REQUEST['actionAjax'] : null;
|
$actionAjax = isset( $_REQUEST['actionAjax'] ) ? $_REQUEST['actionAjax'] : null;
|
||||||
|
|
||||||
|
|
||||||
if ($actionAjax == "historyDynaformPage") {
|
if ($actionAjax == "historyDynaformPage") {
|
||||||
global $G_PUBLISH;
|
global $G_PUBLISH;
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
G::loadClass( 'configuration' );
|
G::loadClass( 'configuration' );
|
||||||
$conf = new Configurations;
|
$conf = new Configurations();
|
||||||
$oHeadPublisher->addExtJsScript( 'cases/caseHistoryDynaformPage', true ); //adding a javascript file .js
|
$oHeadPublisher->addExtJsScript( 'cases/caseHistoryDynaformPage', true ); //adding a javascript file .js
|
||||||
$oHeadPublisher->addContent( 'cases/caseHistoryDynaformPage' ); //adding a html file .html.
|
$oHeadPublisher->addContent( 'cases/caseHistoryDynaformPage' ); //adding a html file .html.
|
||||||
$oHeadPublisher->assign( 'pageSize', $conf->getEnvSetting( 'casesListRowNumber' ) );
|
$oHeadPublisher->assign( 'pageSize', $conf->getEnvSetting( 'casesListRowNumber' ) );
|
||||||
@@ -48,8 +46,7 @@
|
|||||||
|
|
||||||
if ($c->getDbName() == 'dbarray') {
|
if ($c->getDbName() == 'dbarray') {
|
||||||
$rs = ArrayBasePeer::doSelectRs( $c );
|
$rs = ArrayBasePeer::doSelectRs( $c );
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
$rs = GulliverBasePeer::doSelectRs( $c );
|
$rs = GulliverBasePeer::doSelectRs( $c );
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -71,7 +68,6 @@
|
|||||||
echo G::json_encode( $r );
|
echo G::json_encode( $r );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if ($actionAjax == 'showHistoryMessage') {
|
if ($actionAjax == 'showHistoryMessage') {
|
||||||
?>
|
?>
|
||||||
<link rel="stylesheet" type="text/css" href="/css/classic.css" />
|
<link rel="stylesheet" type="text/css" href="/css/classic.css" />
|
||||||
@@ -79,6 +75,7 @@
|
|||||||
html {
|
html {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
@@ -110,7 +107,6 @@
|
|||||||
|
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_MessagesView', '', $oCase->getHistoryMessagesTrackerView( $_POST['APP_UID'], $_POST['APP_MSG_UID'] ) );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_MessagesView', '', $oCase->getHistoryMessagesTrackerView( $_POST['APP_UID'], $_POST['APP_MSG_UID'] ) );
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<script language="javascript">
|
<script language="javascript">
|
||||||
<?php
|
<?php
|
||||||
@@ -138,6 +134,7 @@
|
|||||||
html {
|
html {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
@@ -224,6 +221,7 @@
|
|||||||
html {
|
html {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
@@ -250,7 +248,6 @@
|
|||||||
$_POST['DYN_UID'] = $_REQUEST['DYN_UID'];
|
$_POST['DYN_UID'] = $_REQUEST['DYN_UID'];
|
||||||
$_POST['HISTORY_ID'] = $_REQUEST['HISTORY_ID'];
|
$_POST['HISTORY_ID'] = $_REQUEST['HISTORY_ID'];
|
||||||
|
|
||||||
|
|
||||||
global $G_PUBLISH;
|
global $G_PUBLISH;
|
||||||
$G_PUBLISH = new Publisher();
|
$G_PUBLISH = new Publisher();
|
||||||
$FieldsHistory = unserialize( $_SESSION['HISTORY_DATA'] );
|
$FieldsHistory = unserialize( $_SESSION['HISTORY_DATA'] );
|
||||||
@@ -261,7 +258,6 @@
|
|||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_ACTION'] = 'return false;';
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_ACTION'] = 'return false;';
|
||||||
$G_PUBLISH->AddContent( 'dynaform', 'xmlform', $_SESSION['PROCESS'] . '/' . $_POST['DYN_UID'], '', $Fields['APP_DATA'], '', '', 'view' );
|
$G_PUBLISH->AddContent( 'dynaform', 'xmlform', $_SESSION['PROCESS'] . '/' . $_POST['DYN_UID'], '', $Fields['APP_DATA'], '', '', 'view' );
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<script language="javascript">
|
<script language="javascript">
|
||||||
<?php
|
<?php
|
||||||
@@ -283,6 +279,7 @@
|
|||||||
html {
|
html {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
@@ -337,5 +334,5 @@ function loadForm_<?php echo $G_FORM->id;?>(parametro1) {
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
G::RenderPage( 'publish', 'raw' );
|
G::RenderPage( 'publish', 'raw' );
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -11,8 +11,7 @@ if (isset($_GET['ux'])) {
|
|||||||
default:
|
default:
|
||||||
$url = 'casesListExtJs';
|
$url = 'casesListExtJs';
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$url = 'casesListExtJs';
|
$url = 'casesListExtJs';
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -29,3 +28,4 @@ if (isset($_GET['ux'])) {
|
|||||||
?>
|
?>
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
require_once 'classes/model/Application.php';
|
require_once 'classes/model/Application.php';
|
||||||
require_once 'classes/model/Users.php';
|
require_once 'classes/model/Users.php';
|
||||||
@@ -45,7 +44,8 @@
|
|||||||
global $oAppCache;
|
global $oAppCache;
|
||||||
$oAppCache = new AppCacheView();
|
$oAppCache = new AppCacheView();
|
||||||
$processes = Array ();
|
$processes = Array ();
|
||||||
$processes[] = array ( '', G::LoadTranslation('ID_ALL_PROCESS') );
|
$processes[] = array ('',G::LoadTranslation( 'ID_ALL_PROCESS' )
|
||||||
|
);
|
||||||
|
|
||||||
//get the list based in the action provided
|
//get the list based in the action provided
|
||||||
switch ($action) {
|
switch ($action) {
|
||||||
@@ -60,7 +60,7 @@
|
|||||||
//in search action, the query to obtain all process is too slow, so we need to query directly to
|
//in search action, the query to obtain all process is too slow, so we need to query directly to
|
||||||
//process and content tables, and for that reason we need the current language in AppCacheView.
|
//process and content tables, and for that reason we need the current language in AppCacheView.
|
||||||
G::loadClass( 'configuration' );
|
G::loadClass( 'configuration' );
|
||||||
$oConf = new Configurations;
|
$oConf = new Configurations();
|
||||||
$oConf->loadConfig( $x, 'APP_CACHE_VIEW_ENGINE', '', '', '', '' );
|
$oConf->loadConfig( $x, 'APP_CACHE_VIEW_ENGINE', '', '', '', '' );
|
||||||
$appCacheViewEngine = $oConf->aConfig;
|
$appCacheViewEngine = $oConf->aConfig;
|
||||||
$lang = isset( $appCacheViewEngine['LANG'] ) ? $appCacheViewEngine['LANG'] : 'en';
|
$lang = isset( $appCacheViewEngine['LANG'] ) ? $appCacheViewEngine['LANG'] : 'en';
|
||||||
@@ -74,9 +74,12 @@
|
|||||||
}
|
}
|
||||||
$del = DBAdapter::getStringDelimiter();
|
$del = DBAdapter::getStringDelimiter();
|
||||||
$conds = array ();
|
$conds = array ();
|
||||||
$conds[] = array(ProcessPeer::PRO_UID, ContentPeer::CON_ID );
|
$conds[] = array (ProcessPeer::PRO_UID,ContentPeer::CON_ID
|
||||||
$conds[] = array(ContentPeer::CON_CATEGORY, $del . 'PRO_TITLE' . $del);
|
);
|
||||||
$conds[] = array(ContentPeer::CON_LANG, $del . $lang . $del);
|
$conds[] = array (ContentPeer::CON_CATEGORY,$del . 'PRO_TITLE' . $del
|
||||||
|
);
|
||||||
|
$conds[] = array (ContentPeer::CON_LANG,$del . $lang . $del
|
||||||
|
);
|
||||||
$cProcess->addJoinMC( $conds, Criteria::LEFT_JOIN );
|
$cProcess->addJoinMC( $conds, Criteria::LEFT_JOIN );
|
||||||
$cProcess->add( ProcessPeer::PRO_STATUS, 'ACTIVE' );
|
$cProcess->add( ProcessPeer::PRO_STATUS, 'ACTIVE' );
|
||||||
$oDataset = ProcessPeer::doSelectRS( $cProcess );
|
$oDataset = ProcessPeer::doSelectRS( $cProcess );
|
||||||
@@ -84,7 +87,8 @@
|
|||||||
$oDataset->next();
|
$oDataset->next();
|
||||||
|
|
||||||
while ($aRow = $oDataset->getRow()) {
|
while ($aRow = $oDataset->getRow()) {
|
||||||
$processes[] = array ( $aRow['PRO_UID'], $aRow['CON_VALUE'] );
|
$processes[] = array ($aRow['PRO_UID'],$aRow['CON_VALUE']
|
||||||
|
);
|
||||||
$oDataset->next();
|
$oDataset->next();
|
||||||
}
|
}
|
||||||
return print G::json_encode( $processes );
|
return print G::json_encode( $processes );
|
||||||
@@ -127,7 +131,8 @@
|
|||||||
$oDataset->next();
|
$oDataset->next();
|
||||||
|
|
||||||
while ($aRow = $oDataset->getRow()) {
|
while ($aRow = $oDataset->getRow()) {
|
||||||
$processes[] = array ( $aRow['PRO_UID'], $aRow['APP_PRO_TITLE'] );
|
$processes[] = array ($aRow['PRO_UID'],$aRow['APP_PRO_TITLE']
|
||||||
|
);
|
||||||
$oDataset->next();
|
$oDataset->next();
|
||||||
}
|
}
|
||||||
return print G::json_encode( $processes );
|
return print G::json_encode( $processes );
|
||||||
@@ -147,7 +152,6 @@
|
|||||||
$_SESSION['APPLICATION'] = $APP_UID;
|
$_SESSION['APPLICATION'] = $APP_UID;
|
||||||
$_SESSION['INDEX'] = $DEL_INDEX;
|
$_SESSION['INDEX'] = $DEL_INDEX;
|
||||||
|
|
||||||
|
|
||||||
$cases = new Cases();
|
$cases = new Cases();
|
||||||
$user = new Users();
|
$user = new Users();
|
||||||
$app = new Application();
|
$app = new Application();
|
||||||
@@ -170,10 +174,8 @@
|
|||||||
|
|
||||||
print G::json_encode( $result );
|
print G::json_encode( $result );
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if ($actionAjax == 'showHistoryMessage') {
|
if ($actionAjax == 'showHistoryMessage') {
|
||||||
?>
|
?>
|
||||||
<link rel="stylesheet" type="text/css" href="/css/classic.css" />
|
<link rel="stylesheet" type="text/css" href="/css/classic.css" />
|
||||||
@@ -181,6 +183,7 @@
|
|||||||
html {
|
html {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
@@ -212,7 +215,6 @@
|
|||||||
|
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_MessagesView', '', $oCase->getHistoryMessagesTrackerView( $_POST['APP_UID'], $_POST['APP_MSG_UID'] ) );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_MessagesView', '', $oCase->getHistoryMessagesTrackerView( $_POST['APP_UID'], $_POST['APP_MSG_UID'] ) );
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<script language="javascript">
|
<script language="javascript">
|
||||||
<?php
|
<?php
|
||||||
@@ -240,6 +242,7 @@
|
|||||||
html {
|
html {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
@@ -326,6 +329,7 @@
|
|||||||
html {
|
html {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
@@ -352,7 +356,6 @@
|
|||||||
$_POST['DYN_UID'] = $_REQUEST['DYN_UID'];
|
$_POST['DYN_UID'] = $_REQUEST['DYN_UID'];
|
||||||
$_POST['HISTORY_ID'] = $_REQUEST['HISTORY_ID'];
|
$_POST['HISTORY_ID'] = $_REQUEST['HISTORY_ID'];
|
||||||
|
|
||||||
|
|
||||||
global $G_PUBLISH;
|
global $G_PUBLISH;
|
||||||
$G_PUBLISH = new Publisher();
|
$G_PUBLISH = new Publisher();
|
||||||
$FieldsHistory = unserialize( $_SESSION['HISTORY_DATA'] );
|
$FieldsHistory = unserialize( $_SESSION['HISTORY_DATA'] );
|
||||||
@@ -363,7 +366,6 @@
|
|||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_ACTION'] = 'return false;';
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_ACTION'] = 'return false;';
|
||||||
$G_PUBLISH->AddContent( 'dynaform', 'xmlform', $_SESSION['PROCESS'] . '/' . $_POST['DYN_UID'], '', $Fields['APP_DATA'], '', '', 'view' );
|
$G_PUBLISH->AddContent( 'dynaform', 'xmlform', $_SESSION['PROCESS'] . '/' . $_POST['DYN_UID'], '', $Fields['APP_DATA'], '', '', 'view' );
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<script language="javascript">
|
<script language="javascript">
|
||||||
<?php
|
<?php
|
||||||
@@ -385,14 +387,13 @@
|
|||||||
html {
|
html {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: black !important;
|
color: black !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
<script language="Javascript">
|
<script language="Javascript">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//!Code that simulated reload library javascript maborak
|
//!Code that simulated reload library javascript maborak
|
||||||
var leimnud = {};
|
var leimnud = {};
|
||||||
leimnud.exec = "";
|
leimnud.exec = "";
|
||||||
@@ -435,5 +436,5 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
G::RenderPage( 'publish', 'raw' );
|
G::RenderPage( 'publish', 'raw' );
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -17,8 +17,8 @@
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getLoadTreeMenuData ()
|
||||||
function getLoadTreeMenuData () {
|
{
|
||||||
header( "content-type: text/xml" );
|
header( "content-type: text/xml" );
|
||||||
|
|
||||||
global $G_TMP_MENU;
|
global $G_TMP_MENU;
|
||||||
@@ -26,28 +26,14 @@
|
|||||||
$oMenu->load( 'cases' );
|
$oMenu->load( 'cases' );
|
||||||
|
|
||||||
$oCases = new Cases();
|
$oCases = new Cases();
|
||||||
$aTypes = Array(
|
$aTypes = Array ('to_do','draft','cancelled','sent','paused','completed','selfservice'
|
||||||
'to_do',
|
|
||||||
'draft',
|
|
||||||
'cancelled',
|
|
||||||
'sent',
|
|
||||||
'paused',
|
|
||||||
'completed',
|
|
||||||
'selfservice',
|
|
||||||
//'to_revise',
|
//'to_revise',
|
||||||
//'to_reassign'
|
//'to_reassign'
|
||||||
);
|
;
|
||||||
$aTypesID = Array(
|
$aTypesID = Array ('CASES_INBOX' => 'to_do','CASES_DRAFT' => 'draft','CASES_CANCELLED' => 'cancelled','CASES_SENT' => 'sent','CASES_PAUSED' => 'paused','CASES_COMPLETED' => 'completed','CASES_SELFSERVICE' => 'selfservice'
|
||||||
'CASES_INBOX'=>'to_do',
|
|
||||||
'CASES_DRAFT'=>'draft',
|
|
||||||
'CASES_CANCELLED'=>'cancelled',
|
|
||||||
'CASES_SENT'=>'sent',
|
|
||||||
'CASES_PAUSED'=>'paused',
|
|
||||||
'CASES_COMPLETED'=>'completed',
|
|
||||||
'CASES_SELFSERVICE'=>'selfservice',
|
|
||||||
//'CASES_TO_REVISE'=>'to_revise',
|
//'CASES_TO_REVISE'=>'to_revise',
|
||||||
//'CASES_TO_REASSIGN'=>'to_reassign'
|
//'CASES_TO_REASSIGN'=>'to_reassign'
|
||||||
);
|
;
|
||||||
|
|
||||||
$list = array ();
|
$list = array ();
|
||||||
$list['count'] = ' ';
|
$list['count'] = ' ';
|
||||||
@@ -80,10 +66,7 @@
|
|||||||
$menuCases[$CurrentBlockID]['blockType'] = $oMenu->Types[$i];
|
$menuCases[$CurrentBlockID]['blockType'] = $oMenu->Types[$i];
|
||||||
$menuCases[$CurrentBlockID]['link'] = $oMenu->Options[$i];
|
$menuCases[$CurrentBlockID]['link'] = $oMenu->Options[$i];
|
||||||
} else {
|
} else {
|
||||||
$menuCases[$CurrentBlockID]['blockItems'][$oMenu->Id[$i]] = Array (
|
$menuCases[$CurrentBlockID]['blockItems'][$oMenu->Id[$i]] = Array ('label' => $oMenu->Labels[$i],'link' => $oMenu->Options[$i],'icon' => (isset( $oMenu->Icons[$i] ) && $oMenu->Icons[$i] != '') ? $oMenu->Icons[$i] : 'kcmdf.png'
|
||||||
'label' => $oMenu->Labels[$i],
|
|
||||||
'link' => $oMenu->Options[$i],
|
|
||||||
'icon' => (isset($oMenu->Icons[$i]) && $oMenu->Icons[$i] != '') ? $oMenu->Icons[$i] : 'kcmdf.png'
|
|
||||||
);
|
);
|
||||||
|
|
||||||
if (isset( $aTypesID[$oMenu->Id[$i]] )) {
|
if (isset( $aTypesID[$oMenu->Id[$i]] )) {
|
||||||
@@ -105,8 +88,7 @@
|
|||||||
$i ++;
|
$i ++;
|
||||||
if (isset( $aMenu['cases_count'] ) && $aMenu['cases_count'] !== '') {
|
if (isset( $aMenu['cases_count'] ) && $aMenu['cases_count'] !== '') {
|
||||||
$nofifier = "cases_count=\"{$aMenu['cases_count']}\" ";
|
$nofifier = "cases_count=\"{$aMenu['cases_count']}\" ";
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$nofifier = '';
|
$nofifier = '';
|
||||||
}
|
}
|
||||||
$xml .= '<option title="' . $aMenu['label'] . '" id="' . $id . '" ' . $nofifier . ' url="' . $aMenu['link'] . '">';
|
$xml .= '<option title="' . $aMenu['label'] . '" id="' . $id . '" ' . $nofifier . ' url="' . $aMenu['link'] . '">';
|
||||||
@@ -128,11 +110,12 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
// get the process summary of specific case list type,
|
// get the process summary of specific case list type,
|
||||||
function getProcess () {
|
function getProcess ()
|
||||||
|
{
|
||||||
global $G_TMP_MENU;
|
global $G_TMP_MENU;
|
||||||
global $userId;
|
global $userId;
|
||||||
if (! isset( $_GET['item'] )) {
|
if (! isset( $_GET['item'] )) {
|
||||||
die;
|
die();
|
||||||
}
|
}
|
||||||
|
|
||||||
$oMenu = new Menu();
|
$oMenu = new Menu();
|
||||||
@@ -150,9 +133,11 @@
|
|||||||
$aTypesID['CASES_SELFSERVICE'] = 'selfservice';
|
$aTypesID['CASES_SELFSERVICE'] = 'selfservice';
|
||||||
//$aTypesID['CASES_TO_REVISE'] = 'to_revise';
|
//$aTypesID['CASES_TO_REVISE'] = 'to_revise';
|
||||||
//$aTypesID['CASES_TO_REASSIGN'] = 'to_reassign';
|
//$aTypesID['CASES_TO_REASSIGN'] = 'to_reassign';
|
||||||
$aTypesID = Array('CASES_INBOX'=>'to_do', 'CASES_DRAFT'=>'draft', 'CASES_CANCELLED'=>'cancelled', 'CASES_SENT'=>'sent', 'CASES_PAUSED'=>'paused', 'CASES_COMPLETED'=>'completed','CASES_SELFSERVICE'=>'selfservice','CASES_TO_REVISE'=>'to_revise','CASES_TO_REASSIGN'=>'to_reassign');
|
$aTypesID = Array ('CASES_INBOX' => 'to_do','CASES_DRAFT' => 'draft','CASES_CANCELLED' => 'cancelled','CASES_SENT' => 'sent','CASES_PAUSED' => 'paused','CASES_COMPLETED' => 'completed','CASES_SELFSERVICE' => 'selfservice','CASES_TO_REVISE' => 'to_revise','CASES_TO_REASSIGN' => 'to_reassign'
|
||||||
|
);
|
||||||
|
|
||||||
$aCount = $oCases->getAllCounters(Array($aTypesID[$type]), $userId, true);
|
$aCount = $oCases->getAllCounters( Array ($aTypesID[$type]
|
||||||
|
), $userId, true );
|
||||||
|
|
||||||
$response = Array ();
|
$response = Array ();
|
||||||
//disabling the summary...
|
//disabling the summary...
|
||||||
@@ -183,7 +168,8 @@
|
|||||||
echo G::json_encode( $response );
|
echo G::json_encode( $response );
|
||||||
}
|
}
|
||||||
|
|
||||||
function getAllCounters() {
|
function getAllCounters ()
|
||||||
|
{
|
||||||
$userUid = (isset( $_SESSION['USER_LOGGED'] ) && $_SESSION['USER_LOGGED'] != '') ? $_SESSION['USER_LOGGED'] : null;
|
$userUid = (isset( $_SESSION['USER_LOGGED'] ) && $_SESSION['USER_LOGGED'] != '') ? $_SESSION['USER_LOGGED'] : null;
|
||||||
$oAppCache = new AppCacheView();
|
$oAppCache = new AppCacheView();
|
||||||
$aTypes = Array ();
|
$aTypes = Array ();
|
||||||
@@ -197,6 +183,7 @@
|
|||||||
//$aTypes['to_revise'] = 'CASES_TO_REVISE';
|
//$aTypes['to_revise'] = 'CASES_TO_REVISE';
|
||||||
//$aTypes['to_reassign'] = 'CASES_TO_REASSIGN';
|
//$aTypes['to_reassign'] = 'CASES_TO_REASSIGN';
|
||||||
|
|
||||||
|
|
||||||
if ((($solrConf = System::solrEnv()) !== false)) {
|
if ((($solrConf = System::solrEnv()) !== false)) {
|
||||||
G::LoadClass( 'AppSolr' );
|
G::LoadClass( 'AppSolr' );
|
||||||
$ApplicationSolrIndex = new AppSolr( $solrConf['solr_enabled'], $solrConf['solr_host'], $solrConf['solr_instance'] );
|
$ApplicationSolrIndex = new AppSolr( $solrConf['solr_enabled'], $solrConf['solr_host'], $solrConf['solr_instance'] );
|
||||||
@@ -204,11 +191,11 @@
|
|||||||
$aCount = $ApplicationSolrIndex->getCasesCount( $userUid );
|
$aCount = $ApplicationSolrIndex->getCasesCount( $userUid );
|
||||||
|
|
||||||
//get paused count
|
//get paused count
|
||||||
$aCountMissing = $oAppCache->getAllCounters( array('paused', 'completed', 'cancelled'), $userUid );
|
$aCountMissing = $oAppCache->getAllCounters( array ('paused','completed','cancelled'
|
||||||
|
), $userUid );
|
||||||
|
|
||||||
$aCount = array_merge( $aCount, $aCountMissing );
|
$aCount = array_merge( $aCount, $aCountMissing );
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
|
|
||||||
$aCount = $oAppCache->getAllCounters( array_keys( $aTypes ), $userUid );
|
$aCount = $oAppCache->getAllCounters( array_keys( $aTypes ), $userUid );
|
||||||
|
|
||||||
|
|||||||
@@ -20,12 +20,12 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
//validate the data post
|
//validate the data post
|
||||||
//$oForm = new Form ( $_SESSION ['PROCESS'] . '/' . $_GET ['UID'], PATH_DYNAFORM );
|
//$oForm = new Form ( $_SESSION ['PROCESS'] . '/' . $_GET ['UID'], PATH_DYNAFORM );
|
||||||
//$oForm->validatePost ();
|
//$oForm->validatePost ();
|
||||||
|
|
||||||
|
|
||||||
/* @author Alvaro Campos Sanchez */
|
/* @author Alvaro Campos Sanchez */
|
||||||
/* Includes */
|
/* Includes */
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
@@ -64,7 +64,6 @@ if ($_SESSION ['TRIGGER_DEBUG'] ['NUM_TRIGGERS'] != 0) {
|
|||||||
//Execute after triggers - End
|
//Execute after triggers - End
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//go to the next step
|
//go to the next step
|
||||||
$aNextStep = $oCase->getNextStep( $_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['STEP_POSITION'] );
|
$aNextStep = $oCase->getNextStep( $_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['STEP_POSITION'] );
|
||||||
if (isset( $_GET['_REFRESH_'] )) {
|
if (isset( $_GET['_REFRESH_'] )) {
|
||||||
|
|||||||
@@ -20,14 +20,12 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
//if (($RBAC_Response=$RBAC->userCanAccess("PM_USERS"))!=1) return $RBAC_Response;
|
//if (($RBAC_Response=$RBAC->userCanAccess("PM_USERS"))!=1) return $RBAC_Response;
|
||||||
G::LoadInclude( 'ajax' );
|
G::LoadInclude( 'ajax' );
|
||||||
$_POST['action'] = get_ajax_value( 'action' );
|
$_POST['action'] = get_ajax_value( 'action' );
|
||||||
|
|
||||||
switch ($_POST['action'])
|
switch ($_POST['action']) {
|
||||||
{
|
|
||||||
case 'updatePageSize':
|
case 'updatePageSize':
|
||||||
G::LoadClass( 'configuration' );
|
G::LoadClass( 'configuration' );
|
||||||
$c = new Configurations();
|
$c = new Configurations();
|
||||||
@@ -41,4 +39,4 @@ switch ($_POST['action'])
|
|||||||
break;
|
break;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
?>
|
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ switch($page){
|
|||||||
case "startCase":
|
case "startCase":
|
||||||
$oHeadPublisher->addExtJsScript( 'cases/casesStartCase', true ); //adding a javascript file .js
|
$oHeadPublisher->addExtJsScript( 'cases/casesStartCase', true ); //adding a javascript file .js
|
||||||
|
|
||||||
|
|
||||||
$oHeadPublisher->addContent( 'cases/casesStartCase' ); //adding a html file .html.
|
$oHeadPublisher->addContent( 'cases/casesStartCase' ); //adding a html file .html.
|
||||||
G::LoadClass( 'configuration' );
|
G::LoadClass( 'configuration' );
|
||||||
$c = new Configurations();
|
$c = new Configurations();
|
||||||
@@ -43,5 +44,5 @@ switch($page){
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
G::RenderPage( 'publish', 'extJs' );
|
G::RenderPage( 'publish', 'extJs' );
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
if (! isset( $_REQUEST['action'] )) {
|
if (! isset( $_REQUEST['action'] )) {
|
||||||
$res['success'] = 'failure';
|
$res['success'] = 'failure';
|
||||||
$res['message'] = 'You may request an action';
|
$res['message'] = 'You may request an action';
|
||||||
@@ -18,7 +17,8 @@ $functionParams = isset ( $_REQUEST ['params'] ) ? $_REQUEST ['params'] : array
|
|||||||
|
|
||||||
$functionName( $functionParams );
|
$functionName( $functionParams );
|
||||||
|
|
||||||
function getProcessList() {
|
function getProcessList ()
|
||||||
|
{
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
G::LoadClass( 'process' );
|
G::LoadClass( 'process' );
|
||||||
G::LoadClass( 'calendar' );
|
G::LoadClass( 'calendar' );
|
||||||
@@ -53,7 +53,6 @@ function getProcessList() {
|
|||||||
$node = $_REQUEST['node'];
|
$node = $_REQUEST['node'];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
foreach ($proData as $key => $proInfo) {
|
foreach ($proData as $key => $proInfo) {
|
||||||
$proData[$proInfo['PRO_UID']] = $proInfo;
|
$proData[$proInfo['PRO_UID']] = $proInfo;
|
||||||
}
|
}
|
||||||
@@ -96,6 +95,7 @@ function getProcessList() {
|
|||||||
|
|
||||||
//$tempTree['cls']='file';
|
//$tempTree['cls']='file';
|
||||||
|
|
||||||
|
|
||||||
$tempTreeChildren[] = $tempTreeChild;
|
$tempTreeChildren[] = $tempTreeChild;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -136,7 +136,8 @@ function getProcessList() {
|
|||||||
die();
|
die();
|
||||||
}
|
}
|
||||||
|
|
||||||
function ellipsis($text, $numb) {
|
function ellipsis ($text, $numb)
|
||||||
|
{
|
||||||
$text = html_entity_decode( $text, ENT_QUOTES );
|
$text = html_entity_decode( $text, ENT_QUOTES );
|
||||||
if (strlen( $text ) > $numb) {
|
if (strlen( $text ) > $numb) {
|
||||||
$text = substr( $text, 0, $numb );
|
$text = substr( $text, 0, $numb );
|
||||||
@@ -152,7 +153,8 @@ function ellipsis($text, $numb) {
|
|||||||
return $text;
|
return $text;
|
||||||
}
|
}
|
||||||
|
|
||||||
function lookinginforContentProcess($sproUid){
|
function lookinginforContentProcess ($sproUid)
|
||||||
|
{
|
||||||
require_once 'classes/model/Content.php';
|
require_once 'classes/model/Content.php';
|
||||||
require_once 'classes/model/Task.php';
|
require_once 'classes/model/Task.php';
|
||||||
require_once 'classes/model/Content.php';
|
require_once 'classes/model/Content.php';
|
||||||
@@ -205,17 +207,22 @@ function ellipsis($text, $numb) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function startCase ()
|
||||||
function startCase() {
|
{
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
|
|
||||||
/* GET , POST & $_SESSION Vars */
|
/* GET , POST & $_SESSION Vars */
|
||||||
/* unset any variable, because we are starting a new case */
|
/* unset any variable, because we are starting a new case */
|
||||||
if (isset ( $_SESSION ['APPLICATION'] )) unset ( $_SESSION ['APPLICATION'] );
|
if (isset( $_SESSION['APPLICATION'] ))
|
||||||
if (isset ( $_SESSION ['PROCESS'] )) unset ( $_SESSION ['PROCESS'] );
|
unset( $_SESSION['APPLICATION'] );
|
||||||
if (isset ( $_SESSION ['TASK'] )) unset ( $_SESSION ['TASK'] );
|
if (isset( $_SESSION['PROCESS'] ))
|
||||||
if (isset ( $_SESSION ['INDEX'] )) unset ( $_SESSION ['INDEX'] );
|
unset( $_SESSION['PROCESS'] );
|
||||||
if (isset ( $_SESSION ['STEP_POSITION'] )) unset ( $_SESSION ['STEP_POSITION'] );
|
if (isset( $_SESSION['TASK'] ))
|
||||||
|
unset( $_SESSION['TASK'] );
|
||||||
|
if (isset( $_SESSION['INDEX'] ))
|
||||||
|
unset( $_SESSION['INDEX'] );
|
||||||
|
if (isset( $_SESSION['STEP_POSITION'] ))
|
||||||
|
unset( $_SESSION['STEP_POSITION'] );
|
||||||
|
|
||||||
/* Process */
|
/* Process */
|
||||||
try {
|
try {
|
||||||
@@ -248,15 +255,15 @@ function startCase() {
|
|||||||
|
|
||||||
$aData['status'] = 'success';
|
$aData['status'] = 'success';
|
||||||
print (G::json_encode( $aData )) ;
|
print (G::json_encode( $aData )) ;
|
||||||
}
|
} catch (Exception $e) {
|
||||||
catch ( Exception $e ) {
|
|
||||||
$aData['status'] = 'failure';
|
$aData['status'] = 'failure';
|
||||||
$aData['message'] = $e->getMessage();
|
$aData['message'] = $e->getMessage();
|
||||||
print_r( G::json_encode( $aData ) );
|
print_r( G::json_encode( $aData ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function getSimpleDashboardData() {
|
function getSimpleDashboardData ()
|
||||||
|
{
|
||||||
G::LoadClass( "BasePeer" );
|
G::LoadClass( "BasePeer" );
|
||||||
require_once ("classes/model/AppCacheView.php");
|
require_once ("classes/model/AppCacheView.php");
|
||||||
require_once 'classes/model/Process.php';
|
require_once 'classes/model/Process.php';
|
||||||
@@ -282,8 +289,10 @@ function getSimpleDashboardData() {
|
|||||||
$Criteria->addSelectColumn( AppCacheViewPeer::USR_UID );
|
$Criteria->addSelectColumn( AppCacheViewPeer::USR_UID );
|
||||||
$Criteria->addSelectColumn( AppCacheViewPeer::APP_THREAD_STATUS );
|
$Criteria->addSelectColumn( AppCacheViewPeer::APP_THREAD_STATUS );
|
||||||
|
|
||||||
$Criteria->add ( AppCacheViewPeer::APP_STATUS, array ("TO_DO", "DRAFT" ), CRITERIA::IN );
|
$Criteria->add( AppCacheViewPeer::APP_STATUS, array ("TO_DO","DRAFT"
|
||||||
$Criteria->add ( AppCacheViewPeer::USR_UID, array ($sUIDUserLogged, "" ), CRITERIA::IN );
|
), CRITERIA::IN );
|
||||||
|
$Criteria->add( AppCacheViewPeer::USR_UID, array ($sUIDUserLogged,""
|
||||||
|
), CRITERIA::IN );
|
||||||
|
|
||||||
$Criteria->add( AppCacheViewPeer::DEL_FINISH_DATE, null, Criteria::ISNULL );
|
$Criteria->add( AppCacheViewPeer::DEL_FINISH_DATE, null, Criteria::ISNULL );
|
||||||
|
|
||||||
@@ -310,9 +319,11 @@ function getSimpleDashboardData() {
|
|||||||
|
|
||||||
if ($aRow['USR_UID'] == "")
|
if ($aRow['USR_UID'] == "")
|
||||||
$aRow['APP_STATUS'] = "UNASSIGNED";
|
$aRow['APP_STATUS'] = "UNASSIGNED";
|
||||||
if (((in_array ( $aRow ['APP_STATUS'], array ("TO_DO", "UNASSIGNED" ) )) && ($aRow ['APP_THREAD_STATUS'] == "OPEN")) || ($aRow ['APP_STATUS'] == "DRAFT")) {
|
if (((in_array( $aRow['APP_STATUS'], array ("TO_DO","UNASSIGNED"
|
||||||
|
) )) && ($aRow['APP_THREAD_STATUS'] == "OPEN")) || ($aRow['APP_STATUS'] == "DRAFT")) {
|
||||||
$rows[$processNames[$aRow['PRO_UID']]][$aRow['APP_STATUS']][$aRow['DEL_DELAYED']][] = $aRow['APP_UID'];
|
$rows[$processNames[$aRow['PRO_UID']]][$aRow['APP_STATUS']][$aRow['DEL_DELAYED']][] = $aRow['APP_UID'];
|
||||||
if(!isset($rows [$processNames [$aRow ['PRO_UID']]] [$aRow ['APP_STATUS']]['count'])) $rows [$processNames [$aRow ['PRO_UID']]] [$aRow ['APP_STATUS']]['count']=0;
|
if (! isset( $rows[$processNames[$aRow['PRO_UID']]][$aRow['APP_STATUS']]['count'] ))
|
||||||
|
$rows[$processNames[$aRow['PRO_UID']]][$aRow['APP_STATUS']]['count'] = 0;
|
||||||
$rows[$processNames[$aRow['PRO_UID']]][$aRow['APP_STATUS']]['count'] ++;
|
$rows[$processNames[$aRow['PRO_UID']]][$aRow['APP_STATUS']]['count'] ++;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -324,26 +335,32 @@ function getSimpleDashboardData() {
|
|||||||
foreach ($rows as $processID => $processInfo) {
|
foreach ($rows as $processID => $processInfo) {
|
||||||
$i ++;
|
$i ++;
|
||||||
if ($i <= 10) {
|
if ($i <= 10) {
|
||||||
$rowsResponse['caseStatusByProcess'][]=array('process'=>$processID,'inbox'=>isset($processInfo['TO_DO']['count'])?$processInfo['TO_DO']['count']:0,'draft'=>isset($processInfo['DRAFT']['count'])?$processInfo['DRAFT']['count']:0,'unassigned'=>isset($processInfo['UNASSIGNED']['count'])?$processInfo['UNASSIGNED']['count']:0);
|
$rowsResponse['caseStatusByProcess'][] = array ('process' => $processID,'inbox' => isset( $processInfo['TO_DO']['count'] ) ? $processInfo['TO_DO']['count'] : 0,'draft' => isset( $processInfo['DRAFT']['count'] ) ? $processInfo['DRAFT']['count'] : 0,'unassigned' => isset( $processInfo['UNASSIGNED']['count'] ) ? $processInfo['UNASSIGNED']['count'] : 0
|
||||||
|
);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$rowsResponse['caseDelayed'][]=array('delayed'=>'On Time','total'=>100);
|
$rowsResponse['caseDelayed'][] = array ('delayed' => 'On Time','total' => 100
|
||||||
$rowsResponse['caseDelayed'][]=array('delayed'=>'Delayed','total'=>50);
|
);
|
||||||
|
$rowsResponse['caseDelayed'][] = array ('delayed' => 'Delayed','total' => 50
|
||||||
|
);
|
||||||
|
|
||||||
print_r( G::json_encode( $rowsResponse ) );
|
print_r( G::json_encode( $rowsResponse ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
function getRegisteredDashboards() {
|
function getRegisteredDashboards ()
|
||||||
|
{
|
||||||
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
||||||
$dashBoardPages = $oPluginRegistry->getDashboardPages();
|
$dashBoardPages = $oPluginRegistry->getDashboardPages();
|
||||||
print_r( G::json_encode( $dashBoardPages ) );
|
print_r( G::json_encode( $dashBoardPages ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
function getDefaultDashboard(){
|
function getDefaultDashboard ()
|
||||||
|
{
|
||||||
$defaultDashboard['defaultTab'] = "mainDashboard";
|
$defaultDashboard['defaultTab'] = "mainDashboard";
|
||||||
if (isset( $_SESSION['__currentTabDashboard'] )) {
|
if (isset( $_SESSION['__currentTabDashboard'] )) {
|
||||||
$defaultDashboard['defaultTab'] = $_SESSION['__currentTabDashboard'];
|
$defaultDashboard['defaultTab'] = $_SESSION['__currentTabDashboard'];
|
||||||
}
|
}
|
||||||
print_r( G::json_encode( $defaultDashboard ) );
|
print_r( G::json_encode( $defaultDashboard ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
// $oHeadPublisher =& headPublisher::getSingleton();
|
// $oHeadPublisher =& headPublisher::getSingleton();
|
||||||
|
|
||||||
// $TRANSLATIONS = array_merge($TRANSLATIONS, $TRANSLATIONS2);
|
// $TRANSLATIONS = array_merge($TRANSLATIONS, $TRANSLATIONS2);
|
||||||
$delIndex = $_GET['DEL_INDEX'];
|
$delIndex = $_GET['DEL_INDEX'];
|
||||||
$appUid = $_GET['APP_UID'];
|
$appUid = $_GET['APP_UID'];
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
class TreeNode {
|
class TreeNode
|
||||||
|
{
|
||||||
public $text = "";
|
public $text = "";
|
||||||
public $id = "";
|
public $id = "";
|
||||||
public $iconCls = "";
|
public $iconCls = "";
|
||||||
@@ -10,8 +10,8 @@ class TreeNode {
|
|||||||
public $href = "#";
|
public $href = "#";
|
||||||
public $hrefTarget = "";
|
public $hrefTarget = "";
|
||||||
|
|
||||||
function __construct($id,$text,$iconCls,$leaf,$draggable,$href,$hrefTarget) {
|
function __construct ($id, $text, $iconCls, $leaf, $draggable, $href, $hrefTarget)
|
||||||
|
{
|
||||||
$this->id = $id;
|
$this->id = $id;
|
||||||
$this->text = $text;
|
$this->text = $text;
|
||||||
$this->iconCls = $iconCls;
|
$this->iconCls = $iconCls;
|
||||||
@@ -21,18 +21,23 @@ class TreeNode {
|
|||||||
$this->hrefTarget = $hrefTarget;
|
$this->hrefTarget = $hrefTarget;
|
||||||
}
|
}
|
||||||
|
|
||||||
function toJson() {
|
function toJson ()
|
||||||
|
{
|
||||||
return G::json_encode( $this );
|
return G::json_encode( $this );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class ExtJsTreeNode extends TreeNode {
|
class ExtJsTreeNode extends TreeNode
|
||||||
|
{
|
||||||
public $children = array ();
|
public $children = array ();
|
||||||
function add($object) {
|
|
||||||
|
function add ($object)
|
||||||
|
{
|
||||||
$this->children[] = $object;
|
$this->children[] = $object;
|
||||||
}
|
}
|
||||||
|
|
||||||
function toJson() {
|
function toJson ()
|
||||||
|
{
|
||||||
return G::json_encode( $this );
|
return G::json_encode( $this );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -91,3 +96,4 @@ $treeArray = array();
|
|||||||
}
|
}
|
||||||
echo $extTreeInputDocs->toJson();
|
echo $extTreeInputDocs->toJson();
|
||||||
echo "]";
|
echo "]";
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
/*
|
/*
|
||||||
* Created on 13-02-2008
|
* Created on 13-02-2008
|
||||||
@@ -37,12 +36,10 @@ $sAppDocUid = $oAppDocument->getAppDocUid();
|
|||||||
$info = pathinfo( $oAppDocument->getAppDocFilename() );
|
$info = pathinfo( $oAppDocument->getAppDocFilename() );
|
||||||
if (! isset( $_GET['ext'] )) {
|
if (! isset( $_GET['ext'] )) {
|
||||||
$ext = $info['extension'];
|
$ext = $info['extension'];
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
if ($_GET['ext'] != '') {
|
if ($_GET['ext'] != '') {
|
||||||
$ext = $_GET['ext'];
|
$ext = $_GET['ext'];
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$ext = $info['extension'];
|
$ext = $info['extension'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -74,7 +71,7 @@ if(!$sw_file_exists){
|
|||||||
G::SendMessageText( $error_message, "ERROR" );
|
G::SendMessageText( $error_message, "ERROR" );
|
||||||
$backUrlObj = explode( "sys" . SYS_SYS, $_SERVER['HTTP_REFERER'] );
|
$backUrlObj = explode( "sys" . SYS_SYS, $_SERVER['HTTP_REFERER'] );
|
||||||
G::header( "location: " . "/sys" . SYS_SYS . $backUrlObj[1] );
|
G::header( "location: " . "/sys" . SYS_SYS . $backUrlObj[1] );
|
||||||
die;
|
die();
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
@@ -87,4 +84,4 @@ if(!$sw_file_exists){
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//G::streamFile ( $realPath, true);
|
//G::streamFile ( $realPath, true);
|
||||||
?>
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
/*
|
/*
|
||||||
* Created on 13-02-2008
|
* Created on 13-02-2008
|
||||||
@@ -32,12 +31,12 @@
|
|||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -50,12 +49,10 @@
|
|||||||
$info = pathinfo( $oAppDocument->getAppDocFilename() );
|
$info = pathinfo( $oAppDocument->getAppDocFilename() );
|
||||||
if (! isset( $_GET['ext'] )) {
|
if (! isset( $_GET['ext'] )) {
|
||||||
$ext = $info['extension'];
|
$ext = $info['extension'];
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
if ($_GET['ext'] != '') {
|
if ($_GET['ext'] != '') {
|
||||||
$ext = $_GET['ext'];
|
$ext = $_GET['ext'];
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$ext = $info['extension'];
|
$ext = $info['extension'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -63,4 +60,3 @@
|
|||||||
$realPath = PATH_DOCUMENT . $_SESSION['APPLICATION'] . '/outdocs/' . $info['basename'] . '.' . $ext;
|
$realPath = PATH_DOCUMENT . $_SESSION['APPLICATION'] . '/outdocs/' . $info['basename'] . '.' . $ext;
|
||||||
G::streamFile( $realPath, true );
|
G::streamFile( $realPath, true );
|
||||||
|
|
||||||
?>
|
|
||||||
@@ -20,29 +20,26 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Permissions */
|
/* Permissions */
|
||||||
switch ($RBAC->userCanAccess('PM_CASES'))
|
switch ($RBAC->userCanAccess( 'PM_CASES' )) {
|
||||||
{
|
|
||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( (int)$_SESSION['INDEX'] < 1 )
|
if ((int) $_SESSION['INDEX'] < 1) {
|
||||||
{
|
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
||||||
die;
|
die();
|
||||||
}
|
}
|
||||||
global $_DBArray;
|
global $_DBArray;
|
||||||
if (! isset( $_DBArray )) {
|
if (! isset( $_DBArray )) {
|
||||||
@@ -53,7 +50,6 @@
|
|||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
G::LoadClass( 'derivation' );
|
G::LoadClass( 'derivation' );
|
||||||
|
|
||||||
|
|
||||||
/* GET , POST & $_SESSION Vars */
|
/* GET , POST & $_SESSION Vars */
|
||||||
if (isset( $_GET['POSITION'] )) {
|
if (isset( $_GET['POSITION'] )) {
|
||||||
$_SESSION['STEP_POSITION'] = (int) $_GET['POSITION'];
|
$_SESSION['STEP_POSITION'] = (int) $_GET['POSITION'];
|
||||||
@@ -73,7 +69,7 @@
|
|||||||
/* Prepare page before to show */
|
/* Prepare page before to show */
|
||||||
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
||||||
$oTemplatePower->prepare();
|
$oTemplatePower->prepare();
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
$oHeadPublisher->addScriptCode( '
|
$oHeadPublisher->addScriptCode( '
|
||||||
var Cse = {};
|
var Cse = {};
|
||||||
@@ -102,18 +98,19 @@
|
|||||||
|
|
||||||
#trigger debug routines...
|
#trigger debug routines...
|
||||||
|
|
||||||
|
|
||||||
if (isset( $oProcessFieds['PRO_DEBUG'] ) && $oProcessFieds['PRO_DEBUG']) { #here we must verify if is a debugg session
|
if (isset( $oProcessFieds['PRO_DEBUG'] ) && $oProcessFieds['PRO_DEBUG']) { #here we must verify if is a debugg session
|
||||||
$_SESSION['TRIGGER_DEBUG']['ISSET'] = 1;
|
$_SESSION['TRIGGER_DEBUG']['ISSET'] = 1;
|
||||||
$_SESSION['PMDEBUGGER'] = true;
|
$_SESSION['PMDEBUGGER'] = true;
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$_SESSION['TRIGGER_DEBUG']['ISSET'] = 0;
|
$_SESSION['TRIGGER_DEBUG']['ISSET'] = 0;
|
||||||
$_SESSION['PMDEBUGGER'] = false;
|
$_SESSION['PMDEBUGGER'] = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
//cleaning debug variables
|
//cleaning debug variables
|
||||||
if (! isset( $_GET['breakpoint'] )) {
|
if (! isset( $_GET['breakpoint'] )) {
|
||||||
if( isset($_SESSION['TRIGGER_DEBUG']['info']) ) unset($_SESSION['TRIGGER_DEBUG']['info']);
|
if (isset( $_SESSION['TRIGGER_DEBUG']['info'] ))
|
||||||
|
unset( $_SESSION['TRIGGER_DEBUG']['info'] );
|
||||||
|
|
||||||
if (! isset( $_SESSION['_NO_EXECUTE_TRIGGERS_'] )) {
|
if (! isset( $_SESSION['_NO_EXECUTE_TRIGGERS_'] )) {
|
||||||
$_SESSION['TRIGGER_DEBUG']['ERRORS'] = Array ();
|
$_SESSION['TRIGGER_DEBUG']['ERRORS'] = Array ();
|
||||||
@@ -137,8 +134,7 @@
|
|||||||
$Fields['DEL_INDEX'] = $_SESSION['INDEX'];
|
$Fields['DEL_INDEX'] = $_SESSION['INDEX'];
|
||||||
$Fields['TAS_UID'] = $_SESSION['TASK'];
|
$Fields['TAS_UID'] = $_SESSION['TASK'];
|
||||||
//Execute before triggers - End
|
//Execute before triggers - End
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
unset( $_SESSION['_NO_EXECUTE_TRIGGERS_'] );
|
unset( $_SESSION['_NO_EXECUTE_TRIGGERS_'] );
|
||||||
$Fields['DEL_INDEX'] = $_SESSION['INDEX'];
|
$Fields['DEL_INDEX'] = $_SESSION['INDEX'];
|
||||||
$Fields['TAS_UID'] = $_SESSION['TASK'];
|
$Fields['TAS_UID'] = $_SESSION['TASK'];
|
||||||
@@ -161,22 +157,25 @@
|
|||||||
}
|
}
|
||||||
#end trigger debug session.......
|
#end trigger debug session.......
|
||||||
|
|
||||||
|
|
||||||
//$oCase->thisIsTheCurrentUser($_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['USER_LOGGED'], 'REDIRECT', 'cases_List');
|
//$oCase->thisIsTheCurrentUser($_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['USER_LOGGED'], 'REDIRECT', 'cases_List');
|
||||||
|
|
||||||
|
|
||||||
//Save data - Start
|
//Save data - Start
|
||||||
$oCase->updateCase( $_SESSION['APPLICATION'], $Fields );
|
$oCase->updateCase( $_SESSION['APPLICATION'], $Fields );
|
||||||
//Save data - End
|
//Save data - End
|
||||||
|
|
||||||
|
|
||||||
//Obtain previous and next step - Start
|
//Obtain previous and next step - Start
|
||||||
try {
|
try {
|
||||||
$oCase = new Cases();
|
$oCase = new Cases();
|
||||||
$aNextStep = $oCase->getNextStep( $_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['STEP_POSITION'] );
|
$aNextStep = $oCase->getNextStep( $_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['STEP_POSITION'] );
|
||||||
$aPreviousStep = $oCase->getPreviousStep( $_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['STEP_POSITION'] );
|
$aPreviousStep = $oCase->getPreviousStep( $_SESSION['PROCESS'], $_SESSION['APPLICATION'], $_SESSION['INDEX'], $_SESSION['STEP_POSITION'] );
|
||||||
}
|
} catch (Exception $e) {
|
||||||
catch ( Exception $e ) {
|
|
||||||
}
|
}
|
||||||
//Obtain previous and next step - End
|
//Obtain previous and next step - End
|
||||||
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
//Add content content step - Start
|
//Add content content step - Start
|
||||||
$oApp = ApplicationPeer::retrieveByPK( $_SESSION['APPLICATION'] );
|
$oApp = ApplicationPeer::retrieveByPK( $_SESSION['APPLICATION'] );
|
||||||
@@ -191,16 +190,14 @@
|
|||||||
$noShowTitle = $oProcessFieds['PRO_SHOW_MESSAGE'];
|
$noShowTitle = $oProcessFieds['PRO_SHOW_MESSAGE'];
|
||||||
}
|
}
|
||||||
|
|
||||||
switch ($_GET['TYPE'])
|
switch ($_GET['TYPE']) {
|
||||||
{
|
|
||||||
case 'DYNAFORM':
|
case 'DYNAFORM':
|
||||||
if ($noShowTitle == 0) {
|
if ($noShowTitle == 0) {
|
||||||
$G_PUBLISH->AddContent( 'smarty', 'cases/cases_title', '', '', $array );
|
$G_PUBLISH->AddContent( 'smarty', 'cases/cases_title', '', '', $array );
|
||||||
}
|
}
|
||||||
if (! $aPreviousStep) {
|
if (! $aPreviousStep) {
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP'] = $aPreviousStep['PAGE'];
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP'] = $aPreviousStep['PAGE'];
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = G::loadTranslation( "ID_PREVIOUS_STEP" );
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = G::loadTranslation( "ID_PREVIOUS_STEP" );
|
||||||
}
|
}
|
||||||
@@ -220,8 +217,10 @@
|
|||||||
$oStep = new Step();
|
$oStep = new Step();
|
||||||
$oStep = $oStep->loadByProcessTaskPosition( $_SESSION['PROCESS'], $_SESSION['TASK'], $_GET['POSITION'] );
|
$oStep = $oStep->loadByProcessTaskPosition( $_SESSION['PROCESS'], $_SESSION['TASK'], $_GET['POSITION'] );
|
||||||
|
|
||||||
/** Added By erik 16-05-08
|
/**
|
||||||
* Description: this was added for the additional database connections */
|
* Added By erik 16-05-08
|
||||||
|
* Description: this was added for the additional database connections
|
||||||
|
*/
|
||||||
G::LoadClass( 'dbConnections' );
|
G::LoadClass( 'dbConnections' );
|
||||||
$oDbConnections = new dbConnections( $_SESSION['PROCESS'] );
|
$oDbConnections = new dbConnections( $_SESSION['PROCESS'] );
|
||||||
$oDbConnections->loadAdditionalConnections();
|
$oDbConnections->loadAdditionalConnections();
|
||||||
@@ -239,8 +238,7 @@
|
|||||||
if (! $aPreviousStep) {
|
if (! $aPreviousStep) {
|
||||||
$Fields['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
$Fields['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
||||||
$Fields['PREVIOUS_STEP_LABEL'] = '';
|
$Fields['PREVIOUS_STEP_LABEL'] = '';
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$Fields['__DYNAFORM_OPTIONS']['PREVIOUS_STEP'] = $aPreviousStep['PAGE'];
|
$Fields['__DYNAFORM_OPTIONS']['PREVIOUS_STEP'] = $aPreviousStep['PAGE'];
|
||||||
$Fields['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = G::loadTranslation( "ID_PREVIOUS_STEP" );
|
$Fields['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = G::loadTranslation( "ID_PREVIOUS_STEP" );
|
||||||
|
|
||||||
@@ -249,8 +247,7 @@
|
|||||||
}
|
}
|
||||||
$Fields['NEXT_STEP'] = $aNextStep['PAGE'];
|
$Fields['NEXT_STEP'] = $aNextStep['PAGE'];
|
||||||
$Fields['NEXT_STEP_LABEL'] = G::loadTranslation( "ID_NEXT_STEP" );
|
$Fields['NEXT_STEP_LABEL'] = G::loadTranslation( "ID_NEXT_STEP" );
|
||||||
switch ($_GET['ACTION'])
|
switch ($_GET['ACTION']) {
|
||||||
{
|
|
||||||
case 'ATTACH':
|
case 'ATTACH':
|
||||||
switch ($Fields['INP_DOC_FORM_NEEDED']) {
|
switch ($Fields['INP_DOC_FORM_NEEDED']) {
|
||||||
case 'REAL':
|
case 'REAL':
|
||||||
@@ -271,10 +268,13 @@
|
|||||||
//START: If there is a Break Step registered from Plugin Similar as a Trigger debug
|
//START: If there is a Break Step registered from Plugin Similar as a Trigger debug
|
||||||
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
||||||
if ($oPluginRegistry->existsTrigger( PM_UPLOAD_DOCUMENT_BEFORE )) { //If a Plugin has registered a Break Page Evaluator
|
if ($oPluginRegistry->existsTrigger( PM_UPLOAD_DOCUMENT_BEFORE )) { //If a Plugin has registered a Break Page Evaluator
|
||||||
$oPluginRegistry->executeTriggers ( PM_UPLOAD_DOCUMENT_BEFORE , array('USR_UID'=>$_SESSION['USER_LOGGED']) );
|
$oPluginRegistry->executeTriggers( PM_UPLOAD_DOCUMENT_BEFORE, array ('USR_UID' => $_SESSION['USER_LOGGED']
|
||||||
|
) );
|
||||||
}
|
}
|
||||||
//END: If there is a Break Step registered from Plugin
|
//END: If there is a Break Step registered from Plugin
|
||||||
$G_PUBLISH->AddContent('propeltable', 'cases/paged-table-inputDocuments', 'cases/cases_InputdocsList', $oCase->getInputDocumentsCriteria($_SESSION['APPLICATION'], $_SESSION['INDEX'], $_GET['UID']), array_merge(array('DOC_UID'=>$_GET['UID']),$Fields));//$aFields
|
$G_PUBLISH->AddContent( 'propeltable', 'cases/paged-table-inputDocuments', 'cases/cases_InputdocsList', $oCase->getInputDocumentsCriteria( $_SESSION['APPLICATION'], $_SESSION['INDEX'], $_GET['UID'] ), array_merge( array ('DOC_UID' => $_GET['UID']
|
||||||
|
), $Fields ) ); //$aFields
|
||||||
|
|
||||||
|
|
||||||
//call plugin
|
//call plugin
|
||||||
//if ( $oPluginRegistry->existsTrigger ( PM_CASE_DOCUMENT_LIST ) ) {
|
//if ( $oPluginRegistry->existsTrigger ( PM_CASE_DOCUMENT_LIST ) ) {
|
||||||
@@ -286,9 +286,11 @@
|
|||||||
//else
|
//else
|
||||||
// $G_PUBLISH->AddContent('propeltable', 'cases/paged-table-inputDocuments', 'cases/cases_InputdocsList', $oCase->getInputDocumentsCriteria($_SESSION['APPLICATION'], $_SESSION['INDEX'], $_GET['UID']), array_merge(array('DOC_UID'=>$_GET['UID']),$Fields));//$aFields
|
// $G_PUBLISH->AddContent('propeltable', 'cases/paged-table-inputDocuments', 'cases/cases_InputdocsList', $oCase->getInputDocumentsCriteria($_SESSION['APPLICATION'], $_SESSION['INDEX'], $_GET['UID']), array_merge(array('DOC_UID'=>$_GET['UID']),$Fields));//$aFields
|
||||||
|
|
||||||
|
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
$titleDocument = "<h3>" . $Fields['INP_DOC_TITLE'] . "<br><small>" . G::LoadTranslation( 'ID_INPUT_DOCUMENT' ) . "</small></h3>";
|
$titleDocument = "<h3>" . $Fields['INP_DOC_TITLE'] . "<br><small>" . G::LoadTranslation( 'ID_INPUT_DOCUMENT' ) . "</small></h3>";
|
||||||
if($Fields['INP_DOC_DESCRIPTION']) $titleDocument.= " ".str_replace("\n","",str_replace("'","\'",nl2br(htmlentities(utf8_decode($Fields['INP_DOC_DESCRIPTION'])))))."";
|
if ($Fields['INP_DOC_DESCRIPTION'])
|
||||||
|
$titleDocument .= " " . str_replace( "\n", "", str_replace( "'", "\'", nl2br( htmlentities( utf8_decode( $Fields['INP_DOC_DESCRIPTION'] ) ) ) ) ) . "";
|
||||||
|
|
||||||
$oHeadPublisher->addScriptCode( "documentName='{$titleDocument}';" );
|
$oHeadPublisher->addScriptCode( "documentName='{$titleDocument}';" );
|
||||||
break;
|
break;
|
||||||
@@ -302,8 +304,7 @@
|
|||||||
$oUser = new Users();
|
$oUser = new Users();
|
||||||
$aUser = $oUser->load( $oAppDocument->Fields['USR_UID'] );
|
$aUser = $oUser->load( $oAppDocument->Fields['USR_UID'] );
|
||||||
$Fields['CREATOR'] = $aUser['USR_FIRSTNAME'] . ' ' . $aUser['USR_LASTNAME'];
|
$Fields['CREATOR'] = $aUser['USR_FIRSTNAME'] . ' ' . $aUser['USR_LASTNAME'];
|
||||||
switch ($Fields['INP_DOC_FORM_NEEDED'])
|
switch ($Fields['INP_DOC_FORM_NEEDED']) {
|
||||||
{
|
|
||||||
case 'REAL':
|
case 'REAL':
|
||||||
$sXmlForm = 'cases/cases_ViewInputDocument2';
|
$sXmlForm = 'cases/cases_ViewInputDocument2';
|
||||||
break;
|
break;
|
||||||
@@ -324,25 +325,25 @@
|
|||||||
case 'OUTPUT_DOCUMENT':
|
case 'OUTPUT_DOCUMENT':
|
||||||
//$G_PUBLISH->AddContent('smarty', 'cases/cases_title', '', '', $array);
|
//$G_PUBLISH->AddContent('smarty', 'cases/cases_title', '', '', $array);
|
||||||
|
|
||||||
|
|
||||||
require_once 'classes/model/OutputDocument.php';
|
require_once 'classes/model/OutputDocument.php';
|
||||||
$oOutputDocument = new OutputDocument();
|
$oOutputDocument = new OutputDocument();
|
||||||
$aOD = $oOutputDocument->load( $_GET['UID'] );
|
$aOD = $oOutputDocument->load( $_GET['UID'] );
|
||||||
if (! $aPreviousStep) {
|
if (! $aPreviousStep) {
|
||||||
$aOD['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
$aOD['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$aOD['__DYNAFORM_OPTIONS']['PREVIOUS_STEP'] = $aPreviousStep['PAGE'];
|
$aOD['__DYNAFORM_OPTIONS']['PREVIOUS_STEP'] = $aPreviousStep['PAGE'];
|
||||||
$aOD['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = G::loadTranslation( "ID_PREVIOUS_STEP" );
|
$aOD['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = G::loadTranslation( "ID_PREVIOUS_STEP" );
|
||||||
}
|
}
|
||||||
$aOD['__DYNAFORM_OPTIONS']['NEXT_STEP'] = $aNextStep['PAGE'];
|
$aOD['__DYNAFORM_OPTIONS']['NEXT_STEP'] = $aNextStep['PAGE'];
|
||||||
$aOD['__DYNAFORM_OPTIONS']['NEXT_STEP_LABEL'] = G::loadTranslation( "ID_NEXT_STEP" );
|
$aOD['__DYNAFORM_OPTIONS']['NEXT_STEP_LABEL'] = G::loadTranslation( "ID_NEXT_STEP" );
|
||||||
switch ($_GET['ACTION'])
|
switch ($_GET['ACTION']) {
|
||||||
{
|
|
||||||
case 'GENERATE':
|
case 'GENERATE':
|
||||||
//START: If there is a Break Step registered from Plugin Similar as a Trigger debug
|
//START: If there is a Break Step registered from Plugin Similar as a Trigger debug
|
||||||
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
||||||
if ($oPluginRegistry->existsTrigger( PM_UPLOAD_DOCUMENT_BEFORE )) { //If a Plugin has registered a Break Page Evaluator
|
if ($oPluginRegistry->existsTrigger( PM_UPLOAD_DOCUMENT_BEFORE )) { //If a Plugin has registered a Break Page Evaluator
|
||||||
$oPluginRegistry->executeTriggers ( PM_UPLOAD_DOCUMENT_BEFORE , array('USR_UID'=>$_SESSION['USER_LOGGED']) );
|
$oPluginRegistry->executeTriggers( PM_UPLOAD_DOCUMENT_BEFORE, array ('USR_UID' => $_SESSION['USER_LOGGED']
|
||||||
|
) );
|
||||||
}
|
}
|
||||||
//END: If there is a Break Step registered from Plugin
|
//END: If there is a Break Step registered from Plugin
|
||||||
|
|
||||||
@@ -360,6 +361,7 @@
|
|||||||
|
|
||||||
//Get last Document Version and apply versioning if is enabled
|
//Get last Document Version and apply versioning if is enabled
|
||||||
|
|
||||||
|
|
||||||
$oAppDocument = new AppDocument();
|
$oAppDocument = new AppDocument();
|
||||||
$lastDocVersion = $oAppDocument->getLastDocVersion( $_GET['UID'], $_SESSION['APPLICATION'] );
|
$lastDocVersion = $oAppDocument->getLastDocVersion( $_GET['UID'], $_SESSION['APPLICATION'] );
|
||||||
|
|
||||||
@@ -367,6 +369,7 @@
|
|||||||
// $lastDocVersion++;
|
// $lastDocVersion++;
|
||||||
//}
|
//}
|
||||||
|
|
||||||
|
|
||||||
$oCriteria = new Criteria( 'workflow' );
|
$oCriteria = new Criteria( 'workflow' );
|
||||||
$oCriteria->add( AppDocumentPeer::APP_UID, $_SESSION['APPLICATION'] );
|
$oCriteria->add( AppDocumentPeer::APP_UID, $_SESSION['APPLICATION'] );
|
||||||
//$oCriteria->add(AppDocumentPeer::DEL_INDEX, $_SESSION['INDEX']);
|
//$oCriteria->add(AppDocumentPeer::DEL_INDEX, $_SESSION['INDEX']);
|
||||||
@@ -379,49 +382,24 @@
|
|||||||
if (($aOD['OUT_DOC_VERSIONING']) && ($lastDocVersion != 0)) { //Create new Version of current output
|
if (($aOD['OUT_DOC_VERSIONING']) && ($lastDocVersion != 0)) { //Create new Version of current output
|
||||||
$lastDocVersion ++;
|
$lastDocVersion ++;
|
||||||
if ($aRow = $oDataset->getRow()) {
|
if ($aRow = $oDataset->getRow()) {
|
||||||
$aFields = array('APP_DOC_UID' => $aRow['APP_DOC_UID'],
|
$aFields = array ('APP_DOC_UID' => $aRow['APP_DOC_UID'],'APP_UID' => $_SESSION['APPLICATION'],'DEL_INDEX' => $_SESSION['INDEX'],'DOC_UID' => $_GET['UID'],'DOC_VERSION' => $lastDocVersion + 1,'USR_UID' => $_SESSION['USER_LOGGED'],'APP_DOC_TYPE' => 'OUTPUT','APP_DOC_CREATE_DATE' => date( 'Y-m-d H:i:s' ),'APP_DOC_FILENAME' => $sFilename,'FOLDER_UID' => $folderId,'APP_DOC_TAGS' => $fileTags
|
||||||
'APP_UID' => $_SESSION['APPLICATION'],
|
);
|
||||||
'DEL_INDEX' => $_SESSION['INDEX'],
|
|
||||||
'DOC_UID' => $_GET['UID'],
|
|
||||||
'DOC_VERSION' => $lastDocVersion+1,
|
|
||||||
'USR_UID' => $_SESSION['USER_LOGGED'],
|
|
||||||
'APP_DOC_TYPE' => 'OUTPUT',
|
|
||||||
'APP_DOC_CREATE_DATE' => date('Y-m-d H:i:s'),
|
|
||||||
'APP_DOC_FILENAME' => $sFilename,
|
|
||||||
'FOLDER_UID' => $folderId,
|
|
||||||
'APP_DOC_TAGS' => $fileTags);
|
|
||||||
$oAppDocument = new AppDocument();
|
$oAppDocument = new AppDocument();
|
||||||
$oAppDocument->create( $aFields );
|
$oAppDocument->create( $aFields );
|
||||||
$sDocUID = $aRow['APP_DOC_UID'];
|
$sDocUID = $aRow['APP_DOC_UID'];
|
||||||
}
|
}
|
||||||
} else { //No versioning so Update a current Output or Create new if no exist
|
} else { //No versioning so Update a current Output or Create new if no exist
|
||||||
if ($aRow = $oDataset->getRow()) { //Update
|
if ($aRow = $oDataset->getRow()) { //Update
|
||||||
$aFields = array('APP_DOC_UID' => $aRow['APP_DOC_UID'],
|
$aFields = array ('APP_DOC_UID' => $aRow['APP_DOC_UID'],'APP_UID' => $_SESSION['APPLICATION'],'DEL_INDEX' => $_SESSION['INDEX'],'DOC_UID' => $_GET['UID'],'DOC_VERSION' => $lastDocVersion,'USR_UID' => $_SESSION['USER_LOGGED'],'APP_DOC_TYPE' => 'OUTPUT','APP_DOC_CREATE_DATE' => date( 'Y-m-d H:i:s' ),'APP_DOC_FILENAME' => $sFilename,'FOLDER_UID' => $folderId,'APP_DOC_TAGS' => $fileTags
|
||||||
'APP_UID' => $_SESSION['APPLICATION'],
|
);
|
||||||
'DEL_INDEX' => $_SESSION['INDEX'],
|
|
||||||
'DOC_UID' => $_GET['UID'],
|
|
||||||
'DOC_VERSION' => $lastDocVersion,
|
|
||||||
'USR_UID' => $_SESSION['USER_LOGGED'],
|
|
||||||
'APP_DOC_TYPE' => 'OUTPUT',
|
|
||||||
'APP_DOC_CREATE_DATE' => date('Y-m-d H:i:s'),
|
|
||||||
'APP_DOC_FILENAME' => $sFilename,
|
|
||||||
'FOLDER_UID' => $folderId,
|
|
||||||
'APP_DOC_TAGS' => $fileTags);
|
|
||||||
$oAppDocument = new AppDocument();
|
$oAppDocument = new AppDocument();
|
||||||
$oAppDocument->update( $aFields );
|
$oAppDocument->update( $aFields );
|
||||||
$sDocUID = $aRow['APP_DOC_UID'];
|
$sDocUID = $aRow['APP_DOC_UID'];
|
||||||
} else { //create
|
} else { //create
|
||||||
if($lastDocVersion==0) $lastDocVersion++;
|
if ($lastDocVersion == 0)
|
||||||
$aFields = array('APP_UID' => $_SESSION['APPLICATION'],
|
$lastDocVersion ++;
|
||||||
'DEL_INDEX' => $_SESSION['INDEX'],
|
$aFields = array ('APP_UID' => $_SESSION['APPLICATION'],'DEL_INDEX' => $_SESSION['INDEX'],'DOC_UID' => $_GET['UID'],'DOC_VERSION' => $lastDocVersion,'USR_UID' => $_SESSION['USER_LOGGED'],'APP_DOC_TYPE' => 'OUTPUT','APP_DOC_CREATE_DATE' => date( 'Y-m-d H:i:s' ),'APP_DOC_FILENAME' => $sFilename,'FOLDER_UID' => $folderId,'APP_DOC_TAGS' => $fileTags
|
||||||
'DOC_UID' => $_GET['UID'],
|
);
|
||||||
'DOC_VERSION' => $lastDocVersion,
|
|
||||||
'USR_UID' => $_SESSION['USER_LOGGED'],
|
|
||||||
'APP_DOC_TYPE' => 'OUTPUT',
|
|
||||||
'APP_DOC_CREATE_DATE' => date('Y-m-d H:i:s'),
|
|
||||||
'APP_DOC_FILENAME' => $sFilename,
|
|
||||||
'FOLDER_UID' => $folderId,
|
|
||||||
'APP_DOC_TAGS' => $fileTags);
|
|
||||||
$oAppDocument = new AppDocument();
|
$oAppDocument = new AppDocument();
|
||||||
$aFields['APP_DOC_UID'] = $sDocUID = $oAppDocument->create( $aFields );
|
$aFields['APP_DOC_UID'] = $sDocUID = $oAppDocument->create( $aFields );
|
||||||
|
|
||||||
@@ -431,6 +409,7 @@
|
|||||||
//$sFilename = ereg_replace('[^A-Za-z0-9_]', '_', G::replaceDataField($aOD['OUT_DOC_FILENAME'], $Fields['APP_DATA']));
|
//$sFilename = ereg_replace('[^A-Za-z0-9_]', '_', G::replaceDataField($aOD['OUT_DOC_FILENAME'], $Fields['APP_DATA']));
|
||||||
//if ( $sFilename == '' ) $sFilename='_';
|
//if ( $sFilename == '' ) $sFilename='_';
|
||||||
|
|
||||||
|
|
||||||
$sFilename = $aFields['APP_DOC_UID'] . "_" . $lastDocVersion;
|
$sFilename = $aFields['APP_DOC_UID'] . "_" . $lastDocVersion;
|
||||||
|
|
||||||
$pathOutput = PATH_DOCUMENT . $_SESSION['APPLICATION'] . PATH_SEP . 'outdocs' . PATH_SEP;
|
$pathOutput = PATH_DOCUMENT . $_SESSION['APPLICATION'] . PATH_SEP . 'outdocs' . PATH_SEP;
|
||||||
@@ -440,6 +419,7 @@
|
|||||||
|
|
||||||
$aProperties = array (); //maui
|
$aProperties = array (); //maui
|
||||||
|
|
||||||
|
|
||||||
if (! isset( $aOD['OUT_DOC_MEDIA'] ))
|
if (! isset( $aOD['OUT_DOC_MEDIA'] ))
|
||||||
$aOD['OUT_DOC_MEDIA'] = 'Letter';
|
$aOD['OUT_DOC_MEDIA'] = 'Letter';
|
||||||
if (! isset( $aOD['OUT_DOC_LEFT_MARGIN'] ))
|
if (! isset( $aOD['OUT_DOC_LEFT_MARGIN'] ))
|
||||||
@@ -452,12 +432,13 @@
|
|||||||
$aOD['OUT_DOC_BOTTOM_MARGIN'] = '15';
|
$aOD['OUT_DOC_BOTTOM_MARGIN'] = '15';
|
||||||
|
|
||||||
$aProperties['media'] = $aOD['OUT_DOC_MEDIA'];
|
$aProperties['media'] = $aOD['OUT_DOC_MEDIA'];
|
||||||
$aProperties['margins']=array('left' => $aOD['OUT_DOC_LEFT_MARGIN'], 'right' => $aOD['OUT_DOC_RIGHT_MARGIN'], 'top' => $aOD['OUT_DOC_TOP_MARGIN'], 'bottom' => $aOD['OUT_DOC_BOTTOM_MARGIN']);
|
$aProperties['margins'] = array ('left' => $aOD['OUT_DOC_LEFT_MARGIN'],'right' => $aOD['OUT_DOC_RIGHT_MARGIN'],'top' => $aOD['OUT_DOC_TOP_MARGIN'],'bottom' => $aOD['OUT_DOC_BOTTOM_MARGIN']
|
||||||
|
);
|
||||||
if ($aOD['OUT_DOC_PDF_SECURITY_ENABLED'] == '1') {
|
if ($aOD['OUT_DOC_PDF_SECURITY_ENABLED'] == '1') {
|
||||||
$aProperties['pdfSecurity']=array('openPassword'=>$aOD['OUT_DOC_PDF_SECURITY_OPEN_PASSWORD'],'ownerPassword'=>$aOD['OUT_DOC_PDF_SECURITY_OWNER_PASSWORD'],'permissions'=>$aOD['OUT_DOC_PDF_SECURITY_PERMISSIONS']);
|
$aProperties['pdfSecurity'] = array ('openPassword' => $aOD['OUT_DOC_PDF_SECURITY_OPEN_PASSWORD'],'ownerPassword' => $aOD['OUT_DOC_PDF_SECURITY_OWNER_PASSWORD'],'permissions' => $aOD['OUT_DOC_PDF_SECURITY_PERMISSIONS']
|
||||||
|
);
|
||||||
}
|
}
|
||||||
$oOutputDocument->generate( $_GET['UID'], $Fields['APP_DATA'], $pathOutput,
|
$oOutputDocument->generate( $_GET['UID'], $Fields['APP_DATA'], $pathOutput, $sFilename, $aOD['OUT_DOC_TEMPLATE'], (boolean) $aOD['OUT_DOC_LANDSCAPE'], $aOD['OUT_DOC_GENERATE'], $aProperties );
|
||||||
$sFilename, $aOD['OUT_DOC_TEMPLATE'], (boolean)$aOD['OUT_DOC_LANDSCAPE'], $aOD['OUT_DOC_GENERATE'],$aProperties );
|
|
||||||
//$sFilename, $aOD['OUT_DOC_TEMPLATE'], (boolean)$aOD['OUT_DOC_LANDSCAPE'], $aOD['OUT_DOC_GENERATE'] );
|
//$sFilename, $aOD['OUT_DOC_TEMPLATE'], (boolean)$aOD['OUT_DOC_LANDSCAPE'], $aOD['OUT_DOC_GENERATE'] );
|
||||||
break;
|
break;
|
||||||
case 'JRXML':
|
case 'JRXML':
|
||||||
@@ -498,6 +479,7 @@
|
|||||||
$xmlData .= "</dynaform>\n";
|
$xmlData .= "</dynaform>\n";
|
||||||
//$iSize = file_put_contents ( $javaOutput . 'addressBook.xml' , $xmlData );
|
//$iSize = file_put_contents ( $javaOutput . 'addressBook.xml' , $xmlData );
|
||||||
|
|
||||||
|
|
||||||
G::LoadClass( 'javaBridgePM' );
|
G::LoadClass( 'javaBridgePM' );
|
||||||
$JBPM = new JavaBridgePM();
|
$JBPM = new JavaBridgePM();
|
||||||
$JBPM->checkJavaExtension();
|
$JBPM->checkJavaExtension();
|
||||||
@@ -518,37 +500,30 @@
|
|||||||
throw (new Exception( 'invalid output document' ));
|
throw (new Exception( 'invalid output document' ));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//Execute after triggers - Start
|
//Execute after triggers - Start
|
||||||
$Fields['APP_DATA'] = $oCase->ExecuteTriggers( $_SESSION['TASK'], 'OUTPUT_DOCUMENT', $_GET['UID'], 'AFTER', $Fields['APP_DATA'] );
|
$Fields['APP_DATA'] = $oCase->ExecuteTriggers( $_SESSION['TASK'], 'OUTPUT_DOCUMENT', $_GET['UID'], 'AFTER', $Fields['APP_DATA'] );
|
||||||
$Fields['DEL_INDEX'] = $_SESSION['INDEX'];
|
$Fields['DEL_INDEX'] = $_SESSION['INDEX'];
|
||||||
$Fields['TAS_UID'] = $_SESSION['TASK'];
|
$Fields['TAS_UID'] = $_SESSION['TASK'];
|
||||||
//Execute after triggers - End
|
//Execute after triggers - End
|
||||||
|
|
||||||
|
|
||||||
//Save data - Start
|
//Save data - Start
|
||||||
$oCase->updateCase( $_SESSION['APPLICATION'], $Fields );
|
$oCase->updateCase( $_SESSION['APPLICATION'], $Fields );
|
||||||
//Save data - End
|
//Save data - End
|
||||||
|
|
||||||
|
|
||||||
//Plugin Hook PM_UPLOAD_DOCUMENT for upload document
|
//Plugin Hook PM_UPLOAD_DOCUMENT for upload document
|
||||||
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
||||||
if ($oPluginRegistry->existsTrigger( PM_UPLOAD_DOCUMENT ) && class_exists( 'uploadDocumentData' )) {
|
if ($oPluginRegistry->existsTrigger( PM_UPLOAD_DOCUMENT ) && class_exists( 'uploadDocumentData' )) {
|
||||||
$triggerDetail = $oPluginRegistry->getTriggerInfo( PM_UPLOAD_DOCUMENT );
|
$triggerDetail = $oPluginRegistry->getTriggerInfo( PM_UPLOAD_DOCUMENT );
|
||||||
|
|
||||||
|
|
||||||
$sPathName = PATH_DOCUMENT . $_SESSION['APPLICATION'] . PATH_SEP;
|
$sPathName = PATH_DOCUMENT . $_SESSION['APPLICATION'] . PATH_SEP;
|
||||||
|
|
||||||
$oData['APP_UID'] = $_SESSION['APPLICATION'];
|
$oData['APP_UID'] = $_SESSION['APPLICATION'];
|
||||||
$oData['ATTACHMENT_FOLDER'] = true;
|
$oData['ATTACHMENT_FOLDER'] = true;
|
||||||
switch ($aOD['OUT_DOC_GENERATE']) {
|
switch ($aOD['OUT_DOC_GENERATE']) {
|
||||||
case "BOTH":
|
case "BOTH":
|
||||||
$documentData = new uploadDocumentData (
|
$documentData = new uploadDocumentData( $_SESSION['APPLICATION'], $_SESSION['USER_LOGGED'], $pathOutput . $sFilename . '.pdf', $sFilenameOriginal . '.pdf', $sDocUID, $oAppDocument->getDocVersion() );
|
||||||
$_SESSION['APPLICATION'],
|
|
||||||
$_SESSION['USER_LOGGED'],
|
|
||||||
$pathOutput . $sFilename . '.pdf',
|
|
||||||
$sFilenameOriginal. '.pdf',
|
|
||||||
$sDocUID,
|
|
||||||
$oAppDocument->getDocVersion()
|
|
||||||
);
|
|
||||||
|
|
||||||
$documentData->sFileType = "PDF";
|
$documentData->sFileType = "PDF";
|
||||||
$documentData->bUseOutputFolder = true;
|
$documentData->bUseOutputFolder = true;
|
||||||
@@ -560,16 +535,7 @@
|
|||||||
unlink( $pathOutput . $sFilename . '.pdf' );
|
unlink( $pathOutput . $sFilename . '.pdf' );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$documentData = new uploadDocumentData( $_SESSION['APPLICATION'], $_SESSION['USER_LOGGED'], $pathOutput . $sFilename . '.doc', $sFilenameOriginal . '.doc', $sDocUID, $oAppDocument->getDocVersion() );
|
||||||
|
|
||||||
$documentData = new uploadDocumentData (
|
|
||||||
$_SESSION['APPLICATION'],
|
|
||||||
$_SESSION['USER_LOGGED'],
|
|
||||||
$pathOutput . $sFilename . '.doc',
|
|
||||||
$sFilenameOriginal. '.doc',
|
|
||||||
$sDocUID,
|
|
||||||
$oAppDocument->getDocVersion()
|
|
||||||
);
|
|
||||||
|
|
||||||
$documentData->sFileType = "DOC";
|
$documentData->sFileType = "DOC";
|
||||||
$documentData->bUseOutputFolder = true;
|
$documentData->bUseOutputFolder = true;
|
||||||
@@ -580,15 +546,7 @@
|
|||||||
|
|
||||||
break;
|
break;
|
||||||
case "PDF":
|
case "PDF":
|
||||||
$documentData = new uploadDocumentData (
|
$documentData = new uploadDocumentData( $_SESSION['APPLICATION'], $_SESSION['USER_LOGGED'], $pathOutput . $sFilename . '.pdf', $sFilenameOriginal . '.pdf', $sDocUID, $oAppDocument->getDocVersion() );
|
||||||
$_SESSION['APPLICATION'],
|
|
||||||
$_SESSION['USER_LOGGED'],
|
|
||||||
$pathOutput . $sFilename . '.pdf',
|
|
||||||
$sFilenameOriginal. '.pdf',
|
|
||||||
$sDocUID,
|
|
||||||
$oAppDocument->getDocVersion()
|
|
||||||
);
|
|
||||||
|
|
||||||
|
|
||||||
$documentData->sFileType = "PDF";
|
$documentData->sFileType = "PDF";
|
||||||
$documentData->bUseOutputFolder = true;
|
$documentData->bUseOutputFolder = true;
|
||||||
@@ -598,14 +556,7 @@
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case "DOC":
|
case "DOC":
|
||||||
$documentData = new uploadDocumentData (
|
$documentData = new uploadDocumentData( $_SESSION['APPLICATION'], $_SESSION['USER_LOGGED'], $pathOutput . $sFilename . '.doc', $sFilenameOriginal . '.doc', $sDocUID, $oAppDocument->getDocVersion() );
|
||||||
$_SESSION['APPLICATION'],
|
|
||||||
$_SESSION['USER_LOGGED'],
|
|
||||||
$pathOutput . $sFilename . '.doc',
|
|
||||||
$sFilenameOriginal. '.doc',
|
|
||||||
$sDocUID,
|
|
||||||
$oAppDocument->getDocVersion()
|
|
||||||
);
|
|
||||||
|
|
||||||
$documentData->sFileType = "DOC";
|
$documentData->sFileType = "DOC";
|
||||||
$documentData->bUseOutputFolder = true;
|
$documentData->bUseOutputFolder = true;
|
||||||
@@ -620,7 +571,7 @@
|
|||||||
|
|
||||||
$outputNextStep = 'cases_Step?TYPE=OUTPUT_DOCUMENT&UID=' . $_GET['UID'] . '&POSITION=' . $_SESSION['STEP_POSITION'] . '&ACTION=VIEW&DOC=' . $sDocUID;
|
$outputNextStep = 'cases_Step?TYPE=OUTPUT_DOCUMENT&UID=' . $_GET['UID'] . '&POSITION=' . $_SESSION['STEP_POSITION'] . '&ACTION=VIEW&DOC=' . $sDocUID;
|
||||||
G::header( 'location: ' . $outputNextStep );
|
G::header( 'location: ' . $outputNextStep );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case 'VIEW':
|
case 'VIEW':
|
||||||
if ($noShowTitle == 0) {
|
if ($noShowTitle == 0) {
|
||||||
@@ -657,7 +608,6 @@
|
|||||||
|
|
||||||
$aFields['FILE2'] = 'cases_ShowOutputDocument?a=' . $aFields['APP_DOC_UID'] . '&v=' . $lastDocVersion . '&ext=pdf&random=' . rand() . '&PHPSESSID=' . @session_id();
|
$aFields['FILE2'] = 'cases_ShowOutputDocument?a=' . $aFields['APP_DOC_UID'] . '&v=' . $lastDocVersion . '&ext=pdf&random=' . rand() . '&PHPSESSID=' . @session_id();
|
||||||
|
|
||||||
|
|
||||||
if (is_array( $listing )) { //If exist in Plugin Document List
|
if (is_array( $listing )) { //If exist in Plugin Document List
|
||||||
foreach ($listing as $folderitem) {
|
foreach ($listing as $folderitem) {
|
||||||
if (($folderitem->filename == $aFields['APP_DOC_UID']) && ($folderitem->type == 'DOC')) {
|
if (($folderitem->filename == $aFields['APP_DOC_UID']) && ($folderitem->type == 'DOC')) {
|
||||||
@@ -682,7 +632,6 @@
|
|||||||
if ($aGields['OUT_DOC_GENERATE'] == 'PDF')
|
if ($aGields['OUT_DOC_GENERATE'] == 'PDF')
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_ViewOutputDocument3', '', G::array_merges( $aOD, $aFields ), '' );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_ViewOutputDocument3', '', G::array_merges( $aOD, $aFields ), '' );
|
||||||
|
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -711,10 +660,7 @@
|
|||||||
$aFields['TAS_TYPE_DAY'] = G::LoadTranslation( 'ID_COUNT_DAYS' );
|
$aFields['TAS_TYPE_DAY'] = G::LoadTranslation( 'ID_COUNT_DAYS' );
|
||||||
$aFields['TAS_CALENDAR'] = G::LoadTranslation( 'ID_CALENDAR' );
|
$aFields['TAS_CALENDAR'] = G::LoadTranslation( 'ID_CALENDAR' );
|
||||||
|
|
||||||
$aFields['TASK'] = $oDerivation->prepareInformation(array(
|
$aFields['TASK'] = $oDerivation->prepareInformation( array ('USER_UID' => $_SESSION['USER_LOGGED'],'APP_UID' => $_SESSION['APPLICATION'],'DEL_INDEX' => $_SESSION['INDEX']
|
||||||
'USER_UID' => $_SESSION['USER_LOGGED'],
|
|
||||||
'APP_UID' => $_SESSION['APPLICATION'],
|
|
||||||
'DEL_INDEX' => $_SESSION['INDEX']
|
|
||||||
) );
|
) );
|
||||||
|
|
||||||
if (empty( $aFields['TASK'] )) {
|
if (empty( $aFields['TASK'] )) {
|
||||||
@@ -725,17 +671,16 @@
|
|||||||
$aFields['PROCESS']['ROU_TYPE'] = $aFields['TASK'][1]['ROU_TYPE'];
|
$aFields['PROCESS']['ROU_TYPE'] = $aFields['TASK'][1]['ROU_TYPE'];
|
||||||
$aFields['PROCESS']['ROU_FINISH_FLAG'] = false;
|
$aFields['PROCESS']['ROU_FINISH_FLAG'] = false;
|
||||||
|
|
||||||
foreach ( $aFields['TASK'] as $sKey => &$aValues)
|
foreach ($aFields['TASK'] as $sKey => &$aValues) {
|
||||||
{
|
|
||||||
$sPriority = ''; //set priority value
|
$sPriority = ''; //set priority value
|
||||||
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_PRIORITY_VARIABLE'] != '') {
|
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_PRIORITY_VARIABLE'] != '') {
|
||||||
//TO DO: review this type of assignment
|
//TO DO: review this type of assignment
|
||||||
if (isset($aData['APP_DATA'][str_replace('@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_PRIORITY_VARIABLE'])]))
|
if (isset( $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_PRIORITY_VARIABLE'] )] )) {
|
||||||
{
|
|
||||||
$sPriority = $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_PRIORITY_VARIABLE'] )];
|
$sPriority = $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_PRIORITY_VARIABLE'] )];
|
||||||
}
|
}
|
||||||
} //set priority value
|
} //set priority value
|
||||||
|
|
||||||
|
|
||||||
$sTask = $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_UID'];
|
$sTask = $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_UID'];
|
||||||
|
|
||||||
//TAS_UID has a hidden field to store the TAS_UID
|
//TAS_UID has a hidden field to store the TAS_UID
|
||||||
@@ -760,15 +705,13 @@
|
|||||||
break;
|
break;
|
||||||
case 'MANUAL':
|
case 'MANUAL':
|
||||||
$Aux = array ();
|
$Aux = array ();
|
||||||
foreach ($aValues['NEXT_TASK']['USER_ASSIGNED'] as $aUser)
|
foreach ($aValues['NEXT_TASK']['USER_ASSIGNED'] as $aUser) {
|
||||||
{
|
|
||||||
$Aux[$aUser['USR_UID']] = $aUser['USR_FULLNAME'];
|
$Aux[$aUser['USR_UID']] = $aUser['USR_FULLNAME'];
|
||||||
}
|
}
|
||||||
asort( $Aux );
|
asort( $Aux );
|
||||||
$sAux = '<select name="form[TASKS][' . $sKey . '][USR_UID]" id="form[TASKS][' . $sKey . '][USR_UID]">';
|
$sAux = '<select name="form[TASKS][' . $sKey . '][USR_UID]" id="form[TASKS][' . $sKey . '][USR_UID]">';
|
||||||
$sAux .= '<option value="" enabled>' . G::LoadTranslation( 'ID_SELECT' ) . '</option>';
|
$sAux .= '<option value="" enabled>' . G::LoadTranslation( 'ID_SELECT' ) . '</option>';
|
||||||
foreach ($Aux as $key => $value)
|
foreach ($Aux as $key => $value) {
|
||||||
{
|
|
||||||
$sAux .= '<option value="' . $key . '">' . $value . '</option>';
|
$sAux .= '<option value="' . $key . '">' . $value . '</option>';
|
||||||
}
|
}
|
||||||
$sAux .= '</select>';
|
$sAux .= '</select>';
|
||||||
@@ -783,79 +726,63 @@
|
|||||||
//set TAS_MI_INSTANCE_VARIABLE value
|
//set TAS_MI_INSTANCE_VARIABLE value
|
||||||
$sMIinstanceVar = '';
|
$sMIinstanceVar = '';
|
||||||
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'] != '') {
|
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'] != '') {
|
||||||
if (isset($aData['APP_DATA'][str_replace('@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'])]))
|
if (isset( $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'] )] )) {
|
||||||
{
|
|
||||||
$sMIinstanceVar = $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'] )];
|
$sMIinstanceVar = $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'] )];
|
||||||
if ($sMIinstanceVar > $cntInstanceUsers)
|
if ($sMIinstanceVar > $cntInstanceUsers)
|
||||||
throw (new Exception( "Total Multiple Instance Task cannot be greater than number of users in the group." ));
|
throw (new Exception( "Total Multiple Instance Task cannot be greater than number of users in the group." ));
|
||||||
else if ($sMIinstanceVar == 0)
|
else if ($sMIinstanceVar == 0)
|
||||||
throw (new Exception( "Total Multiple Instance Task cannot be zero." ));
|
throw (new Exception( "Total Multiple Instance Task cannot be zero." ));
|
||||||
}
|
} else if (is_int( (int) $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'] )) {
|
||||||
else if(is_int((int)$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE']))
|
|
||||||
{
|
|
||||||
$sMIinstanceVar = $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'];
|
$sMIinstanceVar = $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_INSTANCE_VARIABLE'];
|
||||||
if ($sMIinstanceVar > $cntInstanceUsers)
|
if ($sMIinstanceVar > $cntInstanceUsers)
|
||||||
throw (new Exception( "Total Multiple Instance Task cannot be greater than number of users in the group." ));
|
throw (new Exception( "Total Multiple Instance Task cannot be greater than number of users in the group." ));
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
throw (new Exception( "Total Multiple Instance Task variable doesn't have valid value." ));
|
throw (new Exception( "Total Multiple Instance Task variable doesn't have valid value." ));
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
throw (new Exception( "Total Multiple Instance Task variable doesn't have valid value." ));
|
throw (new Exception( "Total Multiple Instance Task variable doesn't have valid value." ));
|
||||||
////set TAS_MI_INSTANCE_VARIABLE value
|
////set TAS_MI_INSTANCE_VARIABLE value
|
||||||
|
|
||||||
|
|
||||||
//set TAS_MI_COMPLETE_VARIABLE value
|
//set TAS_MI_COMPLETE_VARIABLE value
|
||||||
$sMIcompleteVar = '';
|
$sMIcompleteVar = '';
|
||||||
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'] != '') {
|
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'] != '') {
|
||||||
if (isset($aData['APP_DATA'][str_replace('@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'])]))
|
if (isset( $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'] )] )) {
|
||||||
{
|
|
||||||
$sMIcompleteVar = $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'] )];
|
$sMIcompleteVar = $aData['APP_DATA'][str_replace( '@@', '', $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'] )];
|
||||||
//
|
//
|
||||||
if ($sMIcompleteVar > $sMIinstanceVar)
|
if ($sMIcompleteVar > $sMIinstanceVar)
|
||||||
throw (new Exception( "Total Multiple Instance Task to complete cannot be greater than Total number of Instances." ));
|
throw (new Exception( "Total Multiple Instance Task to complete cannot be greater than Total number of Instances." ));
|
||||||
}
|
} else if (is_int( (int) $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'] )) {
|
||||||
else if(is_int((int)$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE']))
|
|
||||||
{
|
|
||||||
$sMIcompleteVar = $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'];
|
$sMIcompleteVar = $aFields['TASK'][$sKey]['NEXT_TASK']['TAS_MI_COMPLETE_VARIABLE'];
|
||||||
if ($sMIcompleteVar > $sMIinstanceVar)
|
if ($sMIcompleteVar > $sMIinstanceVar)
|
||||||
throw (new Exception( "Total Multiple Instance Task to complete cannot be greater than Total number of Instances." ));
|
throw (new Exception( "Total Multiple Instance Task to complete cannot be greater than Total number of Instances." ));
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
throw (new Exception( "Total Multiple Instance Task to complete variable doesn't have valid value." ));
|
throw (new Exception( "Total Multiple Instance Task to complete variable doesn't have valid value." ));
|
||||||
|
|
||||||
}
|
} else
|
||||||
else
|
|
||||||
throw (new Exception( "Total Multiple Instance Task to complete variable doesn't have valid value." ));
|
throw (new Exception( "Total Multiple Instance Task to complete variable doesn't have valid value." ));
|
||||||
//set TAS_MI_COMPLETE_VARIABLE value
|
//set TAS_MI_COMPLETE_VARIABLE value
|
||||||
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_NEXT'] = $aValues['NEXT_TASK']['TAS_ASSIGN_TYPE'];
|
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_NEXT'] = $aValues['NEXT_TASK']['TAS_ASSIGN_TYPE'];
|
||||||
|
|
||||||
//If the Users in the group is equal to the MI Instance variable then Show all the users without Dropdown
|
//If the Users in the group is equal to the MI Instance variable then Show all the users without Dropdown
|
||||||
if($sMIinstanceVar == $cntInstanceUsers)
|
if ($sMIinstanceVar == $cntInstanceUsers) {
|
||||||
{
|
foreach ($aValues['NEXT_TASK']['USER_ASSIGNED'] as $key => $aUser) {
|
||||||
foreach ($aValues['NEXT_TASK']['USER_ASSIGNED'] as $key=>$aUser)
|
|
||||||
{
|
|
||||||
$hiddenName = "form[TASKS][" . $sKey . "][NEXT_TASK][USER_ASSIGNED][" . $key . "][USR_UID]";
|
$hiddenName = "form[TASKS][" . $sKey . "][NEXT_TASK][USER_ASSIGNED][" . $key . "][USR_UID]";
|
||||||
$aFields['TASK'][$sKey]['NEXT_TASK']['USER_ASSIGNED'][$key]['USR_UID'] = $aUser['USR_FULLNAME'];
|
$aFields['TASK'][$sKey]['NEXT_TASK']['USER_ASSIGNED'][$key]['USR_UID'] = $aUser['USR_FULLNAME'];
|
||||||
$aFields['TASK'][$sKey]['NEXT_TASK']['USER_ASSIGNED'][$key]['USR_HIDDEN_FIELD'] = '<input type="hidden" name="' . $hiddenName . '" id="' . $hiddenName . '" value="' . $aUser['USR_UID'] . '">';
|
$aFields['TASK'][$sKey]['NEXT_TASK']['USER_ASSIGNED'][$key]['USR_HIDDEN_FIELD'] = '<input type="hidden" name="' . $hiddenName . '" id="' . $hiddenName . '" value="' . $aUser['USR_UID'] . '">';
|
||||||
}
|
}
|
||||||
}
|
} //If the Users in the group is not equal to the MI Instance variable then Show Only count users in dropdown
|
||||||
//If the Users in the group is not equal to the MI Instance variable then Show Only count users in dropdown
|
else {
|
||||||
else
|
|
||||||
{
|
|
||||||
$Aux = array ();
|
$Aux = array ();
|
||||||
foreach ($aValues['NEXT_TASK']['USER_ASSIGNED'] as $aUser)
|
foreach ($aValues['NEXT_TASK']['USER_ASSIGNED'] as $aUser) {
|
||||||
{
|
|
||||||
$Aux[$aUser['USR_UID']] = $aUser['USR_FULLNAME'];
|
$Aux[$aUser['USR_UID']] = $aUser['USR_FULLNAME'];
|
||||||
}
|
}
|
||||||
asort( $Aux );
|
asort( $Aux );
|
||||||
$aAux = '<option value="" enabled>' . G::LoadTranslation( 'ID_SELECT' ) . '</option>';
|
$aAux = '<option value="" enabled>' . G::LoadTranslation( 'ID_SELECT' ) . '</option>';
|
||||||
foreach ($Aux as $akey => $value)
|
foreach ($Aux as $akey => $value) {
|
||||||
{
|
|
||||||
$aAux .= '<option value="' . $akey . '">' . $value . '</option>';
|
$aAux .= '<option value="' . $akey . '">' . $value . '</option>';
|
||||||
}
|
}
|
||||||
|
|
||||||
for($key=0; $key < $sMIinstanceVar; $key++)
|
for ($key = 0; $key < $sMIinstanceVar; $key ++) {
|
||||||
{
|
|
||||||
$hiddenName = "form[TASKS][" . $sKey . "][NEXT_TASK][USER_ASSIGNED][" . $key . "][USR_UID]";
|
$hiddenName = "form[TASKS][" . $sKey . "][NEXT_TASK][USER_ASSIGNED][" . $key . "][USR_UID]";
|
||||||
$sAux = "<select name=$hiddenName id=$hiddenName";
|
$sAux = "<select name=$hiddenName id=$hiddenName";
|
||||||
$sAux .= $aAux;
|
$sAux .= $aAux;
|
||||||
@@ -881,8 +808,7 @@
|
|||||||
{
|
{
|
||||||
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TRANSFER_FLY'] = strtolower( $aValues['NEXT_TASK']['TAS_TRANSFER_FLY'] );
|
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TRANSFER_FLY'] = strtolower( $aValues['NEXT_TASK']['TAS_TRANSFER_FLY'] );
|
||||||
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TRANSFER_HIDDEN_FLY'] = "<input type=hidden name='" . $hiddenName . "[NEXT_TASK][TAS_TRANSFER_HIDDEN_FLY]' id='" . $hiddenName . "[NEXT_TASK][TAS_TRANSFER_HIDDEN_FLY]' value=" . $aValues['NEXT_TASK']['TAS_TRANSFER_FLY'] . ">";
|
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TRANSFER_HIDDEN_FLY'] = "<input type=hidden name='" . $hiddenName . "[NEXT_TASK][TAS_TRANSFER_HIDDEN_FLY]' id='" . $hiddenName . "[NEXT_TASK][TAS_TRANSFER_HIDDEN_FLY]' value=" . $aValues['NEXT_TASK']['TAS_TRANSFER_FLY'] . ">";
|
||||||
if($aValues['NEXT_TASK']['TAS_TRANSFER_FLY'] == 'true')
|
if ($aValues['NEXT_TASK']['TAS_TRANSFER_FLY'] == 'true') {
|
||||||
{
|
|
||||||
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_DURATION'] = '<input type="text" size="5" name="' . $hiddenName . '[NEXT_TASK][TAS_DURATION]" id="' . $hiddenName . '[NEXT_TASK][TAS_DURATION]" value="' . $aValues['NEXT_TASK']['TAS_DURATION'] . '">';
|
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_DURATION'] = '<input type="text" size="5" name="' . $hiddenName . '[NEXT_TASK][TAS_DURATION]" id="' . $hiddenName . '[NEXT_TASK][TAS_DURATION]" value="' . $aValues['NEXT_TASK']['TAS_DURATION'] . '">';
|
||||||
$hoursSelected = $daysSelected = '';
|
$hoursSelected = $daysSelected = '';
|
||||||
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TIMEUNIT'] == 'HOURS')
|
if ($aFields['TASK'][$sKey]['NEXT_TASK']['TAS_TIMEUNIT'] == 'HOURS')
|
||||||
@@ -917,10 +843,8 @@
|
|||||||
$aCalendar['CALENDAR_NAME'] = 'DEFAULT';
|
$aCalendar['CALENDAR_NAME'] = 'DEFAULT';
|
||||||
$sAux = '<select name=' . $hiddenName . '[NEXT_TASK][TAS_CALENDAR] id= ' . $hiddenName . '[NEXT_TASK][TAS_CALENDAR] ';
|
$sAux = '<select name=' . $hiddenName . '[NEXT_TASK][TAS_CALENDAR] id= ' . $hiddenName . '[NEXT_TASK][TAS_CALENDAR] ';
|
||||||
$sAux .= "<option value='none'>-None-</option> ";
|
$sAux .= "<option value='none'>-None-</option> ";
|
||||||
foreach($availableCalendar as $aCalendar)
|
foreach ($availableCalendar as $aCalendar) {
|
||||||
{
|
if (is_array( $aCalendar )) {
|
||||||
if(is_array($aCalendar))
|
|
||||||
{
|
|
||||||
$sAux .= "<option value='" . $aCalendar['CALENDAR_UID'] . "'>" . $aCalendar['CALENDAR_NAME'] . "</option> ";
|
$sAux .= "<option value='" . $aCalendar['CALENDAR_UID'] . "'>" . $aCalendar['CALENDAR_NAME'] . "</option> ";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -929,7 +853,6 @@
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_ASSIGN_TYPE'] = '<input type="hidden" name="' . $hiddenName . '[TAS_ASSIGN_TYPE]" id="' . $hiddenName . '[TAS_ASSIGN_TYPE]" value="' . $aValues['NEXT_TASK']['TAS_ASSIGN_TYPE'] . '">';
|
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_ASSIGN_TYPE'] = '<input type="hidden" name="' . $hiddenName . '[TAS_ASSIGN_TYPE]" id="' . $hiddenName . '[TAS_ASSIGN_TYPE]" value="' . $aValues['NEXT_TASK']['TAS_ASSIGN_TYPE'] . '">';
|
||||||
if (isset( $aValues['NEXT_TASK']['TAS_DEF_PROC_CODE'] )) {
|
if (isset( $aValues['NEXT_TASK']['TAS_DEF_PROC_CODE'] )) {
|
||||||
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_DEF_PROC_CODE'] = '<input type="hidden" name="' . $hiddenName . '[TAS_DEF_PROC_CODE]" id="' . $hiddenName . '[TAS_DEF_PROC_CODE]" value="' . $aValues['NEXT_TASK']['TAS_DEF_PROC_CODE'] . '">';
|
$aFields['TASK'][$sKey]['NEXT_TASK']['TAS_DEF_PROC_CODE'] = '<input type="hidden" name="' . $hiddenName . '[TAS_DEF_PROC_CODE]" id="' . $hiddenName . '[TAS_DEF_PROC_CODE]" value="' . $aValues['NEXT_TASK']['TAS_DEF_PROC_CODE'] . '">';
|
||||||
@@ -944,6 +867,7 @@
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* New Feature: Derivation Screen can be personalized
|
* New Feature: Derivation Screen can be personalized
|
||||||
|
*
|
||||||
* @author Erik Amaru Ortiz <erik@colosa.com>
|
* @author Erik Amaru Ortiz <erik@colosa.com>
|
||||||
*/
|
*/
|
||||||
$tplFile = 'cases/cases_ScreenDerivation';
|
$tplFile = 'cases/cases_ScreenDerivation';
|
||||||
@@ -954,8 +878,7 @@
|
|||||||
if (! empty( $tasDerivationScreenTpl )) { //erik: first, verify if the task has a personalized template (for derivation screen)
|
if (! empty( $tasDerivationScreenTpl )) { //erik: first, verify if the task has a personalized template (for derivation screen)
|
||||||
$tplFile = $tasDerivationScreenTpl;
|
$tplFile = $tasDerivationScreenTpl;
|
||||||
$tplFile = PATH_DATA_MAILTEMPLATES . $aFields['PROCESS']['PRO_UID'] . PATH_SEP . $tplFile;
|
$tplFile = PATH_DATA_MAILTEMPLATES . $aFields['PROCESS']['PRO_UID'] . PATH_SEP . $tplFile;
|
||||||
}
|
} else { //erik: verify if the process has a personalized template (for derivation screen)
|
||||||
else { //erik: verify if the process has a personalized template (for derivation screen)
|
|
||||||
if (! empty( $aFields['PROCESS']['PRO_DERIVATION_SCREEN_TPL'] )) {
|
if (! empty( $aFields['PROCESS']['PRO_DERIVATION_SCREEN_TPL'] )) {
|
||||||
$tplFile = $aFields['PROCESS']['PRO_DERIVATION_SCREEN_TPL'];
|
$tplFile = $aFields['PROCESS']['PRO_DERIVATION_SCREEN_TPL'];
|
||||||
$tplFile = PATH_DATA_MAILTEMPLATES . $aFields['PROCESS']['PRO_UID'] . PATH_SEP . $tplFile;
|
$tplFile = PATH_DATA_MAILTEMPLATES . $aFields['PROCESS']['PRO_UID'] . PATH_SEP . $tplFile;
|
||||||
@@ -1000,16 +923,17 @@
|
|||||||
if (class_exists( $sNamespace . "plugin" )) {
|
if (class_exists( $sNamespace . "plugin" )) {
|
||||||
if (! $aPreviousStep) {
|
if (! $aPreviousStep) {
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP'] = $aPreviousStep['PAGE'];
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP'] = $aPreviousStep['PAGE'];
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = G::loadTranslation( "ID_PREVIOUS_STEP" );
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = G::loadTranslation( "ID_PREVIOUS_STEP" );
|
||||||
}
|
}
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_STEP'] = $aNextStep['PAGE'];
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_STEP'] = $aNextStep['PAGE'];
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_STEP_LABEL'] = G::loadTranslation( "ID_NEXT_STEP" );
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_STEP_LABEL'] = G::loadTranslation( "ID_NEXT_STEP" );
|
||||||
|
|
||||||
/** Added By erik date: 16-05-08
|
/**
|
||||||
* Description: this was added for the additional database connections */
|
* Added By erik date: 16-05-08
|
||||||
|
* Description: this was added for the additional database connections
|
||||||
|
*/
|
||||||
G::LoadClass( 'dbConnections' );
|
G::LoadClass( 'dbConnections' );
|
||||||
$oDbConnections = new dbConnections( $_SESSION['PROCESS'] );
|
$oDbConnections = new dbConnections( $_SESSION['PROCESS'] );
|
||||||
$oDbConnections->loadAdditionalConnections();
|
$oDbConnections->loadAdditionalConnections();
|
||||||
@@ -1020,23 +944,22 @@
|
|||||||
}" );
|
}" );
|
||||||
|
|
||||||
$G_PUBLISH->AddContent( 'content', $stepFilename );
|
$G_PUBLISH->AddContent( 'content', $stepFilename );
|
||||||
}
|
} else {
|
||||||
else {
|
$aMessage['MESSAGE'] = G::loadTranslation( 'ID_EXTERNAL_STEP_MISSING', SYS_LANG, array ("plugin" => $sNamespace
|
||||||
$aMessage['MESSAGE'] = G::loadTranslation('ID_EXTERNAL_STEP_MISSING', SYS_LANG, array("plugin"=>$sNamespace) );
|
) );
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//Add content content step - End
|
//Add content content step - End
|
||||||
}
|
} catch (Exception $e) {
|
||||||
catch ( Exception $e ) {
|
|
||||||
G::SendTemporalMessage( G::LoadTranslation( 'ID_PROCESS_DEF_PROBLEM' ), 'error', 'string', 3, 100 );
|
G::SendTemporalMessage( G::LoadTranslation( 'ID_PROCESS_DEF_PROBLEM' ), 'error', 'string', 3, 100 );
|
||||||
$aMessage = array ();
|
$aMessage = array ();
|
||||||
$aMessage['MESSAGE'] = $e->getMessage();
|
$aMessage['MESSAGE'] = $e->getMessage();
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
||||||
G::RenderPage( 'publish', 'blank' );
|
G::RenderPage( 'publish', 'blank' );
|
||||||
die;
|
die();
|
||||||
}
|
}
|
||||||
|
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
@@ -1061,4 +984,3 @@
|
|||||||
}' );
|
}' );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
// die("first");
|
// die("first");
|
||||||
/* Permissions */
|
/* Permissions */
|
||||||
@@ -28,19 +27,19 @@ switch ($RBAC->userCanAccess('PM_SUPERVISOR')) {
|
|||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((int) $_SESSION['INDEX'] < 1) {
|
if ((int) $_SESSION['INDEX'] < 1) {
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
||||||
die;
|
die();
|
||||||
}
|
}
|
||||||
/* Includes */
|
/* Includes */
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
@@ -49,17 +48,17 @@ G::LoadClass('derivation');
|
|||||||
/* GET , POST & $_SESSION Vars */
|
/* GET , POST & $_SESSION Vars */
|
||||||
//$_SESSION['STEP_POSITION'] = (int)$_GET['POSITION'];
|
//$_SESSION['STEP_POSITION'] = (int)$_GET['POSITION'];
|
||||||
|
|
||||||
|
|
||||||
/* Menues */
|
/* Menues */
|
||||||
$G_MAIN_MENU = 'processmaker';
|
$G_MAIN_MENU = 'processmaker';
|
||||||
$G_SUB_MENU = 'cases';
|
$G_SUB_MENU = 'cases';
|
||||||
$G_ID_MENU_SELECTED = 'CASES';
|
$G_ID_MENU_SELECTED = 'CASES';
|
||||||
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
||||||
|
|
||||||
|
|
||||||
/* Prepare page before to show */
|
/* Prepare page before to show */
|
||||||
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
||||||
$oTemplatePower->prepare();
|
$oTemplatePower->prepare();
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$oCase = new Cases();
|
$oCase = new Cases();
|
||||||
$Fields = $oCase->loadCase( $_SESSION['APPLICATION'] );
|
$Fields = $oCase->loadCase( $_SESSION['APPLICATION'] );
|
||||||
|
|
||||||
@@ -108,20 +107,19 @@ if (isset($_GET['type'])) {
|
|||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['PREVIOUS_STEP_LABEL'] = '';
|
||||||
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_STEP_LABEL'] = '';
|
$Fields['APP_DATA']['__DYNAFORM_OPTIONS']['NEXT_STEP_LABEL'] = '';
|
||||||
|
|
||||||
|
/**
|
||||||
/** Added By erik
|
* Added By erik
|
||||||
* date: 16-05-08
|
* date: 16-05-08
|
||||||
* Description: this was added for the additional database connections */
|
* Description: this was added for the additional database connections
|
||||||
|
*/
|
||||||
G::LoadClass( 'dbConnections' );
|
G::LoadClass( 'dbConnections' );
|
||||||
$oDbConnections = new dbConnections( $_SESSION['PROCESS'] );
|
$oDbConnections = new dbConnections( $_SESSION['PROCESS'] );
|
||||||
$oDbConnections->loadAdditionalConnections();
|
$oDbConnections->loadAdditionalConnections();
|
||||||
|
|
||||||
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH = new Publisher;
|
|
||||||
if ($_GET['DYN_UID'] != '') {
|
if ($_GET['DYN_UID'] != '') {
|
||||||
$_SESSION['CURRENT_DYN_UID'] = $_GET['DYN_UID'];
|
$_SESSION['CURRENT_DYN_UID'] = $_GET['DYN_UID'];
|
||||||
$G_PUBLISH->AddContent('dynaform', 'xmlform', $_SESSION['PROCESS'] . '/' . $_GET['DYN_UID'], '',
|
$G_PUBLISH->AddContent( 'dynaform', 'xmlform', $_SESSION['PROCESS'] . '/' . $_GET['DYN_UID'], '', $Fields['APP_DATA'], 'cases_SaveDataSupervisor?UID=' . $_GET['DYN_UID'] );
|
||||||
$Fields['APP_DATA'], 'cases_SaveDataSupervisor?UID='.$_GET['DYN_UID']);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
G::RenderPage( 'publish', 'blank' );
|
G::RenderPage( 'publish', 'blank' );
|
||||||
@@ -150,3 +148,4 @@ function setSelect()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
//die("second");
|
//die("second");
|
||||||
/* Permissions */
|
/* Permissions */
|
||||||
@@ -28,19 +27,19 @@ switch ($RBAC->userCanAccess('PM_SUPERVISOR')) {
|
|||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((int) $_SESSION['INDEX'] < 1) {
|
if ((int) $_SESSION['INDEX'] < 1) {
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
||||||
die;
|
die();
|
||||||
}
|
}
|
||||||
/* Includes */
|
/* Includes */
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
@@ -49,17 +48,17 @@ G::LoadClass('derivation');
|
|||||||
/* GET , POST & $_SESSION Vars */
|
/* GET , POST & $_SESSION Vars */
|
||||||
//$_SESSION['STEP_POSITION'] = (int)$_GET['POSITION'];
|
//$_SESSION['STEP_POSITION'] = (int)$_GET['POSITION'];
|
||||||
|
|
||||||
|
|
||||||
/* Menues */
|
/* Menues */
|
||||||
$G_MAIN_MENU = 'processmaker';
|
$G_MAIN_MENU = 'processmaker';
|
||||||
$G_SUB_MENU = 'cases';
|
$G_SUB_MENU = 'cases';
|
||||||
$G_ID_MENU_SELECTED = 'CASES';
|
$G_ID_MENU_SELECTED = 'CASES';
|
||||||
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
||||||
|
|
||||||
|
|
||||||
/* Prepare page before to show */
|
/* Prepare page before to show */
|
||||||
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
||||||
$oTemplatePower->prepare();
|
$oTemplatePower->prepare();
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
// Check if these code needs to be removed since the interface ar now moving to ExtJS
|
// Check if these code needs to be removed since the interface ar now moving to ExtJS
|
||||||
$oHeadPublisher->addScriptCode( '
|
$oHeadPublisher->addScriptCode( '
|
||||||
@@ -88,7 +87,7 @@ $_SESSION['STEP_POSITION'] = (int)$_GET['position'];
|
|||||||
$oCase = new Cases();
|
$oCase = new Cases();
|
||||||
$Fields = $oCase->loadCase( $_SESSION['APPLICATION'] );
|
$Fields = $oCase->loadCase( $_SESSION['APPLICATION'] );
|
||||||
|
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
|
|
||||||
if (! isset( $_GET['ex'] )) {
|
if (! isset( $_GET['ex'] )) {
|
||||||
$_GET['ex'] = 0;
|
$_GET['ex'] = 0;
|
||||||
@@ -97,8 +96,7 @@ if (!isset($_GET['ex'])) {
|
|||||||
if (! isset( $_GET['INP_DOC_UID'] )) {
|
if (! isset( $_GET['INP_DOC_UID'] )) {
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
$oCase = new Cases();
|
$oCase = new Cases();
|
||||||
$G_PUBLISH->AddContent('propeltable', 'paged-table', 'cases/cases_InputdocsListToRevise',
|
$G_PUBLISH->AddContent( 'propeltable', 'paged-table', 'cases/cases_InputdocsListToRevise', $oCase->getInputDocumentsCriteriaToRevise( $_SESSION['APPLICATION'] ), '' );
|
||||||
$oCase->getInputDocumentsCriteriaToRevise($_SESSION['APPLICATION']), '');
|
|
||||||
} else {
|
} else {
|
||||||
$oInputDocument = new InputDocument();
|
$oInputDocument = new InputDocument();
|
||||||
$Fields = $oInputDocument->load( $_GET['INP_DOC_UID'] );
|
$Fields = $oInputDocument->load( $_GET['INP_DOC_UID'] );
|
||||||
@@ -122,9 +120,8 @@ if (!isset($_GET['INP_DOC_UID'])) {
|
|||||||
$oHeadPublisher->addScriptCode( 'var documentName=\'Reviewing Input Document<br>' . $docName . '\';' );
|
$oHeadPublisher->addScriptCode( 'var documentName=\'Reviewing Input Document<br>' . $docName . '\';' );
|
||||||
// $G_PUBLISH->AddContent('xmlform', 'xmlform', $sXmlForm, '', $Fields, 'cases_SupervisorSaveDocument?UID=' .
|
// $G_PUBLISH->AddContent('xmlform', 'xmlform', $sXmlForm, '', $Fields, 'cases_SupervisorSaveDocument?UID=' .
|
||||||
//$_GET['INP_DOC_UID'] . '&APP_UID=' . $_GET['APP_UID'] . '&position=' . $_GET['position']);
|
//$_GET['INP_DOC_UID'] . '&APP_UID=' . $_GET['APP_UID'] . '&position=' . $_GET['position']);
|
||||||
$G_PUBLISH->AddContent('propeltable', 'cases/paged-table-inputDocumentsToRevise', 'cases/cases_ToReviseInputdocsList',
|
$G_PUBLISH->AddContent( 'propeltable', 'cases/paged-table-inputDocumentsToRevise', 'cases/cases_ToReviseInputdocsList', $oCase->getInputDocumentsCriteria( $_SESSION['APPLICATION'], $_SESSION['INDEX'], $_GET['INP_DOC_UID'] ), array_merge( array ('DOC_UID' => $_GET['INP_DOC_UID']
|
||||||
$oCase->getInputDocumentsCriteria($_SESSION['APPLICATION'], $_SESSION['INDEX'], $_GET['INP_DOC_UID']),
|
), $Fields ) );
|
||||||
array_merge(array('DOC_UID'=>$_GET['INP_DOC_UID']),$Fields));
|
|
||||||
//$aFields
|
//$aFields
|
||||||
// $G_PUBLISH->AddContent('propeltable', 'cases/paged-table-inputDocuments', 'cases/cases_InputdocsList',
|
// $G_PUBLISH->AddContent('propeltable', 'cases/paged-table-inputDocuments', 'cases/cases_InputdocsList',
|
||||||
//$oCase->getInputDocumentsCriteria($_SESSION['APPLICATION']));//$aFields
|
//$oCase->getInputDocumentsCriteria($_SESSION['APPLICATION']));//$aFields
|
||||||
@@ -153,3 +150,4 @@ function setSelect()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Permissions */
|
/* Permissions */
|
||||||
@@ -28,12 +27,12 @@ switch ($RBAC->userCanAccess('PM_SUPERVISOR')) {
|
|||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -46,11 +45,10 @@ $G_SUB_MENU = 'cases';
|
|||||||
$G_ID_MENU_SELECTED = 'CASES';
|
$G_ID_MENU_SELECTED = 'CASES';
|
||||||
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
||||||
|
|
||||||
|
|
||||||
/* Prepare page before to show */
|
/* Prepare page before to show */
|
||||||
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
||||||
$oTemplatePower->prepare();
|
$oTemplatePower->prepare();
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
// check if the code for the addScriptCode is necessary since the interface is now based in ExtJs
|
// check if the code for the addScriptCode is necessary since the interface is now based in ExtJs
|
||||||
$oHeadPublisher->addScriptCode( '
|
$oHeadPublisher->addScriptCode( '
|
||||||
@@ -69,8 +67,7 @@ leimnud.event.add(window,"load",function(){
|
|||||||
' );
|
' );
|
||||||
$G_PUBLISH->AddContent( 'template', '', '', '', $oTemplatePower );
|
$G_PUBLISH->AddContent( 'template', '', '', '', $oTemplatePower );
|
||||||
$oCase = new Cases();
|
$oCase = new Cases();
|
||||||
$G_PUBLISH->AddContent('propeltable', 'paged-table', 'cases/cases_OutputdocsListToRevise',
|
$G_PUBLISH->AddContent( 'propeltable', 'paged-table', 'cases/cases_OutputdocsListToRevise', $oCase->getOutputDocumentsCriteriaToRevise( $_SESSION['APPLICATION'] ), '' );
|
||||||
$oCase->getOutputDocumentsCriteriaToRevise($_SESSION['APPLICATION']), '');
|
|
||||||
G::RenderPage( 'publish', 'blank' );
|
G::RenderPage( 'publish', 'blank' );
|
||||||
|
|
||||||
if (! isset( $_GET['ex'] )) {
|
if (! isset( $_GET['ex'] )) {
|
||||||
@@ -98,3 +95,4 @@ function setSelect()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@@ -28,15 +27,8 @@
|
|||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
|
|
||||||
$oAppDocument = new AppDocument();
|
$oAppDocument = new AppDocument();
|
||||||
$aFields = array('APP_UID' => $_GET['APP_UID'],
|
$aFields = array ('APP_UID' => $_GET['APP_UID'],'DEL_INDEX' => 100000,'USR_UID' => $_SESSION['USER_LOGGED'],'DOC_UID' => $_GET['UID'],'APP_DOC_TYPE' => $_POST['form']['APP_DOC_TYPE'],'APP_DOC_CREATE_DATE' => date( 'Y-m-d H:i:s' ),'APP_DOC_COMMENT' => isset( $_POST['form']['APP_DOC_COMMENT'] ) ? $_POST['form']['APP_DOC_COMMENT'] : '','APP_DOC_TITLE' => '','APP_DOC_FILENAME' => isset( $_FILES['form']['name']['APP_DOC_FILENAME'] ) ? $_FILES['form']['name']['APP_DOC_FILENAME'] : ''
|
||||||
'DEL_INDEX' => 100000,
|
);
|
||||||
'USR_UID' => $_SESSION['USER_LOGGED'],
|
|
||||||
'DOC_UID' => $_GET['UID'],
|
|
||||||
'APP_DOC_TYPE' => $_POST['form']['APP_DOC_TYPE'],
|
|
||||||
'APP_DOC_CREATE_DATE' => date('Y-m-d H:i:s'),
|
|
||||||
'APP_DOC_COMMENT' => isset($_POST['form']['APP_DOC_COMMENT']) ? $_POST['form']['APP_DOC_COMMENT'] : '',
|
|
||||||
'APP_DOC_TITLE' => '',
|
|
||||||
'APP_DOC_FILENAME' => isset($_FILES['form']['name']['APP_DOC_FILENAME']) ? $_FILES['form']['name']['APP_DOC_FILENAME'] : '');
|
|
||||||
$oAppDocument->create( $aFields );
|
$oAppDocument->create( $aFields );
|
||||||
$sAppDocUid = $oAppDocument->getAppDocUid();
|
$sAppDocUid = $oAppDocument->getAppDocUid();
|
||||||
$info = pathinfo( $oAppDocument->getAppDocFilename() );
|
$info = pathinfo( $oAppDocument->getAppDocFilename() );
|
||||||
@@ -52,13 +44,7 @@
|
|||||||
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
$oPluginRegistry = & PMPluginRegistry::getSingleton();
|
||||||
if ($oPluginRegistry->existsTrigger( PM_UPLOAD_DOCUMENT ) && class_exists( 'uploadDocumentData' )) {
|
if ($oPluginRegistry->existsTrigger( PM_UPLOAD_DOCUMENT ) && class_exists( 'uploadDocumentData' )) {
|
||||||
$oData['APP_UID'] = $_GET['APP_UID'];
|
$oData['APP_UID'] = $_GET['APP_UID'];
|
||||||
$documentData = new uploadDocumentData (
|
$documentData = new uploadDocumentData( $_GET['APP_UID'], $_SESSION['USER_LOGGED'], $sPathName . $sFileName, $aFields['APP_DOC_FILENAME'], $sAppDocUid );
|
||||||
$_GET['APP_UID'],
|
|
||||||
$_SESSION['USER_LOGGED'],
|
|
||||||
$sPathName . $sFileName,
|
|
||||||
$aFields['APP_DOC_FILENAME'],
|
|
||||||
$sAppDocUid
|
|
||||||
);
|
|
||||||
$oPluginRegistry->executeTriggers( PM_UPLOAD_DOCUMENT, $documentData );
|
$oPluginRegistry->executeTriggers( PM_UPLOAD_DOCUMENT, $documentData );
|
||||||
unlink( $sPathName . $sFileName );
|
unlink( $sPathName . $sFileName );
|
||||||
}
|
}
|
||||||
@@ -71,16 +57,16 @@
|
|||||||
$aFields = $oCase->loadCase( $_GET['APP_UID'] );
|
$aFields = $oCase->loadCase( $_GET['APP_UID'] );
|
||||||
$aNextStep = $oCase->getNextSupervisorStep( $aFields['PRO_UID'], $_GET['position'], 'INPUT_DOCUMENT' );
|
$aNextStep = $oCase->getNextSupervisorStep( $aFields['PRO_UID'], $_GET['position'], 'INPUT_DOCUMENT' );
|
||||||
G::header( 'location: ' . 'cases_StepToReviseInputs?type=INPUT_DOCUMENT&INP_DOC_UID=' . $aNextStep['UID'] . '&position=' . $aNextStep['POSITION'] . '&APP_UID=' . $_GET['APP_UID'] . '&DEL_INDEX=' );
|
G::header( 'location: ' . 'cases_StepToReviseInputs?type=INPUT_DOCUMENT&INP_DOC_UID=' . $aNextStep['UID'] . '&position=' . $aNextStep['POSITION'] . '&APP_UID=' . $_GET['APP_UID'] . '&DEL_INDEX=' );
|
||||||
die;
|
die();
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
||||||
die;
|
die();
|
||||||
}
|
}
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
/* Render Error page */
|
/* Render Error page */
|
||||||
$aMessage['MESSAGE'] = $e->getMessage();
|
$aMessage['MESSAGE'] = $e->getMessage();
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
||||||
G::RenderPage( 'publish' );
|
G::RenderPage( 'publish' );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Permissions */
|
/* Permissions */
|
||||||
@@ -28,19 +27,19 @@ switch ($RBAC->userCanAccess('PM_SUPERVISOR')) {
|
|||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((int) $_SESSION['INDEX'] < 1) {
|
if ((int) $_SESSION['INDEX'] < 1) {
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
G::header( 'location: ' . $_SERVER['HTTP_REFERER'] );
|
||||||
die;
|
die();
|
||||||
}
|
}
|
||||||
/* Includes */
|
/* Includes */
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
@@ -49,6 +48,7 @@ G::LoadClass('derivation');
|
|||||||
/* GET , POST & $_SESSION Vars */
|
/* GET , POST & $_SESSION Vars */
|
||||||
//$_SESSION['STEP_POSITION'] = (int)$_GET['POSITION'];
|
//$_SESSION['STEP_POSITION'] = (int)$_GET['POSITION'];
|
||||||
|
|
||||||
|
|
||||||
/* Menues */
|
/* Menues */
|
||||||
$G_MAIN_MENU = 'processmaker';
|
$G_MAIN_MENU = 'processmaker';
|
||||||
$G_SUB_MENU = 'cases';
|
$G_SUB_MENU = 'cases';
|
||||||
@@ -61,7 +61,7 @@ $Fields = $oCase->loadCase($_SESSION['APPLICATION']);
|
|||||||
require_once 'classes/model/AppDocument.php';
|
require_once 'classes/model/AppDocument.php';
|
||||||
require_once 'classes/model/Users.php';
|
require_once 'classes/model/Users.php';
|
||||||
|
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
|
|
||||||
$oAppDocument = new AppDocument();
|
$oAppDocument = new AppDocument();
|
||||||
$oAppDocument->Fields = $oAppDocument->load( $_GET['DOC'] );
|
$oAppDocument->Fields = $oAppDocument->load( $_GET['DOC'] );
|
||||||
@@ -77,6 +77,3 @@ $G_PUBLISH->AddContent('xmlform', 'xmlform', 'cases/cases_ViewInputDocumentToRev
|
|||||||
|
|
||||||
G::RenderPage( 'publish' );
|
G::RenderPage( 'publish' );
|
||||||
|
|
||||||
?>
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Permissions */
|
/* Permissions */
|
||||||
@@ -28,12 +27,12 @@ switch ($RBAC->userCanAccess('PM_SUPERVISOR')) {
|
|||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -46,11 +45,10 @@ $G_SUB_MENU = 'cases';
|
|||||||
$G_ID_MENU_SELECTED = 'CASES';
|
$G_ID_MENU_SELECTED = 'CASES';
|
||||||
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
||||||
|
|
||||||
|
|
||||||
/* Prepare page before to show */
|
/* Prepare page before to show */
|
||||||
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
||||||
$oTemplatePower->prepare();
|
$oTemplatePower->prepare();
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
|
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
$oHeadPublisher->addScriptCode( '
|
$oHeadPublisher->addScriptCode( '
|
||||||
@@ -89,12 +87,13 @@ switch ($aOD ['OUT_DOC_GENERATE']) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_ViewOutputDocumentToRevise', '', G::array_merges( $aOD, $aFields ), '' );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_ViewOutputDocumentToRevise', '', G::array_merges( $aOD, $aFields ), '' );
|
||||||
//
|
//
|
||||||
G::RenderPage( 'publish', 'blank' );
|
G::RenderPage( 'publish', 'blank' );
|
||||||
|
|
||||||
if(!isset($_GET['ex'])) $_GET['ex']=0;
|
if (! isset( $_GET['ex'] ))
|
||||||
|
$_GET['ex'] = 0;
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
@@ -117,3 +116,4 @@ function setSelect()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@@ -29,12 +28,12 @@ try {
|
|||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
@@ -64,12 +63,12 @@ try {
|
|||||||
$G_SUB_MENU = 'cases';
|
$G_SUB_MENU = 'cases';
|
||||||
$G_ID_MENU_SELECTED = 'CASES';
|
$G_ID_MENU_SELECTED = 'CASES';
|
||||||
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REASSIGN';
|
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REASSIGN';
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$aMessage['MESSAGE'] = $sText;
|
$aMessage['MESSAGE'] = $sText;
|
||||||
$aMessage['URL'] = 'cases_ReassignByUser?REASSIGN_USER=' . $_POST['USR_UID'];
|
$aMessage['URL'] = 'cases_ReassignByUser?REASSIGN_USER=' . $_POST['USR_UID'];
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_ReassignShowInfo', '', $aMessage );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'cases/cases_ReassignShowInfo', '', $aMessage );
|
||||||
G::RenderPage( 'publish' );
|
G::RenderPage( 'publish' );
|
||||||
}
|
} catch (Exception $oException) {
|
||||||
catch (Exception $oException) {
|
|
||||||
die( $oException->getMessage() );
|
die( $oException->getMessage() );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,26 +4,26 @@ switch ($RBAC->userCanAccess('PM_SUPERVISOR')) {
|
|||||||
case - 2:
|
case - 2:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
case - 1:
|
case - 1:
|
||||||
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
G::SendTemporalMessage( 'ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels' );
|
||||||
G::header( 'location: ../login/login' );
|
G::header( 'location: ../login/login' );
|
||||||
die;
|
die();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (($RBAC_Response = $RBAC->userCanAccess( "PM_USERS" )) != 1)
|
if (($RBAC_Response = $RBAC->userCanAccess( "PM_USERS" )) != 1)
|
||||||
return $RBAC_Response;
|
return $RBAC_Response;
|
||||||
|
|
||||||
|
|
||||||
$G_MAIN_MENU = 'processmaker';
|
$G_MAIN_MENU = 'processmaker';
|
||||||
$G_SUB_MENU = 'cases';
|
$G_SUB_MENU = 'cases';
|
||||||
$G_ID_MENU_SELECTED = 'CASES';
|
$G_ID_MENU_SELECTED = 'CASES';
|
||||||
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
$G_ID_SUB_MENU_SELECTED = 'CASES_TO_REVISE';
|
||||||
|
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH->AddContent( 'view', 'cases/cases_toRevise' );
|
$G_PUBLISH->AddContent( 'view', 'cases/cases_toRevise' );
|
||||||
$G_PUBLISH->AddContent( 'smarty', 'cases/cases_toReviseIn', '', '', array () );
|
$G_PUBLISH->AddContent( 'smarty', 'cases/cases_toReviseIn', '', '', array () );
|
||||||
|
|
||||||
G::RenderPage( "publish-treeview" );
|
G::RenderPage( "publish-treeview" );
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
require_once 'classes/model/LogCasesSchedulerPeer.php';
|
require_once 'classes/model/LogCasesSchedulerPeer.php';
|
||||||
@@ -49,8 +48,7 @@ $oCriteria->addSelectColumn(LogCasesSchedulerPeer::WS_CREATE_CASE_STATUS);
|
|||||||
$oCriteria->addSelectColumn( LogCasesSchedulerPeer::WS_ROUTE_CASE_STATUS );
|
$oCriteria->addSelectColumn( LogCasesSchedulerPeer::WS_ROUTE_CASE_STATUS );
|
||||||
|
|
||||||
if ($filter != '') {
|
if ($filter != '') {
|
||||||
$c_or = $oCriteria->getNewCriterion(LogCasesSchedulerPeer::WS_CREATE_CASE_STATUS, '%'.$filter.'%', Criteria::LIKE)->addOr(
|
$c_or = $oCriteria->getNewCriterion( LogCasesSchedulerPeer::WS_CREATE_CASE_STATUS, '%' . $filter . '%', Criteria::LIKE )->addOr( $oCriteria->getNewCriterion( LogCasesSchedulerPeer::WS_ROUTE_CASE_STATUS, '%' . $filter . '%', Criteria::LIKE ) );
|
||||||
$oCriteria->getNewCriterion(LogCasesSchedulerPeer::WS_ROUTE_CASE_STATUS,'%'.$filter.'%', Criteria::LIKE));
|
|
||||||
$oCriteria->add( $c_or );
|
$oCriteria->add( $c_or );
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -72,11 +70,10 @@ $oCriteria->addDescendingOrderByColumn(LogCasesSchedulerPeer::EXEC_HOUR);
|
|||||||
$oDataset = LogCasesSchedulerPeer::doSelectRS( $oCriteria );
|
$oDataset = LogCasesSchedulerPeer::doSelectRS( $oCriteria );
|
||||||
$oDataset->setFetchmode( ResultSet::FETCHMODE_ASSOC );
|
$oDataset->setFetchmode( ResultSet::FETCHMODE_ASSOC );
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//$oDataset = LogCasesSchedulerPeer::doSelectRS ( $oCriteria );
|
//$oDataset = LogCasesSchedulerPeer::doSelectRS ( $oCriteria );
|
||||||
//$oDataset->setFetchmode ( ResultSet::FETCHMODE_ASSOC );
|
//$oDataset->setFetchmode ( ResultSet::FETCHMODE_ASSOC );
|
||||||
|
|
||||||
|
|
||||||
$addTables = Array ();
|
$addTables = Array ();
|
||||||
while ($oDataset->next()) {
|
while ($oDataset->next()) {
|
||||||
$addTables[] = $oDataset->getRow();
|
$addTables[] = $oDataset->getRow();
|
||||||
@@ -85,5 +82,5 @@ while( $oDataset->next() ) {
|
|||||||
//$oLogCasesScheduler = new LogCasesScheduler();
|
//$oLogCasesScheduler = new LogCasesScheduler();
|
||||||
//$arrData = $oLogCasesScheduler->getAll();
|
//$arrData = $oLogCasesScheduler->getAll();
|
||||||
|
|
||||||
|
|
||||||
echo '{results: ' . $results . ', rows: ' . G::json_encode( $addTables ) . '}';
|
echo '{results: ' . $results . ', rows: ' . G::json_encode( $addTables ) . '}';
|
||||||
|
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ foreach($aTriggers as $aTrigger) {
|
|||||||
//$t_code = addslashes($t_code);
|
//$t_code = addslashes($t_code);
|
||||||
//$t_code = Only1br($t_code);
|
//$t_code = Only1br($t_code);
|
||||||
|
|
||||||
|
|
||||||
//highlighting the trigger code using the geshi third party library
|
//highlighting the trigger code using the geshi third party library
|
||||||
G::LoadThirdParty( 'geshi', 'geshi' );
|
G::LoadThirdParty( 'geshi', 'geshi' );
|
||||||
$geshi = new GeSHi( $aTrigger['TRIGGERS_VALUES'][$index]['TRI_WEBBOT'], 'php' );
|
$geshi = new GeSHi( $aTrigger['TRIGGERS_VALUES'][$index]['TRI_WEBBOT'], 'php' );
|
||||||
@@ -57,7 +58,6 @@ foreach($DEBUG_ERRORS as $error){
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*echo '{total:5, data:[
|
/*echo '{total:5, data:[
|
||||||
{name:"trigger1", execution_time:"after"},
|
{name:"trigger1", execution_time:"after"},
|
||||||
{name:"trigger2", execution_time:"before"},
|
{name:"trigger2", execution_time:"before"},
|
||||||
@@ -70,3 +70,4 @@ $triggersRet->total = count($triggersList);
|
|||||||
$triggersRet->data = $triggersList;
|
$triggersRet->data = $triggersList;
|
||||||
|
|
||||||
echo G::json_encode( $triggersRet );
|
echo G::json_encode( $triggersRet );
|
||||||
|
|
||||||
|
|||||||
@@ -28,13 +28,14 @@ switch ($request) {
|
|||||||
foreach ($field as $row) {
|
foreach ($field as $row) {
|
||||||
if ($sw) {
|
if ($sw) {
|
||||||
foreach ($row as $key => $value) {
|
foreach ($row as $key => $value) {
|
||||||
$response->headers[] = Array('name' => $key);
|
$response->headers[] = Array ('name' => $key
|
||||||
$response->columns[] = Array('header' => $key, 'width' => 100, 'dataIndex' => $key);
|
);
|
||||||
|
$response->columns[] = Array ('header' => $key,'width' => 100,'dataIndex' => $key
|
||||||
|
);
|
||||||
}
|
}
|
||||||
$sw = false;
|
$sw = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$tmp = Array ();
|
$tmp = Array ();
|
||||||
foreach ($row as $key => $value) {
|
foreach ($row as $key => $value) {
|
||||||
$tmp[] = $value;
|
$tmp[] = $value;
|
||||||
@@ -43,12 +44,18 @@ switch ($request) {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (is_object( $field )) {
|
if (is_object( $field )) {
|
||||||
$response->headers = Array(Array('name' => 'name'), Array('name' => 'value'));
|
$response->headers = Array (Array ('name' => 'name'
|
||||||
$response->columns = Array(Array('header' => 'Property', 'width' => 100, 'dataIndex' => 'name'),
|
),Array ('name' => 'value'
|
||||||
Array('header' => 'Value', 'width' => 100, 'dataIndex' => 'value'));
|
)
|
||||||
|
);
|
||||||
|
$response->columns = Array (Array ('header' => 'Property','width' => 100,'dataIndex' => 'name'
|
||||||
|
),Array ('header' => 'Value','width' => 100,'dataIndex' => 'value'
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
foreach ($field as $key => $value) {
|
foreach ($field as $key => $value) {
|
||||||
$response->rows[] = Array($key, $value);
|
$response->rows[] = Array ($key,$value
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -67,7 +74,6 @@ switch ($request) {
|
|||||||
|
|
||||||
$aVars = array_merge( $aFields['APP_DATA'], $aVars );
|
$aVars = array_merge( $aFields['APP_DATA'], $aVars );
|
||||||
|
|
||||||
|
|
||||||
if (isset( $_POST['filter'] ) && $_POST['filter'] == 'dyn') {
|
if (isset( $_POST['filter'] ) && $_POST['filter'] == 'dyn') {
|
||||||
$sysVars = array_keys( G::getSystemConstants() );
|
$sysVars = array_keys( G::getSystemConstants() );
|
||||||
$varNames = array_keys( $aVars );
|
$varNames = array_keys( $aVars );
|
||||||
|
|||||||
@@ -20,10 +20,8 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
//$newFile = str_replace ( 'index.php', 'cases_List.php' , __FILE__ ) ;
|
//$newFile = str_replace ( 'index.php', 'cases_List.php' , __FILE__ ) ;
|
||||||
$newFile = str_replace( 'index.php', 'main.php', __FILE__ );
|
$newFile = str_replace( 'index.php', 'main.php', __FILE__ );
|
||||||
return $newFile;
|
return $newFile;
|
||||||
|
|
||||||
|
|
||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$RBAC->requirePermissions( 'PM_CASES' );
|
$RBAC->requirePermissions( 'PM_CASES' );
|
||||||
@@ -30,7 +29,7 @@ $G_ID_MENU_SELECTED = 'CASES';
|
|||||||
|
|
||||||
$_POST['qs'] = isset( $_SERVER['QUERY_STRING'] ) && $_SERVER['QUERY_STRING'] != '' ? '?' . $_SERVER['QUERY_STRING'] : '';
|
$_POST['qs'] = isset( $_SERVER['QUERY_STRING'] ) && $_SERVER['QUERY_STRING'] != '' ? '?' . $_SERVER['QUERY_STRING'] : '';
|
||||||
|
|
||||||
$G_PUBLISH = new Publisher;
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH->AddContent( 'view', 'cases/cases_Load' );
|
$G_PUBLISH->AddContent( 'view', 'cases/cases_Load' );
|
||||||
G::RenderPage( 'publish' );
|
G::RenderPage( 'publish' );
|
||||||
|
|
||||||
|
|||||||
@@ -20,21 +20,17 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
G::LoadClass( "configuration" );
|
G::LoadClass( "configuration" );
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$conf = new Configurations();
|
$conf = new Configurations();
|
||||||
|
|
||||||
$oHeadPublisher = &headPublisher::getSingleton();
|
$oHeadPublisher = &headPublisher::getSingleton();
|
||||||
$oHeadPublisher->addExtJsScript( "cases/main", false ); //Adding a javascript file .js
|
$oHeadPublisher->addExtJsScript( "cases/main", false ); //Adding a javascript file .js
|
||||||
$oHeadPublisher->addContent( "cases/main" ); //Adding a html file .html.
|
$oHeadPublisher->addContent( "cases/main" ); //Adding a html file .html.
|
||||||
|
|
||||||
|
|
||||||
$keyMem = "USER_PREFERENCES" . $_SESSION["USER_LOGGED"];
|
$keyMem = "USER_PREFERENCES" . $_SESSION["USER_LOGGED"];
|
||||||
$memcache = &PMmemcached::getSingleton( SYS_SYS );
|
$memcache = &PMmemcached::getSingleton( SYS_SYS );
|
||||||
|
|
||||||
|
|||||||
@@ -20,10 +20,10 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
*
|
||||||
* @author Erik Amaru Ortiz <erik@colosa.com>
|
* @author Erik Amaru Ortiz <erik@colosa.com>
|
||||||
* @date Jan 3th, 2010
|
* @date Jan 3th, 2010
|
||||||
*/
|
*/
|
||||||
@@ -40,18 +40,16 @@
|
|||||||
if (is_null( $_GET['DEL_INDEX'] )) {
|
if (is_null( $_GET['DEL_INDEX'] )) {
|
||||||
throw new Exception( G::LoadTranslation( 'ID_CASE_IS_CURRENTLY_WITH_ANOTHER_USER' ) );
|
throw new Exception( G::LoadTranslation( 'ID_CASE_IS_CURRENTLY_WITH_ANOTHER_USER' ) );
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
throw new Exception( "Application ID or Delegation Index is missing!. The System can't open the case." );
|
throw new Exception( "Application ID or Delegation Index is missing!. The System can't open the case." );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
require_once ("classes/model/Step.php");
|
require_once ("classes/model/Step.php");
|
||||||
G::LoadClass( "configuration" );
|
G::LoadClass( "configuration" );
|
||||||
G::LoadClass( "case" );
|
G::LoadClass( "case" );
|
||||||
$oCase = new Cases();
|
$oCase = new Cases();
|
||||||
$conf = new Configurations;
|
$conf = new Configurations();
|
||||||
|
|
||||||
$oHeadPublisher = & headPublisher::getSingleton();
|
$oHeadPublisher = & headPublisher::getSingleton();
|
||||||
|
|
||||||
@@ -67,8 +65,7 @@
|
|||||||
|
|
||||||
if (! isset( $_GET['to_revise'] )) {
|
if (! isset( $_GET['to_revise'] )) {
|
||||||
$script = 'cases_Open?';
|
$script = 'cases_Open?';
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$script = 'cases_OpenToRevise?';
|
$script = 'cases_OpenToRevise?';
|
||||||
$delIndex = $_GET['DEL_INDEX'];
|
$delIndex = $_GET['DEL_INDEX'];
|
||||||
$appUid = $_GET['APP_UID'];
|
$appUid = $_GET['APP_UID'];
|
||||||
@@ -78,7 +75,7 @@
|
|||||||
echo "<div id='toReviseTree'></div>";
|
echo "<div id='toReviseTree'></div>";
|
||||||
}
|
}
|
||||||
|
|
||||||
$oStep = new Step;
|
$oStep = new Step();
|
||||||
$oStep = $oStep->loadByProcessTaskPosition( $case['PRO_UID'], $case['TAS_UID'], 1 );
|
$oStep = $oStep->loadByProcessTaskPosition( $case['PRO_UID'], $case['TAS_UID'], 1 );
|
||||||
|
|
||||||
$oHeadPublisher->assign( 'uri', $script . $uri );
|
$oHeadPublisher->assign( 'uri', $script . $uri );
|
||||||
@@ -87,7 +84,5 @@
|
|||||||
$oHeadPublisher->assign( '_ENV_CURRENT_DATE_NO_FORMAT', date( 'Y-m-d' ) );
|
$oHeadPublisher->assign( '_ENV_CURRENT_DATE_NO_FORMAT', date( 'Y-m-d' ) );
|
||||||
$oHeadPublisher->assign( 'idfirstform', is_null( $oStep ) ? '' : $oStep->getStepUidObj() );
|
$oHeadPublisher->assign( 'idfirstform', is_null( $oStep ) ? '' : $oStep->getStepUidObj() );
|
||||||
|
|
||||||
|
|
||||||
G::RenderPage( 'publish', 'extJs' );
|
G::RenderPage( 'publish', 'extJs' );
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -22,62 +22,19 @@ try {
|
|||||||
$userUid = (isset( $_SESSION["USER_LOGGED"] ) && $_SESSION["USER_LOGGED"] != "") ? $_SESSION["USER_LOGGED"] : null;
|
$userUid = (isset( $_SESSION["USER_LOGGED"] ) && $_SESSION["USER_LOGGED"] != "") ? $_SESSION["USER_LOGGED"] : null;
|
||||||
$user = ($user == "CURRENT_USER") ? $userUid : $user;
|
$user = ($user == "CURRENT_USER") ? $userUid : $user;
|
||||||
|
|
||||||
if ((
|
if (($action == "todo" || $action == "draft" || $action == "sent" || $action == "selfservice" || $action == "unassigned" || $action == "search") && (($solrConf = System::solrEnv()) !== false)) {
|
||||||
$action == "todo" || $action == "draft" || $action == "sent" || $action == "selfservice" ||
|
|
||||||
$action == "unassigned" || $action == "search"
|
|
||||||
)
|
|
||||||
&&
|
|
||||||
(($solrConf = System::solrEnv()) !== false)
|
|
||||||
) {
|
|
||||||
G::LoadClass( "AppSolr" );
|
G::LoadClass( "AppSolr" );
|
||||||
|
|
||||||
$ApplicationSolrIndex = new AppSolr(
|
$ApplicationSolrIndex = new AppSolr( $solrConf["solr_enabled"], $solrConf["solr_host"], $solrConf["solr_instance"] );
|
||||||
$solrConf["solr_enabled"],
|
|
||||||
$solrConf["solr_host"],
|
|
||||||
$solrConf["solr_instance"]
|
|
||||||
);
|
|
||||||
|
|
||||||
$data = $ApplicationSolrIndex->getAppGridData(
|
$data = $ApplicationSolrIndex->getAppGridData( $userUid, $start, $limit, $action, $filter, $search, $process, $user, $status, $type, $dateFrom, $dateTo, $callback, $dir, $sort );
|
||||||
$userUid,
|
|
||||||
$start,
|
|
||||||
$limit,
|
|
||||||
$action,
|
|
||||||
$filter,
|
|
||||||
$search,
|
|
||||||
$process,
|
|
||||||
$user,
|
|
||||||
$status,
|
|
||||||
$type,
|
|
||||||
$dateFrom,
|
|
||||||
$dateTo,
|
|
||||||
$callback,
|
|
||||||
$dir,
|
|
||||||
$sort
|
|
||||||
);
|
|
||||||
|
|
||||||
$result = G::json_encode( $data );
|
$result = G::json_encode( $data );
|
||||||
} else {
|
} else {
|
||||||
G::LoadClass( "applications" );
|
G::LoadClass( "applications" );
|
||||||
|
|
||||||
$apps = new Applications();
|
$apps = new Applications();
|
||||||
$data = $apps->getAll(
|
$data = $apps->getAll( $userUid, $start, $limit, $action, $filter, $search, $process, $user, $status, $type, $dateFrom, $dateTo, $callback, $dir, $sort, $category );
|
||||||
$userUid,
|
|
||||||
$start,
|
|
||||||
$limit,
|
|
||||||
$action,
|
|
||||||
$filter,
|
|
||||||
$search,
|
|
||||||
$process,
|
|
||||||
$user,
|
|
||||||
$status,
|
|
||||||
$type,
|
|
||||||
$dateFrom,
|
|
||||||
$dateTo,
|
|
||||||
$callback,
|
|
||||||
$dir,
|
|
||||||
$sort,
|
|
||||||
$category
|
|
||||||
);
|
|
||||||
|
|
||||||
$result = G::json_encode( $data );
|
$result = G::json_encode( $data );
|
||||||
}
|
}
|
||||||
@@ -85,7 +42,6 @@ try {
|
|||||||
echo $result;
|
echo $result;
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
$msg = array ("error" => $e->getMessage() );
|
$msg = array ("error" => $e->getMessage() );
|
||||||
|
|
||||||
echo G::json_encode( $msg );
|
echo G::json_encode( $msg );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,8 @@
|
|||||||
$query = isset( $_POST['query'] ) ? $_POST['query'] : '';
|
$query = isset( $_POST['query'] ) ? $_POST['query'] : '';
|
||||||
//$action = isset($_GET['action']) ? $_GET['action'] : 'read';
|
//$action = isset($_GET['action']) ? $_GET['action'] : 'read';
|
||||||
$option = '';
|
$option = '';
|
||||||
if ( isset($_GET['t'] ) ) $option = $_GET['t'];
|
if (isset( $_GET['t'] ))
|
||||||
|
$option = $_GET['t'];
|
||||||
try {
|
try {
|
||||||
|
|
||||||
G::LoadClass( "BasePeer" );
|
G::LoadClass( "BasePeer" );
|
||||||
@@ -28,11 +29,13 @@
|
|||||||
$Criteria->add( AppCacheViewPeer::APP_STATUS, "TO_DO", CRITERIA::EQUAL );
|
$Criteria->add( AppCacheViewPeer::APP_STATUS, "TO_DO", CRITERIA::EQUAL );
|
||||||
$Criteria->add( AppCacheViewPeer::USR_UID, $sUIDUserLogged );
|
$Criteria->add( AppCacheViewPeer::USR_UID, $sUIDUserLogged );
|
||||||
|
|
||||||
|
|
||||||
//$totalCount = AppCacheViewPeer::doCount( $Criteria );
|
//$totalCount = AppCacheViewPeer::doCount( $Criteria );
|
||||||
|
|
||||||
if ( isset($limit) ) $Criteria->setLimit( $limit );
|
|
||||||
if ( isset($start) ) $Criteria->setOffset( $start );
|
if (isset( $limit ))
|
||||||
|
$Criteria->setLimit( $limit );
|
||||||
|
if (isset( $start ))
|
||||||
|
$Criteria->setOffset( $start );
|
||||||
|
|
||||||
if ($sort != '') {
|
if ($sort != '') {
|
||||||
if ($dir == 'DESC')
|
if ($dir == 'DESC')
|
||||||
@@ -58,10 +61,10 @@
|
|||||||
|
|
||||||
print G::json_encode( $result );
|
print G::json_encode( $result );
|
||||||
|
|
||||||
}
|
} catch (Exception $e) {
|
||||||
catch ( Exception $e ) {
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH = new Publisher;
|
|
||||||
$aMessage['MESSAGE'] = $e->getMessage();
|
$aMessage['MESSAGE'] = $e->getMessage();
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
|
||||||
G::RenderPage( 'publish', 'blank' );
|
G::RenderPage( 'publish', 'blank' );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,8 @@
|
|||||||
// getting all App Uids and task Uids
|
// getting all App Uids and task Uids
|
||||||
foreach ($sentUids as $sentUid) {
|
foreach ($sentUids as $sentUid) {
|
||||||
$aItem = explode( '|', $sentUid );
|
$aItem = explode( '|', $sentUid );
|
||||||
$allUidsRecords[] = array ( 'APP_UID' => $aItem[0] , 'TAS_UID' => $aItem[1], 'DEL_INDEX' => $aItem[2]);
|
$allUidsRecords[] = array ('APP_UID' => $aItem[0],'TAS_UID' => $aItem[1],'DEL_INDEX' => $aItem[2]
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
$sReassignFromUser = isset( $_POST['user'] ) ? $_POST['user'] : '';
|
$sReassignFromUser = isset( $_POST['user'] ) ? $_POST['user'] : '';
|
||||||
@@ -54,7 +55,8 @@
|
|||||||
foreach ($aCaseUsers as $aCaseUser) {
|
foreach ($aCaseUsers as $aCaseUser) {
|
||||||
if ($aCaseUser['USR_UID'] != $sReassignFromUser) {
|
if ($aCaseUser['USR_UID'] != $sReassignFromUser) {
|
||||||
$aCaseUserRecord = $oUser->load( $aCaseUser['USR_UID'] );
|
$aCaseUserRecord = $oUser->load( $aCaseUser['USR_UID'] );
|
||||||
$aUsersInvolved[] = array ( 'userUid' => $aCaseUser['USR_UID'] , 'userFullname' => $aCaseUserRecord['USR_FIRSTNAME'] . ' ' . $aCaseUserRecord['USR_LASTNAME']); // . ' (' . $aCaseUserRecord['USR_USERNAME']
|
$aUsersInvolved[] = array ('userUid' => $aCaseUser['USR_UID'],'userFullname' => $aCaseUserRecord['USR_FIRSTNAME'] . ' ' . $aCaseUserRecord['USR_LASTNAME']
|
||||||
|
); // . ' (' . $aCaseUserRecord['USR_USERNAME']
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -63,7 +65,8 @@
|
|||||||
foreach ($aCaseUsers as $aCaseUser) {
|
foreach ($aCaseUsers as $aCaseUser) {
|
||||||
if ($aCaseUser['USR_UID'] != $sReassignFromUser) {
|
if ($aCaseUser['USR_UID'] != $sReassignFromUser) {
|
||||||
$aCaseUserRecord = $oUser->load( $aCaseUser['USR_UID'] );
|
$aCaseUserRecord = $oUser->load( $aCaseUser['USR_UID'] );
|
||||||
$aUsersInvolved[] = array ( 'userUid' => $aCaseUser['USR_UID'] , 'userFullname' => $aCaseUserRecord['USR_FIRSTNAME'] . ' ' . $aCaseUserRecord['USR_LASTNAME']);
|
$aUsersInvolved[] = array ('userUid' => $aCaseUser['USR_UID'],'userFullname' => $aCaseUserRecord['USR_FIRSTNAME'] . ' ' . $aCaseUserRecord['USR_LASTNAME']
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$oTmp = $aUsersInvolved;
|
$oTmp = $aUsersInvolved;
|
||||||
@@ -71,27 +74,11 @@
|
|||||||
array_push( $aCasesList, $aCase );
|
array_push( $aCasesList, $aCase );
|
||||||
}
|
}
|
||||||
|
|
||||||
$filedNames = Array (
|
$filedNames = Array ("APP_UID","APP_NUMBER","APP_UPDATE_DATE","DEL_PRIORITY","DEL_INDEX","TAS_UID","DEL_INIT_DATE","DEL_FINISH_DATE","USR_UID","APP_STATUS","DEL_TASK_DUE_DATE","APP_CURRENT_USER","APP_TITLE","APP_PRO_TITLE","APP_TAS_TITLE","APP_DEL_PREVIOUS_USER","USERS"
|
||||||
"APP_UID",
|
|
||||||
"APP_NUMBER",
|
|
||||||
"APP_UPDATE_DATE",
|
|
||||||
"DEL_PRIORITY",
|
|
||||||
"DEL_INDEX",
|
|
||||||
"TAS_UID",
|
|
||||||
"DEL_INIT_DATE",
|
|
||||||
"DEL_FINISH_DATE",
|
|
||||||
"USR_UID",
|
|
||||||
"APP_STATUS",
|
|
||||||
"DEL_TASK_DUE_DATE",
|
|
||||||
"APP_CURRENT_USER",
|
|
||||||
"APP_TITLE",
|
|
||||||
"APP_PRO_TITLE",
|
|
||||||
"APP_TAS_TITLE",
|
|
||||||
"APP_DEL_PREVIOUS_USER",
|
|
||||||
"USERS"
|
|
||||||
);
|
);
|
||||||
|
|
||||||
$aCasesList = array_merge(Array($filedNames), $aCasesList);
|
$aCasesList = array_merge( Array ($filedNames
|
||||||
|
), $aCasesList );
|
||||||
$rows = array ();
|
$rows = array ();
|
||||||
$i = $start;
|
$i = $start;
|
||||||
for ($j = 0; $j < $limit; $j ++) {
|
for ($j = 0; $j < $limit; $j ++) {
|
||||||
@@ -108,3 +95,4 @@
|
|||||||
$result['data'] = $rows;
|
$result['data'] = $rows;
|
||||||
//print the result in json format
|
//print the result in json format
|
||||||
print G::json_encode( $result );
|
print G::json_encode( $result );
|
||||||
|
|
||||||
|
|||||||
@@ -46,8 +46,7 @@ function array_sort($array, $on, $order=SORT_ASC, $query='')
|
|||||||
foreach ($sortable_array as $k => $v) {
|
foreach ($sortable_array as $k => $v) {
|
||||||
if ($query == '') {
|
if ($query == '') {
|
||||||
$new_array[] = $array[$k];
|
$new_array[] = $array[$k];
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
if (preg_match( "/" . $query . "/i", $array[$k]['userFullname'] )) {
|
if (preg_match( "/" . $query . "/i", $array[$k]['userFullname'] )) {
|
||||||
$new_array[] = $array[$k];
|
$new_array[] = $array[$k];
|
||||||
}
|
}
|
||||||
@@ -58,6 +57,7 @@ function array_sort($array, $on, $order=SORT_ASC, $query='')
|
|||||||
}
|
}
|
||||||
// $APP_UIDS = explode(',', $_POST['APP_UID']);
|
// $APP_UIDS = explode(',', $_POST['APP_UID']);
|
||||||
|
|
||||||
|
|
||||||
$appUid = isset( $_POST['application'] ) ? $_POST['application'] : '';
|
$appUid = isset( $_POST['application'] ) ? $_POST['application'] : '';
|
||||||
// $processUid = isset($_POST['process']) ? $_POST['process'] : '';
|
// $processUid = isset($_POST['process']) ? $_POST['process'] : '';
|
||||||
$TaskUid = isset( $_POST['task'] ) ? $_POST['task'] : '';
|
$TaskUid = isset( $_POST['task'] ) ? $_POST['task'] : '';
|
||||||
@@ -77,7 +77,7 @@ function array_sort($array, $on, $order=SORT_ASC, $query='')
|
|||||||
|
|
||||||
$aUsersInvolved = Array ();
|
$aUsersInvolved = Array ();
|
||||||
$aCaseGroups = $oTasks->getGroupsOfTask( $TaskUid, 1 );
|
$aCaseGroups = $oTasks->getGroupsOfTask( $TaskUid, 1 );
|
||||||
$oConf = new Configurations;
|
$oConf = new Configurations();
|
||||||
$ConfEnv = $oConf->getFormats();
|
$ConfEnv = $oConf->getFormats();
|
||||||
foreach ($aCaseGroups as $aCaseGroup) {
|
foreach ($aCaseGroups as $aCaseGroup) {
|
||||||
$aCaseUsers = $oGroups->getUsersOfGroup( $aCaseGroup['GRP_UID'] );
|
$aCaseUsers = $oGroups->getUsersOfGroup( $aCaseGroup['GRP_UID'] );
|
||||||
@@ -86,7 +86,8 @@ function array_sort($array, $on, $order=SORT_ASC, $query='')
|
|||||||
$aCaseUserRecord = $oUser->load( $aCaseUser['USR_UID'] );
|
$aCaseUserRecord = $oUser->load( $aCaseUser['USR_UID'] );
|
||||||
$sCaseUser = G::getFormatUserList( $ConfEnv['format'], $aCaseUserRecord );
|
$sCaseUser = G::getFormatUserList( $ConfEnv['format'], $aCaseUserRecord );
|
||||||
// $aUsersInvolved[] = array ( 'userUid' => $aCaseUser['USR_UID'] , 'userFullname' => $aCaseUserRecord['USR_FIRSTNAME'] . ' ' . $aCaseUserRecord['USR_LASTNAME']); // . ' (' . $aCaseUserRecord['USR_USERNAME'] . ')';
|
// $aUsersInvolved[] = array ( 'userUid' => $aCaseUser['USR_UID'] , 'userFullname' => $aCaseUserRecord['USR_FIRSTNAME'] . ' ' . $aCaseUserRecord['USR_LASTNAME']); // . ' (' . $aCaseUserRecord['USR_USERNAME'] . ')';
|
||||||
$aUsersInvolved[] = array ( 'userUid' => $aCaseUser['USR_UID'] , 'userFullname' => $sCaseUser); // . ' (' . $aCaseUserRecord['USR_USERNAME'] . ')';
|
$aUsersInvolved[] = array ('userUid' => $aCaseUser['USR_UID'],'userFullname' => $sCaseUser
|
||||||
|
); // . ' (' . $aCaseUserRecord['USR_USERNAME'] . ')';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -97,7 +98,8 @@ function array_sort($array, $on, $order=SORT_ASC, $query='')
|
|||||||
$aCaseUserRecord = $oUser->load( $aCaseUser['USR_UID'] );
|
$aCaseUserRecord = $oUser->load( $aCaseUser['USR_UID'] );
|
||||||
$sCaseUser = G::getFormatUserList( $ConfEnv['format'], $aCaseUserRecord );
|
$sCaseUser = G::getFormatUserList( $ConfEnv['format'], $aCaseUserRecord );
|
||||||
// $aUsersInvolved[] = array ( 'userUid' => $aCaseUser['USR_UID'] , 'userFullname' => $aCaseUserRecord['USR_FIRSTNAME'] . ' ' . $aCaseUserRecord['USR_LASTNAME']); // . ' (' . $aCaseUserRecord['USR_USERNAME'] . ')';
|
// $aUsersInvolved[] = array ( 'userUid' => $aCaseUser['USR_UID'] , 'userFullname' => $aCaseUserRecord['USR_FIRSTNAME'] . ' ' . $aCaseUserRecord['USR_LASTNAME']); // . ' (' . $aCaseUserRecord['USR_USERNAME'] . ')';
|
||||||
$aUsersInvolved[] = array ( 'userUid' => $aCaseUser['USR_UID'] , 'userFullname' => $sCaseUser); // . ' (' . $aCaseUserRecord['USR_USERNAME'] . ')';
|
$aUsersInvolved[] = array ('userUid' => $aCaseUser['USR_UID'],'userFullname' => $sCaseUser
|
||||||
|
); // . ' (' . $aCaseUserRecord['USR_USERNAME'] . ')';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// $oTmp = new stdClass();
|
// $oTmp = new stdClass();
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
$aData = G::json_decode( $_POST['data'] );
|
$aData = G::json_decode( $_POST['data'] );
|
||||||
$appSelectedUids = array ();
|
$appSelectedUids = array ();
|
||||||
@@ -65,13 +64,10 @@
|
|||||||
$oCases->reassignCase( $aCase['APP_UID'], $aCase['DEL_INDEX'], ($aCase['USR_UID'] != '' ? $aCase['USR_UID'] : $_SESSION['USER_LOGGED']), $data->APP_REASSIGN_USER_UID );
|
$oCases->reassignCase( $aCase['APP_UID'], $aCase['DEL_INDEX'], ($aCase['USR_UID'] != '' ? $aCase['USR_UID'] : $_SESSION['USER_LOGGED']), $data->APP_REASSIGN_USER_UID );
|
||||||
$currentCasesReassigned ++;
|
$currentCasesReassigned ++;
|
||||||
$casesReassignedCount ++;
|
$casesReassignedCount ++;
|
||||||
$serverResponse[] = array ('APP_REASSIGN_USER' => $data->APP_REASSIGN_USER,
|
$serverResponse[] = array ('APP_REASSIGN_USER' => $data->APP_REASSIGN_USER,'APP_TITLE' => $data->APP_TITLE,'TAS_TITLE' => $data->APP_TAS_TITLE,'REASSIGNED_CASES' => $currentCasesReassigned
|
||||||
'APP_TITLE' => $data->APP_TITLE,
|
);
|
||||||
'TAS_TITLE' => $data->APP_TAS_TITLE,
|
|
||||||
'REASSIGNED_CASES' => $currentCasesReassigned);
|
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$oTmpReassignCriteria = $oCasesReassignList;
|
$oTmpReassignCriteria = $oCasesReassignList;
|
||||||
$oTmpReassignCriteria->add( AppCacheViewPeer::TAS_UID, $aData->TAS_UID );
|
$oTmpReassignCriteria->add( AppCacheViewPeer::TAS_UID, $aData->TAS_UID );
|
||||||
$rs = AppCacheViewPeer::doSelectRS( $oTmpReassignCriteria );
|
$rs = AppCacheViewPeer::doSelectRS( $oTmpReassignCriteria );
|
||||||
@@ -90,8 +86,10 @@
|
|||||||
$rs->next();
|
$rs->next();
|
||||||
$row = $rs->getRow();
|
$row = $rs->getRow();
|
||||||
}
|
}
|
||||||
$serverResponse[] = array ('TAS_TITLE'=>$aData->APP_TAS_TITLE,'REASSIGNED_CASES'=>$currentCasesReassigned);
|
$serverResponse[] = array ('TAS_TITLE' => $aData->APP_TAS_TITLE,'REASSIGNED_CASES' => $currentCasesReassigned
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
$serverResponse['TOTAL'] = $casesReassignedCount;
|
$serverResponse['TOTAL'] = $casesReassignedCount;
|
||||||
echo G::json_encode( $serverResponse );
|
echo G::json_encode( $serverResponse );
|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
*
|
*
|
||||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@@ -41,13 +40,11 @@ try {
|
|||||||
if ($_REQUEST['APP_UID'] == '' || $_REQUEST['DEL_INDEX'] == '' || $_REQUEST['DYN_UID'] == '') {
|
if ($_REQUEST['APP_UID'] == '' || $_REQUEST['DEL_INDEX'] == '' || $_REQUEST['DYN_UID'] == '') {
|
||||||
throw new Exception( G::LoadTranslation( 'ID_REQUIRED_FIELDS_ERROR' ) . ' (APP_UID, DEL_INDEX, DYN_UID)' );
|
throw new Exception( G::LoadTranslation( 'ID_REQUIRED_FIELDS_ERROR' ) . ' (APP_UID, DEL_INDEX, DYN_UID)' );
|
||||||
}
|
}
|
||||||
|
|
||||||
G::LoadClass( 'case' );
|
G::LoadClass( 'case' );
|
||||||
$case = new Cases();
|
$case = new Cases();
|
||||||
if ($RBAC->userCanAccess( 'PM_ALLCASES' ) < 0 && $case->userParticipatedInCase( $_REQUEST['APP_UID'], $_SESSION['USER_LOGGED'] ) == 0) {
|
if ($RBAC->userCanAccess( 'PM_ALLCASES' ) < 0 && $case->userParticipatedInCase( $_REQUEST['APP_UID'], $_SESSION['USER_LOGGED'] ) == 0) {
|
||||||
throw new Exception( G::LoadTranslation( 'ID_NO_PERMISSION_NO_PARTICIPATED' ) );
|
throw new Exception( G::LoadTranslation( 'ID_NO_PERMISSION_NO_PARTICIPATED' ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
$applicationFields = $case->loadCase( $_REQUEST['APP_UID'], $_REQUEST['DEL_INDEX'] );
|
$applicationFields = $case->loadCase( $_REQUEST['APP_UID'], $_REQUEST['DEL_INDEX'] );
|
||||||
|
|
||||||
if (file_exists( PATH_DYNAFORM . $applicationFields['PRO_UID'] . PATH_SEP . $_REQUEST['DYN_UID'] . '.xml' )) {
|
if (file_exists( PATH_DYNAFORM . $applicationFields['PRO_UID'] . PATH_SEP . $_REQUEST['DYN_UID'] . '.xml' )) {
|
||||||
@@ -66,15 +63,15 @@ try {
|
|||||||
$G_PUBLISH = new Publisher();
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH->AddContent( 'dynaform', 'xmlform', $applicationFields['PRO_UID'] . '/' . $_REQUEST['DYN_UID'], '', $applicationFields['APP_DATA'], '', '', 'view' );
|
$G_PUBLISH->AddContent( 'dynaform', 'xmlform', $applicationFields['PRO_UID'] . '/' . $_REQUEST['DYN_UID'], '', $applicationFields['APP_DATA'], '', '', 'view' );
|
||||||
G::RenderPage( 'publish', 'blank' );
|
G::RenderPage( 'publish', 'blank' );
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
throw new Exception( G::LoadTranslation( 'INVALID_FILE' ) . ': ' . $_REQUEST['DYN_UID'] );
|
throw new Exception( G::LoadTranslation( 'INVALID_FILE' ) . ': ' . $_REQUEST['DYN_UID'] );
|
||||||
}
|
}
|
||||||
}
|
} catch (Exception $error) {
|
||||||
catch (Exception $error) {
|
|
||||||
global $G_PUBLISH;
|
global $G_PUBLISH;
|
||||||
$G_PUBLISH = new Publisher();
|
$G_PUBLISH = new Publisher();
|
||||||
$G_PUBLISH->AddContent('xmlform', 'xmlform', 'login/showMessage', '', array('MESSAGE' => $error->getMessage()));
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'login/showMessage', '', array ('MESSAGE' => $error->getMessage()
|
||||||
|
) );
|
||||||
G::RenderPage( 'publish', 'blank' );
|
G::RenderPage( 'publish', 'blank' );
|
||||||
die();
|
die();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user