PM-939 "Support for Message-Event (Running case & Message-Event CRON)"

- Se a implementado el Running case
- Se a implementado el Message-Event CRON:
  Para ejecutar el Message-Event CRON, ejecute el siguiente comando:
        /path/to/processmaker/workflow/engine/bin$ php -f messageeventcron.php +wMyWorkspace
Nota.- Para el correcto funcionamiento del proceso y de esta nueva funcionalidad
       se debera crear el proceso nuevamente (esta nueva funcionalidad
       no funcionara con procesos BPMN antiguos a la fecha de este commit)
This commit is contained in:
Victor Saisa Lopez
2015-02-21 15:59:12 -04:00
parent 085805d55a
commit b2f095f036
15 changed files with 1070 additions and 52 deletions

View File

@@ -322,7 +322,11 @@ class MessageEventRelation
$criteria = new \Criteria("workflow");
foreach ($arrayCondition as $key => $value) {
$criteria->add($key, $value, \Criteria::EQUAL);
if (is_array($value)) {
$criteria->add($key, $value[0], $value[1]);
} else {
$criteria->add($key, $value, \Criteria::EQUAL);
}
}
$result = \MessageEventRelationPeer::doDelete($criteria);
@@ -404,5 +408,44 @@ class MessageEventRelation
throw $e;
}
}
/**
* Get data of a Message-Event-Relation
*
* @param array $arrayCondition Conditions
* @param bool $flagGetRecord Value that set the getting
*
* return array Return an array with data of a Message-Event-Relation, otherwise null
*/
public function getMessageEventRelationWhere(array $arrayCondition, $flagGetRecord = false)
{
try {
//Get data
$criteria = $this->getMessageEventRelationCriteria();
foreach ($arrayCondition as $key => $value) {
if (is_array($value)) {
$criteria->add($key, $value[0], $value[1]);
} else {
$criteria->add($key, $value, \Criteria::EQUAL);
}
}
$rsCriteria = \MessageEventRelationPeer::doSelectRS($criteria);
$rsCriteria->setFetchmode(\ResultSet::FETCHMODE_ASSOC);
if ($rsCriteria->next()) {
$row = $rsCriteria->getRow();
//Return
return (!$flagGetRecord)? $this->getMessageEventRelationDataFromRecord($row) : $row;
} else {
//Return
return null;
}
} catch (\Exception $e) {
throw $e;
}
}
}