Closed tonyellow closed 2 years ago
Did you had a look to the "workflow_name"
option of the extension constructor in README ?
When you have multiple workflow on your entities, you cannot register a global extension. You have to register the extension as many time as you want fore each workflow you want to cover.
Let say you have 2 workflow for your PullRequest entity (workflow_a
& workflow_b
), you will end with something like :
admin.extension.pull_request_workflow.workflow_a:
class: Yokai\SonataWorkflow\Admin\Extension\WorkflowExtension
public: true
arguments:
- '@workflow.registry'
- workflow_name: workflow_a
admin.extension.pull_request_workflow.workflow_b:
class: Yokai\SonataWorkflow\Admin\Extension\WorkflowExtension
public: true
arguments:
- '@workflow.registry'
- workflow_name: workflow_b
sonata_admin:
extensions:
admin.extension.pull_request_workflow.workflow_a:
admins:
- admin.pull_request
admin.extension.pull_request_workflow.workflow_b:
admins:
- admin.pull_request
Considering the issues as answered
I have multiple workflows configured for some entities. Symfony 4 has support for it, this plugin does not, is that correct? I can not find a way to pass a specific workflow to this manager. Thanks in advance!