Skip to content

Commit 8d326cb

Browse files
committed
[Workflow] Mention that the initial marking is configured, not set in code
1 parent fdb2407 commit 8d326cb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

workflow.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,9 @@ The configured property will be used via its implemented getter/setter methods b
189189
{
190190
$this->currentPlace = $currentPlace;
191191
}
192+
193+
// you don't need to set the initial marking in the constructor or any other method;
194+
// this is configured in the workflow with the 'initial_marking' option
192195
}
193196

194197
.. note::
@@ -225,6 +228,8 @@ what actions are allowed on a blog post::
225228
use Symfony\Component\Workflow\Exception\LogicException;
226229

227230
$post = new BlogPost();
231+
// you don't need to set the initial marking with code; this is configured
232+
// in the workflow with the 'initial_marking' option
228233

229234
$workflow = $this->container->get('workflow.blog_publishing');
230235
$workflow->can($post, 'publish'); // False

0 commit comments

Comments
 (0)