i’m trying to set a dynamic list of choices in workflow transition form.
I have an entity for example FunnelCloseReason who is a list (name, label) of possible reasons.
I want to set that list in choices list of workflow/transitions.yml file :YAML12345678910111213141516171819workflows:funnel_workflow_processing:transitions:close:label: 'Fermer'step_to: contactedfrontend_options:icon: 'icon-trash'class: 'btn-danger'form_options:attribute_fields:close_reason_name:form_type: choiceoptions:required: trueempty_value: falsechoices: @funnel_close_reason.provider->getChoicesconstraints:- NotBlank: ~
@funnel_close_reason.provider is defined in services.yml
But I have an error :
Uncaught PHP Exception Symfony\Component\OptionsResolver\Exception\InvalidOptionsException: “The option “choices” with value “@funnel_close_reason.provider->getChoices” is expected to be of type “null” or “array” or “\Traversable”, but is of type “string”.”
You must be logged in to reply to this topic.