Espinoza Guillermo 6 年之前
父节点
当前提交
fee1244bc5
共有 2 个文件被更改,包括 6 次插入1 次删除
  1. 4 1
      Command/WorkflowApplyCommand.php
  2. 2 0
      Services/TaskLoggerService.php

+ 4 - 1
Command/WorkflowApplyCommand.php

@@ -96,7 +96,10 @@ class WorkflowApplyCommand extends ContainerAwareCommand
         }, $wf->getEnabledTransitions($entity));
         
         if (!in_array($transition, $transitions)) {
-            throw new \Exception ("Can't apply transition '$transition', only allowed transitions for this entity are '". implode("','", $transitions). "'");
+            // throw new \Exception ("Can't apply transition '$transition', only allowed transitions for this entity are '". implode("','", $transitions). "'");
+            $output->writeln("Can't apply transition '$transition', only allowed transitions for this entity are '". implode("','", $transitions). "'");
+            
+            return;
         }
         
         $from = array_keys($wf->getMarking($entity)->getPlaces());

+ 2 - 0
Services/TaskLoggerService.php

@@ -56,7 +56,9 @@ class TaskLoggerService implements ConsumerInterface
                 ]);
             }
             
+            echo PHP_EOL . PHP_EOL;
             var_export($output);
+            echo PHP_EOL . PHP_EOL;
 
             return true;
         }