Skip to content

PHPMentorsWorkflowerBundle 1.2.0 (stable)

Choose a tag to compare

@iteman iteman released this 31 Oct 05:59
· 27 commits to master since this release
v1.2.0

Release Date: 2016-10-31 UTC

What's New in PHPMentorsWorkflowerBundle 1.2.0

Service Task support

(@iteman, Issue #8)

Service Tasks have been supported. When a Service Task is reached in the process, the task will be allocated and started automatically, and the associated Symfony service is executed at the started state on the work item. And the task will be completed automatically.

Symfony services for this must implement PHPMentors\Workflower\Workflow\Operation\OperationRunnerInterface as the following:

<?php
// ...
use PHPMentors\Workflower\Workflow\Operation\OperationalInterface;
use PHPMentors\Workflower\Workflow\Operation\OperationRunnerInterface;
use PHPMentors\Workflower\Workflow\Workflow;

class FooOperationRunner implements OperationRunnerInterface
{
    /**
     * {@inheritdoc}
     */
    public function provideParticipant(OperationalInterface $operational, Workflow $workflow)
    {
        // ...
    }

    /**
     * {@inheritdoc}
     */
    public function run(OperationalInterface $operational, Workflow $workflow)
    {
        // ...
    }
}

See also the release notes for Workflower 1.2.0 for BPMN definitions of Service Tasks.