diff --git a/workflow/engine/methods/setup/clearCompiledAjax.php b/workflow/engine/methods/setup/clearCompiledAjax.php index d665b64d8..ccbabcf28 100644 --- a/workflow/engine/methods/setup/clearCompiledAjax.php +++ b/workflow/engine/methods/setup/clearCompiledAjax.php @@ -3,23 +3,63 @@ try { $response = new stdClass; if (isset( $_POST['javascriptCache'] ) || isset( $_POST['metadataCache'] ) || isset( $_POST['htmlCache'] )) { - $msgLog = ''; - if (isset( $_POST['javascriptCache'] )) { - G::rm_dir( PATH_C . 'ExtJs' ); + $msgLog = ""; + $msgLogAux = ""; + + if (isset($_POST["javascriptCache"])) { + G::rm_dir(PATH_C . "ExtJs"); $response->javascript = true; - $msgLog .= 'Javascript cache '; - } - if (isset( $_POST['metadataCache'] )) { - G::rm_dir( PATH_C . 'xmlform' ); - $response->xmlform = true; - $msgLog .= 'Forms Metadata cache '; - } + $msgLog = $msgLog . "Javascript Cache"; - if (isset( $_POST['htmlCache'] )) { - G::rm_dir( PATH_C . 'smarty' ); - $response->smarty = true; - $msgLog .= 'Forms Html Templates cache '; + if (isset($_POST["metadataCache"])) { + G::rm_dir(PATH_C . "xmlform"); + $response->xmlform = true; + + $msgLogAux = $msgLog; + $msgLog = $msgLog . ", Forms Metadata Cache"; + + if (isset($_POST["htmlCache"])) { + G::rm_dir(PATH_C . "smarty"); + $response->smarty = true; + + $msgLog = $msgLog . " and Forms Html Templates Cache."; + } else { + $msgLog = $msgLogAux ." and Forms Metadata Cache."; + } + } else { + if (isset($_POST["htmlCache"])) { + G::rm_dir(PATH_C . "smarty"); + $response->smarty = true; + + $msgLog = $msgLog . " and Forms Html Templates Cache."; + } else { + $msgLog = $msgLog . "."; + } + } + } else { + if (isset($_POST["metadataCache"])) { + G::rm_dir(PATH_C . "xmlform"); + $response->xmlform = true; + + $msgLog = $msgLog . "Forms Metadata Cache"; + + if (isset($_POST["htmlCache"])) { + G::rm_dir(PATH_C . "smarty"); + $response->smarty = true; + + $msgLog = $msgLog . " and Forms Html Templates Cache."; + } else { + $msgLog = $msgLog . "."; + } + } else { + if (isset($_POST["htmlCache"])) { + G::rm_dir(PATH_C . "smarty"); + $response->smarty = true; + + $msgLog = $msgLog . "Forms Html Templates Cache."; + } + } } $response->success = true; diff --git a/workflow/engine/methods/triggers/triggers_Edit.php b/workflow/engine/methods/triggers/triggers_Edit.php index a5a34e361..8358f5b5e 100755 --- a/workflow/engine/methods/triggers/triggers_Edit.php +++ b/workflow/engine/methods/triggers/triggers_Edit.php @@ -46,6 +46,7 @@ if (isset( $_GET['TRI_UID'] )) { $ST_TYPE = isset($_GET['ST_TYPE'])?$_GET['ST_TYPE']:''; $_GET = $aTriggerData['params']; $_GET['TRI_UID'] = $triUid; + $_GET['PRO_UID'] = $aFields['PRO_UID']; $_GET['STEP_UID']=$STEP_UID; $_GET['ST_TYPE']=$ST_TYPE; require_once ('triggers_EditWizard.php');