Se modifica la funcionalidad de start event para Case Scheduler y Web Entry (add)
This commit is contained in:
@@ -308,15 +308,16 @@ class BpmnWorkflow extends Project\Bpmn
|
|||||||
|
|
||||||
$eventUid = parent::addEvent($data);
|
$eventUid = parent::addEvent($data);
|
||||||
$event = \BpmnEventPeer::retrieveByPK($eventUid);
|
$event = \BpmnEventPeer::retrieveByPK($eventUid);
|
||||||
|
$prj_uid = $event->getPrjUid();
|
||||||
|
|
||||||
// create case scheduler
|
// create case scheduler
|
||||||
if ($event->getEvnMarker() == "TIMER") {
|
if ($event->getEvnMarker() == "TIMER") {
|
||||||
$this->wp->addCaseScheduler();
|
$this->wp->addCaseScheduler($eventUid, $prj_uid);
|
||||||
}
|
}
|
||||||
|
|
||||||
// create web entry
|
// create web entry
|
||||||
if ($event->getEvnMarker() == "MESSAGE") {
|
if ($event->getEvnMarker() == "MESSAGE") {
|
||||||
$this->wp->addWebEntry();
|
$this->wp->addWebEntry($eventUid, $prj_uid);
|
||||||
}
|
}
|
||||||
|
|
||||||
//return parent::addEvent($data);
|
//return parent::addEvent($data);
|
||||||
|
|||||||
@@ -775,7 +775,7 @@ class Workflow extends Handler
|
|||||||
$this->update(array("PRO_STATUS" => $status));
|
$this->update(array("PRO_STATUS" => $status));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function addCaseScheduler()
|
public function addCaseScheduler($eventUid, $prj_uid)
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
$caseScheduler = new \CaseScheduler();
|
$caseScheduler = new \CaseScheduler();
|
||||||
@@ -783,7 +783,7 @@ class Workflow extends Handler
|
|||||||
'SCH_NAME'=>'',
|
'SCH_NAME'=>'',
|
||||||
'SCH_DEL_USER_NAME'=>'',
|
'SCH_DEL_USER_NAME'=>'',
|
||||||
'SCH_DEL_USER_UID'=>'',
|
'SCH_DEL_USER_UID'=>'',
|
||||||
'PRO_UID'=>'',
|
'PRO_UID'=>$prj_uid,
|
||||||
'TAS_UID'=>'',
|
'TAS_UID'=>'',
|
||||||
'SCH_TIME_NEXT_RUN'=>date('Y-m-d H:i:s'),
|
'SCH_TIME_NEXT_RUN'=>date('Y-m-d H:i:s'),
|
||||||
'SCH_LAST_RUN_TIME'=>NULL,
|
'SCH_LAST_RUN_TIME'=>NULL,
|
||||||
@@ -805,7 +805,7 @@ class Workflow extends Handler
|
|||||||
'SCH_REPEAT_STOP_IF_RUNNING'=>'',
|
'SCH_REPEAT_STOP_IF_RUNNING'=>'',
|
||||||
'CASE_SH_PLUGIN_UID'=>NULL,
|
'CASE_SH_PLUGIN_UID'=>NULL,
|
||||||
'SCH_DEL_USER_PASS'=>'',
|
'SCH_DEL_USER_PASS'=>'',
|
||||||
'SCH_UID'=>Common::generateUID(),
|
'SCH_UID'=>$eventUid,
|
||||||
'SCH_REPEAT_UNTIL'=>''
|
'SCH_REPEAT_UNTIL'=>''
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -837,12 +837,13 @@ class Workflow extends Handler
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function addWebEntry()
|
public function addWebEntry($eventUid, $prj_uid)
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
$webEntry = new \WebEntry();
|
$webEntry = new \WebEntry();
|
||||||
$webEntryUid = Common::generateUID();
|
$webEntryUid = $eventUid;
|
||||||
$webEntry->setWeUid($webEntryUid);
|
$webEntry->setWeUid($webEntryUid);
|
||||||
|
$webEntry->setProUid($prj_uid);
|
||||||
$webEntry->setWeMethod('');
|
$webEntry->setWeMethod('');
|
||||||
$webEntry->setWeCreateDate(date('Y-m-d H:i:s'));
|
$webEntry->setWeCreateDate(date('Y-m-d H:i:s'));
|
||||||
$webEntry->save();
|
$webEntry->save();
|
||||||
|
|||||||
Reference in New Issue
Block a user