@@ -663,7 +663,7 @@ of domain logic in your templates:
663
663
664
664
``workflow_has_marked_place() ``
665
665
Returns ``true `` if the marking of the given object has the given state.
666
-
666
+
667
667
``workflow_transition_blockers() ``
668
668
Returns :class: `Symfony\\ Component\\ Workflow\\ TransitionBlockerList ` for the given transition.
669
669
@@ -698,7 +698,7 @@ The following example shows these functions in action:
698
698
{% if 'reviewed' in workflow_marked_places(post) %}
699
699
<span class="label">Reviewed</span>
700
700
{% endif %}
701
-
701
+
702
702
{# Loop through the transition blockers #}
703
703
{% for blocker in workflow_transition_blockers(post, 'publish') %}
704
704
<span class="error">{{ blocker.message }}</span>
@@ -858,13 +858,13 @@ Then you can access this metadata in your controller as follows::
858
858
859
859
There is a ``getMetadata() `` method that works with all kinds of metadata::
860
860
861
- // pass a string (the key of workflow metadata) to getMetadata() to get "workflow metadata" by key
861
+ // get "workflow metadata" passing the metadata key as argument
862
862
$title = $workflow->getMetadataStore()->getMetadata('title');
863
863
864
- // pass two arguments: a string ( the key of place metadata) and a string ( the place name) to getMetadata() to get "place metadata" by key
864
+ // get "place metadata" passing the metadata key as the first argument and the place name as the second argument
865
865
$maxNumOfWords = $workflow->getMetadataStore()->getMetadata('max_num_of_words', 'draft');
866
866
867
- // pass two arguments: a string ( the key of transition metadata) and a Transition object to getMetadata() to get "transition metadata" by key
867
+ // get "transition metadata" passing the metadata key as the first argument and a Transition object as the second argument
868
868
$priority = $workflow->getMetadataStore()->getMetadata('priority', $aTransition);
869
869
870
870
In a :ref: `flash message <flash-messages >` in your controller::
0 commit comments