Parallel with Subprocess Asyncrono

R-982
Parallel with Subprocess Asyncrono
This commit is contained in:
Dheeyi William
2016-06-14 10:46:34 -04:00
parent d541f4d583
commit 4491d70e63
2 changed files with 57 additions and 46 deletions

View File

@@ -1358,6 +1358,7 @@ class Derivation
$appFields["APP_FINISH_DATE"] = "now";
$this->verifyIsCaseChild($currentDelegation["APP_UID"], $currentDelegation["DEL_INDEX"]);
$flag = true;
}
if (isset( $iNewDelIndex )) {
@@ -1525,7 +1526,17 @@ class Derivation
}
$currentDelegation2 = array('APP_UID' => $currentDelegation['APP_UID'], 'DEL_INDEX' => $iNewDelIndex, 'APP_STATUS' => 'TO_DO', 'TAS_UID' => $currentDelegation['TAS_UID'], 'ROU_TYPE' => $aDeriveTasks[1]['ROU_TYPE']
);
$openThreads = 0;
if ($currentDelegation2['ROU_TYPE'] == 'SEC-JOIN') {
$openThreads = $this->case->GetOpenThreads($currentDelegation['APP_UID']);
}
if ($openThreads == 0) {
$this->derivate($currentDelegation2, $nextDelegations2);
} else {
$oSubApplication = new SubApplication();
$aSubApplication['SA_STATUS'] = 'ACTIVE';
$oSubApplication->update($aSubApplication);
}
}
}
}
@@ -1558,7 +1569,7 @@ class Derivation
$oDataset->setFetchmode( ResultSet::FETCHMODE_ASSOC );
$oDataset->next();
$aSP = $oDataset->getRow();
if ($aSP['SP_SYNCHRONOUS'] == 1) {
if ($aSP['SP_SYNCHRONOUS'] == 1 || $aSA['SA_STATUS'] == "ACTIVE") {
$appFields = $oCase->loadCase($sApplicationUID, $delIndex);
//Copy case variables to parent case
$aFields = unserialize($aSP['SP_VARIABLES_IN']);