Skip to content

Commit 65d8b66

Browse files
committed
BAP-13894: Cron scheduled workflow transitions are not working
- CR Fixes
1 parent fdb1ce0 commit 65d8b66

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/Oro/Bundle/CronBundle/Command/CronCommand.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,23 +81,23 @@ protected function execute(InputInterface $input, OutputInterface $output)
8181
}
8282

8383
/**
84+
* Convert command arguments to options. It needed for correctly pass this arguments into ArrayInput:
85+
* new ArrayInput(['name' => 'foo', '--bar' => 'foobar']);
86+
*
8487
* @param array $commandOptions
8588
* @return array
8689
*/
8790
protected function resolveOptions(array $commandOptions)
8891
{
8992
$options = [];
90-
9193
foreach ($commandOptions as $key => $option) {
9294
$params = explode('=', $option, 2);
93-
9495
if (is_array($params) && count($params) === 2) {
9596
$options[$params[0]] = $params[1];
9697
} else {
9798
$options[$key] = $option;
9899
}
99100
}
100-
101101
return $options;
102102
}
103103

src/Oro/Bundle/WorkflowBundle/Command/HandleTransitionCronTriggerCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@
44

55
use Doctrine\Common\Persistence\ObjectRepository;
66

7-
use Oro\Bundle\CronBundle\Command\CronCommandInterface;
87
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
98
use Symfony\Component\Console\Input\InputInterface;
109
use Symfony\Component\Console\Input\InputOption;
1110
use Symfony\Component\Console\Output\OutputInterface;
1211

12+
use Oro\Bundle\CronBundle\Command\CronCommandInterface;
1313
use Oro\Bundle\WorkflowBundle\Async\TransitionTriggerMessage;
1414
use Oro\Bundle\WorkflowBundle\Async\TransitionTriggerProcessor;
1515
use Oro\Bundle\WorkflowBundle\Entity\TransitionCronTrigger;

0 commit comments

Comments
 (0)