Merged in cochalo/processmaker/PM-1339 (pull request #2025)
PM-1339 No se puede ordenar las condiciones de enrutamiento del gateway Exclusive
This commit is contained in:
@@ -1348,13 +1348,15 @@ class Bpmn extends Handler
|
||||
$oCriteria->add( \BpmnFlowPeer::FLO_POSITION, $iPosition, '>' );
|
||||
$oDataset = \BpmnFlowPeer::doSelectRS( $oCriteria );
|
||||
$oDataset->setFetchmode( ResultSet::FETCHMODE_ASSOC );
|
||||
$oDataset->next();
|
||||
$aRow = $oDataset->getRow();
|
||||
$oCriteria2 = new Criteria('workflow');
|
||||
$oCriteria2->add( \BpmnFlowPeer::FLO_POSITION, $aRow['FLO_POSITION'] - 1);
|
||||
BasePeer::doUpdate($oCriteria, $oCriteria2, $con);
|
||||
$oDataset->next();
|
||||
|
||||
while ($oDataset->next()) {
|
||||
$aRow = $oDataset->getRow();
|
||||
$newPosition = ((int)$aRow['FLO_POSITION'])-1;
|
||||
$oCriteriaTemp = new Criteria( 'workflow' );
|
||||
$oCriteriaTemp->add( \BpmnFlowPeer::FLO_UID, $aRow['FLO_UID'] );
|
||||
$oCriteria2 = new Criteria('workflow');
|
||||
$oCriteria2->add(\BpmnFlowPeer::FLO_POSITION, $newPosition);
|
||||
BasePeer::doUpdate($oCriteriaTemp, $oCriteria2, $con);
|
||||
}
|
||||
} catch (Exception $oException) {
|
||||
throw $oException;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user