BUG 5979 "Cases are overwritten with data from another..." SOlVED

- problem fixed passing the app uid by GET and acomparing with the session data
  so, if there were differents a message to re-open case will be throw
This commit is contained in:
Erik Amaru Ortiz
2011-11-23 19:10:25 -04:00
parent 92c35449bd
commit 7f336e1757
2 changed files with 223 additions and 206 deletions

View File

@@ -23,231 +23,248 @@
* *
*/ */
//validate the data post //validate the data post
$oForm = new Form ( $_SESSION ['PROCESS'] . '/' . $_GET ['UID'], PATH_DYNAFORM );
$oForm->validatePost ();
/* Includes */ try {
G::LoadClass ( 'case' );
//load the variables if ($_GET['APP_UID'] !== $_SESSION ['APPLICATION']) {
$oCase = new Cases ( ); throw new Exception(G::LoadTranslation('ID_INVALID_APPLICATION_ID_MSG', array('<a href=\''.$_SERVER['HTTP_REFERER'].'\'>{1}</a>', G::LoadTranslation('ID_REOPEN'))));
$oCase->thisIsTheCurrentUser ( $_SESSION ['APPLICATION'], $_SESSION ['INDEX'], $_SESSION ['USER_LOGGED'], 'REDIRECT', 'cases_List' ); }
$Fields = $oCase->loadCase ( $_SESSION ['APPLICATION'] );
$Fields ['APP_DATA'] = array_merge ( $Fields ['APP_DATA'], G::getSystemConstants () );
$Fields ['APP_DATA'] = array_merge ( $Fields ['APP_DATA'], ( array ) $_POST ['form'] );
#here we must verify if is a debug session $oForm = new Form ( $_SESSION ['PROCESS'] . '/' . $_GET ['UID'], PATH_DYNAFORM );
$trigger_debug_session = $_SESSION ['TRIGGER_DEBUG'] ['ISSET']; #here we must verify if is a debugg session $oForm->validatePost ();
/* Includes */
G::LoadClass ( 'case' );
//load the variables
$oCase = new Cases ( );
$oCase->thisIsTheCurrentUser ( $_SESSION ['APPLICATION'], $_SESSION ['INDEX'], $_SESSION ['USER_LOGGED'], 'REDIRECT', 'cases_List' );
$Fields = $oCase->loadCase ( $_SESSION ['APPLICATION'] );
$Fields ['APP_DATA'] = array_merge ( $Fields ['APP_DATA'], G::getSystemConstants () );
$Fields ['APP_DATA'] = array_merge ( $Fields ['APP_DATA'], ( array ) $_POST ['form'] );
#here we must verify if is a debug session
$trigger_debug_session = $_SESSION ['TRIGGER_DEBUG'] ['ISSET']; #here we must verify if is a debugg session
#trigger debug routines... #trigger debug routines...
//cleaning debug variables //cleaning debug variables
$_SESSION ['TRIGGER_DEBUG'] ['ERRORS'] = Array (); $_SESSION ['TRIGGER_DEBUG'] ['ERRORS'] = Array ();
$_SESSION ['TRIGGER_DEBUG'] ['DATA'] = Array (); $_SESSION ['TRIGGER_DEBUG'] ['DATA'] = Array ();
$_SESSION ['TRIGGER_DEBUG'] ['TRIGGERS_NAMES'] = Array (); $_SESSION ['TRIGGER_DEBUG'] ['TRIGGERS_NAMES'] = Array ();
$_SESSION ['TRIGGER_DEBUG'] ['TRIGGERS_VALUES'] = Array (); $_SESSION ['TRIGGER_DEBUG'] ['TRIGGERS_VALUES'] = Array ();
$triggers = $oCase->loadTriggers ( $_SESSION ['TASK'], 'DYNAFORM', $_GET ['UID'], 'AFTER' ); $triggers = $oCase->loadTriggers ( $_SESSION ['TASK'], 'DYNAFORM', $_GET ['UID'], 'AFTER' );
$_SESSION ['TRIGGER_DEBUG'] ['NUM_TRIGGERS'] = count ( $triggers ); $_SESSION ['TRIGGER_DEBUG'] ['NUM_TRIGGERS'] = count ( $triggers );
$_SESSION ['TRIGGER_DEBUG'] ['TIME'] = 'AFTER'; $_SESSION ['TRIGGER_DEBUG'] ['TIME'] = 'AFTER';
if ($_SESSION ['TRIGGER_DEBUG'] ['NUM_TRIGGERS'] != 0) { if ($_SESSION ['TRIGGER_DEBUG'] ['NUM_TRIGGERS'] != 0) {
$_SESSION ['TRIGGER_DEBUG'] ['TRIGGERS_NAMES'] = $oCase->getTriggerNames ( $triggers ); $_SESSION ['TRIGGER_DEBUG'] ['TRIGGERS_NAMES'] = $oCase->getTriggerNames ( $triggers );
$_SESSION ['TRIGGER_DEBUG'] ['TRIGGERS_VALUES'] = $triggers; $_SESSION ['TRIGGER_DEBUG'] ['TRIGGERS_VALUES'] = $triggers;
} }
if ($_SESSION ['TRIGGER_DEBUG'] ['NUM_TRIGGERS'] != 0) { if ($_SESSION ['TRIGGER_DEBUG'] ['NUM_TRIGGERS'] != 0) {
//Execute after triggers - Start //Execute after triggers - Start
$Fields ['APP_DATA'] = $oCase->ExecuteTriggers ( $_SESSION ['TASK'], 'DYNAFORM', $_GET ['UID'], 'AFTER', $Fields ['APP_DATA'] ); $Fields ['APP_DATA'] = $oCase->ExecuteTriggers ( $_SESSION ['TASK'], 'DYNAFORM', $_GET ['UID'], 'AFTER', $Fields ['APP_DATA'] );
//Execute after triggers - End //Execute after triggers - End
} }
//save data in PM Tables if necessary //save data in PM Tables if necessary
$newValues = array (); $newValues = array ();
foreach ( $_POST ['form'] as $sField => $sAux ) { foreach ( $_POST ['form'] as $sField => $sAux ) {
if (isset ( $oForm->fields [$sField]->pmconnection ) && isset ( $oForm->fields [$sField]->pmfield )) { if (isset ( $oForm->fields [$sField]->pmconnection ) && isset ( $oForm->fields [$sField]->pmfield )) {
if (($oForm->fields [$sField]->pmconnection != '') && ($oForm->fields [$sField]->pmfield != '')) { if (($oForm->fields [$sField]->pmconnection != '') && ($oForm->fields [$sField]->pmfield != '')) {
if (isset ( $oForm->fields [$oForm->fields [$sField]->pmconnection] )) { if (isset ( $oForm->fields [$oForm->fields [$sField]->pmconnection] )) {
require_once PATH_CORE . 'classes' . PATH_SEP . 'model' . PATH_SEP . 'AdditionalTables.php'; require_once PATH_CORE . 'classes' . PATH_SEP . 'model' . PATH_SEP . 'AdditionalTables.php';
$oAdditionalTables = new AdditionalTables ( ); $oAdditionalTables = new AdditionalTables ( );
try { try {
$aData = $oAdditionalTables->load ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, true ); $aData = $oAdditionalTables->load ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, true );
} catch ( Exception $oError ) { } catch ( Exception $oError ) {
$aData = array ('FIELDS' => array () ); $aData = array ('FIELDS' => array () );
} }
$aKeys = array (); $aKeys = array ();
$aAux = explode ( '|', $oForm->fields [$oForm->fields [$sField]->pmconnection]->keys ); $aAux = explode ( '|', $oForm->fields [$oForm->fields [$sField]->pmconnection]->keys );
$i = 0; $i = 0;
$aValues = array (); $aValues = array ();
foreach ( $aData ['FIELDS'] as $aField ) { foreach ( $aData ['FIELDS'] as $aField ) {
if ($aField ['FLD_KEY'] == '1') { if ($aField ['FLD_KEY'] == '1') {
$aKeys [$aField ['FLD_NAME']] = (isset ( $aAux [$i] ) ? G::replaceDataField ( $aAux [$i], $Fields ['APP_DATA'] ) : ''); $aKeys [$aField ['FLD_NAME']] = (isset ( $aAux [$i] ) ? G::replaceDataField ( $aAux [$i], $Fields ['APP_DATA'] ) : '');
$i ++; $i ++;
} }
if ($aField ['FLD_NAME'] == $oForm->fields [$sField]->pmfield) { if ($aField ['FLD_NAME'] == $oForm->fields [$sField]->pmfield) {
$aValues [$aField ['FLD_NAME']] = $Fields ['APP_DATA'] [$sField]; $aValues [$aField ['FLD_NAME']] = $Fields ['APP_DATA'] [$sField];
} else { } else {
$aValues [$aField ['FLD_NAME']] = ''; $aValues [$aField ['FLD_NAME']] = '';
} }
} }
try { try {
$aRow = $oAdditionalTables->getDataTable ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $aKeys ); $aRow = $oAdditionalTables->getDataTable ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $aKeys );
} catch ( Exception $oError ) { } catch ( Exception $oError ) {
$aRow = false; $aRow = false;
} }
if ($aRow) { if ($aRow) {
foreach ( $aValues as $sKey => $sValue ) { foreach ( $aValues as $sKey => $sValue ) {
if ($sKey != $oForm->fields [$sField]->pmfield) { if ($sKey != $oForm->fields [$sField]->pmfield) {
$aValues [$sKey] = $aRow [$sKey]; $aValues [$sKey] = $aRow [$sKey];
} }
} }
try { try {
$oAdditionalTables->updateDataInTable ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $aValues ); $oAdditionalTables->updateDataInTable ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $aValues );
} catch ( Exception $oError ) { } catch ( Exception $oError ) {
//Nothing //Nothing
} }
} else { }
try { else {
// assembling the field list in order to save the data ina new record of a pm table try {
if (empty($newValues)){ // assembling the field list in order to save the data ina new record of a pm table
$newValues = $aValues; if (empty($newValues)){
} else { $newValues = $aValues;
foreach ($aValues as $aValueKey=>$aValueCont) { }
if (trim($newValues[$aValueKey])==''){ else {
$newValues[$aValueKey] = $aValueCont; foreach ($aValues as $aValueKey=>$aValueCont) {
} if (trim($newValues[$aValueKey])==''){
} $newValues[$aValueKey] = $aValueCont;
} }
//$oAdditionalTables->saveDataInTable ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $aValues ); }
}
} catch ( Exception $oError ) { //$oAdditionalTables->saveDataInTable ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $aValues );
//Nothing } catch ( Exception $oError ) {
} //Nothing
} }
} }
} }
} }
} }
// saving the data ina pm table in case that is a new record }
if (!empty($newValues)){ // saving the data ina pm table in case that is a new record
if(!$oAdditionalTables->saveDataInTable ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $newValues)) if (!empty($newValues)){
$oAdditionalTables->updateDataInTable( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $newValues); if(!$oAdditionalTables->saveDataInTable ( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $newValues))
} $oAdditionalTables->updateDataInTable( $oForm->fields [$oForm->fields [$sField]->pmconnection]->pmtable, $newValues);
//save data }
$aData = array (); //save data
$aData ['APP_NUMBER'] = $Fields ['APP_NUMBER']; $aData = array ();
$aData ['APP_PROC_STATUS'] = $Fields ['APP_PROC_STATUS']; $aData ['APP_NUMBER'] = $Fields ['APP_NUMBER'];
$aData ['APP_DATA'] = $Fields ['APP_DATA']; $aData ['APP_PROC_STATUS'] = $Fields ['APP_PROC_STATUS'];
$aData ['DEL_INDEX'] = $_SESSION ['INDEX']; $aData ['APP_DATA'] = $Fields ['APP_DATA'];
$aData ['TAS_UID'] = $_SESSION ['TASK']; $aData ['DEL_INDEX'] = $_SESSION ['INDEX'];
$aData ['CURRENT_DYNAFORM'] = $_GET ['UID']; $aData ['TAS_UID'] = $_SESSION ['TASK'];
$aData ['USER_UID'] = $_SESSION ['USER_LOGGED']; $aData ['CURRENT_DYNAFORM'] = $_GET ['UID'];
$aData ['APP_STATUS'] = $Fields ['APP_STATUS']; $aData ['USER_UID'] = $_SESSION ['USER_LOGGED'];
$aData ['PRO_UID'] = $_SESSION ['PROCESS']; $aData ['APP_STATUS'] = $Fields ['APP_STATUS'];
$aData ['PRO_UID'] = $_SESSION ['PROCESS'];
$oCase->updateCase ( $_SESSION ['APPLICATION'], $aData ); $oCase->updateCase ( $_SESSION ['APPLICATION'], $aData );
//save files //save files
require_once 'classes/model/AppDocument.php'; require_once 'classes/model/AppDocument.php';
if (isset ( $_FILES ['form'] )) { if (isset ( $_FILES ['form'] )) {
foreach ( $_FILES ['form'] ['name'] as $sFieldName => $vValue ) { foreach ( $_FILES ['form'] ['name'] as $sFieldName => $vValue ) {
if ($_FILES ['form'] ['error'] [$sFieldName] == 0) { if ($_FILES ['form'] ['error'] [$sFieldName] == 0) {
$oAppDocument = new AppDocument ( ); $oAppDocument = new AppDocument ( );
if ( isset ( $_POST ['INPUTS'] [$sFieldName] ) && $_POST ['INPUTS'] [$sFieldName] != '' ) {
require_once ('classes/model/AppFolder.php');
if ( isset ( $_POST ['INPUTS'] [$sFieldName] ) && $_POST ['INPUTS'] [$sFieldName] != '' ) {
require_once ('classes/model/AppFolder.php');
require_once ('classes/model/InputDocument.php'); require_once ('classes/model/InputDocument.php');
$oInputDocument = new InputDocument(); $oInputDocument = new InputDocument();
$aID = $oInputDocument->load($_POST ['INPUTS'] [$sFieldName]); $aID = $oInputDocument->load($_POST ['INPUTS'] [$sFieldName]);
//Get the Custom Folder ID (create if necessary) //Get the Custom Folder ID (create if necessary)
$oFolder=new AppFolder(); $oFolder=new AppFolder();
$folderId=$oFolder->createFromPath($aID['INP_DOC_DESTINATION_PATH']); $folderId=$oFolder->createFromPath($aID['INP_DOC_DESTINATION_PATH']);
//Tags //Tags
$fileTags=$oFolder->parseTags($aID['INP_DOC_TAGS']); $fileTags=$oFolder->parseTags($aID['INP_DOC_TAGS']);
$aFields = array ( $aFields = array (
'APP_UID' => $_SESSION ['APPLICATION'], 'APP_UID' => $_SESSION ['APPLICATION'],
'DEL_INDEX' => $_SESSION ['INDEX'], 'DEL_INDEX' => $_SESSION ['INDEX'],
'USR_UID' => $_SESSION ['USER_LOGGED'], 'USR_UID' => $_SESSION ['USER_LOGGED'],
'DOC_UID' => $_POST ['INPUTS'] [$sFieldName], 'DOC_UID' => $_POST ['INPUTS'] [$sFieldName],
'APP_DOC_TYPE' => 'INPUT', 'APP_DOC_TYPE' => 'INPUT',
'APP_DOC_CREATE_DATE' => date ( 'Y-m-d H:i:s' ), 'APP_DOC_CREATE_DATE' => date ( 'Y-m-d H:i:s' ),
'APP_DOC_COMMENT' => '', 'APP_DOC_COMMENT' => '',
'APP_DOC_TITLE' => '', 'APP_DOC_TITLE' => '',
'APP_DOC_FILENAME' => $_FILES ['form'] ['name'] [$sFieldName], 'APP_DOC_FILENAME' => $_FILES ['form'] ['name'] [$sFieldName],
'FOLDER_UID' => $folderId, 'FOLDER_UID' => $folderId,
'APP_DOC_TAGS' => $fileTags 'APP_DOC_TAGS' => $fileTags
); );
} else { }
$aFields = array ( else {
'APP_UID' => $_SESSION ['APPLICATION'], $aFields = array (
'DEL_INDEX' => $_SESSION ['INDEX'], 'APP_UID' => $_SESSION ['APPLICATION'],
'USR_UID' => $_SESSION ['USER_LOGGED'], 'DEL_INDEX' => $_SESSION ['INDEX'],
'DOC_UID' => - 1, 'USR_UID' => $_SESSION ['USER_LOGGED'],
'APP_DOC_TYPE' => 'ATTACHED', 'DOC_UID' => - 1,
'APP_DOC_CREATE_DATE' => date ( 'Y-m-d H:i:s' ), 'APP_DOC_TYPE' => 'ATTACHED',
'APP_DOC_COMMENT' => '', 'APP_DOC_CREATE_DATE' => date ( 'Y-m-d H:i:s' ),
'APP_DOC_TITLE' => '', 'APP_DOC_COMMENT' => '',
'APP_DOC_FILENAME' => $_FILES ['form'] ['name'] [$sFieldName] 'APP_DOC_TITLE' => '',
); 'APP_DOC_FILENAME' => $_FILES ['form'] ['name'] [$sFieldName]
} );
}
$oAppDocument->create ( $aFields );
$iDocVersion = $oAppDocument->getDocVersion(); $oAppDocument->create ( $aFields );
$sAppDocUid = $oAppDocument->getAppDocUid (); $iDocVersion = $oAppDocument->getDocVersion();
$aInfo = pathinfo ( $oAppDocument->getAppDocFilename () ); $sAppDocUid = $oAppDocument->getAppDocUid ();
$sExtension = (isset ( $aInfo ['extension'] ) ? $aInfo ['extension'] : ''); $aInfo = pathinfo ( $oAppDocument->getAppDocFilename () );
$sPathName = PATH_DOCUMENT . $_SESSION ['APPLICATION'] . PATH_SEP; $sExtension = (isset ( $aInfo ['extension'] ) ? $aInfo ['extension'] : '');
$sFileName = $sAppDocUid . '_'.$iDocVersion.'.' . $sExtension; $sPathName = PATH_DOCUMENT . $_SESSION ['APPLICATION'] . PATH_SEP;
G::uploadFile ( $_FILES ['form'] ['tmp_name'] [$sFieldName], $sPathName, $sFileName ); $sFileName = $sAppDocUid . '_'.$iDocVersion.'.' . $sExtension;
//Plugin Hook PM_UPLOAD_DOCUMENT for upload document G::uploadFile ( $_FILES ['form'] ['tmp_name'] [$sFieldName], $sPathName, $sFileName );
$oPluginRegistry = & PMPluginRegistry::getSingleton (); //Plugin Hook PM_UPLOAD_DOCUMENT for upload document
if ($oPluginRegistry->existsTrigger ( PM_UPLOAD_DOCUMENT ) && class_exists ( 'uploadDocumentData' )) { $oPluginRegistry = & PMPluginRegistry::getSingleton ();
$documentData = new uploadDocumentData ( $_SESSION ['APPLICATION'], $_SESSION ['USER_LOGGED'], $sPathName . $sFileName, $aFields ['APP_DOC_FILENAME'], $sAppDocUid ); if ($oPluginRegistry->existsTrigger ( PM_UPLOAD_DOCUMENT ) && class_exists ( 'uploadDocumentData' )) {
$uploadReturn=$oPluginRegistry->executeTriggers ( PM_UPLOAD_DOCUMENT, $documentData ); $documentData = new uploadDocumentData ( $_SESSION ['APPLICATION'], $_SESSION ['USER_LOGGED'], $sPathName . $sFileName, $aFields ['APP_DOC_FILENAME'], $sAppDocUid );
if($uploadReturn){ $uploadReturn=$oPluginRegistry->executeTriggers ( PM_UPLOAD_DOCUMENT, $documentData );
$aFields['APP_DOC_PLUGIN']=$triggerDetail->sNamespace; if($uploadReturn){
$oAppDocument1 = new AppDocument(); $aFields['APP_DOC_PLUGIN']=$triggerDetail->sNamespace;
$oAppDocument1->update($aFields); $oAppDocument1 = new AppDocument();
unlink ( $sPathName . $sFileName ); $oAppDocument1->update($aFields);
} unlink ( $sPathName . $sFileName );
} }
} }
} }
}
}
//go to the next step
$aNextStep = $oCase->getNextStep ( $_SESSION ['PROCESS'], $_SESSION ['APPLICATION'], $_SESSION ['INDEX'], $_SESSION ['STEP_POSITION'] );
if (isset ( $_GET ['_REFRESH_'] )) {
G::header ( 'location: ' . $_SERVER ['HTTP_REFERER'] );
die ();
}
$_SESSION ['STEP_POSITION'] = $aNextStep ['POSITION'];
$_SESSION['BREAKSTEP']['NEXT_STEP'] = $aNextStep ['PAGE'];
if ($trigger_debug_session) {
$_SESSION ['TRIGGER_DEBUG'] ['BREAKPAGE'] = $aNextStep ['PAGE'];
$aNextStep ['PAGE'] = $aNextStep ['PAGE'] . '&breakpoint=triggerdebug';
}
$oForm->validatePost ();
$oJSON = new Services_JSON ( );
$_POST ['__notValidateThisFields__'] = (isset($_POST ['__notValidateThisFields__']) && $_POST ['__notValidateThisFields__']!='')?$_POST ['__notValidateThisFields__']:$_POST ['DynaformRequiredFields'];
if ($missing_req_values = $oForm->validateRequiredFields ( $_POST ['form'], $oJSON->decode ( stripslashes ( $_POST ['__notValidateThisFields__'] ) ) )) {
$_POST ['next_step'] = $aNextStep;
$_POST ['previous_step'] = $oCase->getPreviousStep ( $_SESSION ['PROCESS'], $_SESSION ['APPLICATION'], $_SESSION ['INDEX'], $_SESSION ['STEP_POSITION'] );
$_POST ['req_val'] = $missing_req_values;
$G_PUBLISH = new Publisher ( );
$G_PUBLISH->AddContent ( 'view', 'cases/missRequiredFields' );
G::RenderPage ( 'publish', 'blank' );
exit ( 0 );
}
G::header ( 'location: ' . $aNextStep ['PAGE'] );
} }
//go to the next step catch(Exception $e) {
$aNextStep = $oCase->getNextStep ( $_SESSION ['PROCESS'], $_SESSION ['APPLICATION'], $_SESSION ['INDEX'], $_SESSION ['STEP_POSITION'] );
if (isset ( $_GET ['_REFRESH_'] )) {
G::header ( 'location: ' . $_SERVER ['HTTP_REFERER'] );
die ();
}
$_SESSION ['STEP_POSITION'] = $aNextStep ['POSITION'];
$_SESSION['BREAKSTEP']['NEXT_STEP'] = $aNextStep ['PAGE'];
if ($trigger_debug_session) {
$_SESSION ['TRIGGER_DEBUG'] ['BREAKPAGE'] = $aNextStep ['PAGE'];
$aNextStep ['PAGE'] = $aNextStep ['PAGE'] . '&breakpoint=triggerdebug';
}
$oForm->validatePost ();
$oJSON = new Services_JSON ( );
$_POST ['__notValidateThisFields__'] = (isset($_POST ['__notValidateThisFields__']) && $_POST ['__notValidateThisFields__']!='')?$_POST ['__notValidateThisFields__']:$_POST ['DynaformRequiredFields'];
if ($missing_req_values = $oForm->validateRequiredFields ( $_POST ['form'], $oJSON->decode ( stripslashes ( $_POST ['__notValidateThisFields__'] ) ) )) {
$_POST ['next_step'] = $aNextStep;
$_POST ['previous_step'] = $oCase->getPreviousStep ( $_SESSION ['PROCESS'], $_SESSION ['APPLICATION'], $_SESSION ['INDEX'], $_SESSION ['STEP_POSITION'] );
$_POST ['req_val'] = $missing_req_values;
$G_PUBLISH = new Publisher ( );
$G_PUBLISH->AddContent ( 'view', 'cases/missRequiredFields' );
G::RenderPage ( 'publish', 'blank' );
exit ( 0 );
}
G::header ( 'location: ' . $aNextStep ['PAGE'] );
$G_PUBLISH = new Publisher;
$aMessage = array();
$aMessage['MESSAGE'] = $e->getMessage();
$G_PUBLISH->AddContent('xmlform', 'xmlform', 'login/showMessage', '', $aMessage );
G::RenderPage( 'publish', 'blank' );
die;
}

View File

@@ -218,7 +218,7 @@ $uidf=$_GET['UID'];
$oDbConnections->loadAdditionalConnections(); $oDbConnections->loadAdditionalConnections();
$_SESSION['CURRENT_DYN_UID'] = $_GET['UID']; $_SESSION['CURRENT_DYN_UID'] = $_GET['UID'];
$G_PUBLISH->AddContent('dynaform', 'xmlform', $_SESSION['PROCESS']. '/' . $_GET['UID'], '', $Fields['APP_DATA'], 'cases_SaveData?UID=' . $_GET['UID'], '', (strtolower($oStep->getStepMode()) != 'edit' ? strtolower($oStep->getStepMode()) : '')); $G_PUBLISH->AddContent('dynaform', 'xmlform', $_SESSION['PROCESS']. '/' . $_GET['UID'], '', $Fields['APP_DATA'], 'cases_SaveData?UID=' . $_GET['UID'] . '&APP_UID=' . $_SESSION['APPLICATION'], '', (strtolower($oStep->getStepMode()) != 'edit' ? strtolower($oStep->getStepMode()) : ''));
break; break;
case 'INPUT_DOCUMENT': case 'INPUT_DOCUMENT':