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;
         }