Skip to content

Commit 40fbaf3

Browse files
committed
Update arrays to use short syntax
1 parent ea64992 commit 40fbaf3

File tree

1 file changed

+28
-27
lines changed

1 file changed

+28
-27
lines changed

workflow/usage.rst

Lines changed: 28 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ like this:
164164
]);
165165
166166
As configured, the following property is used by the marking store::
167+
.. code-block:: php
167168
168169
class BlogPost
169170
{
@@ -620,34 +621,34 @@ requires:
620621
621622
// config/packages/workflow.php
622623
623-
$container->loadFromExtension('framework', array(
624+
$container->loadFromExtension('framework', [
625+
// ...
626+
'workflows' => [
627+
'blog_publishing' => [
628+
'metadata' => [
629+
'title' => 'Blog Publishing Workflow',
630+
],
624631
// ...
625-
'workflows' => array(
626-
'blog_publishing' => array(
627-
'metadata' => array(
628-
'title' => 'Blog Publishing Workflow',
629-
),
630-
// ...
631-
'places' => array(
632-
'draft' => array(
633-
'metadata' => array(
634-
'max_num_of_words' => 500,
635-
),
636-
),
637-
// ...
638-
),
639-
'transitions' => array(
640-
'to_review' => array(
641-
'from' => 'draft',
642-
'to' => 'review',
643-
'metadata' => array(
644-
'priority' => 0.5,
645-
),
646-
),
647-
),
648-
),
649-
),
650-
));
632+
'places' => [
633+
'draft' => [
634+
'metadata' => [
635+
'max_num_of_words' => 500,
636+
],
637+
],
638+
// ...
639+
],
640+
'transitions' => [
641+
'to_review' => [
642+
'from' => 'draft',
643+
'to' => 'review',
644+
'metadata' => [
645+
'priority' => 0.5,
646+
],
647+
],
648+
],
649+
],
650+
],
651+
]);
651652

652653
Then you can access this metadata in your controller as follows::
653654

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy