This repository was archived by the owner on Sep 16, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -478,8 +478,10 @@ follows::
478
478
$content = new StaticContent();
479
479
$content->setParentDocument($dm->find(null, '/cms/content'));
480
480
$content->setName('my-content');
481
+ $content->setTitle('My Content');
482
+ $content->setBody('Some Content');
481
483
$dm->persist($content);
482
- $route->setRouteContent ($content);
484
+ $route->setContent ($content);
483
485
484
486
// now define an id parameter; do not forget the leading slash if you
485
487
// want /projects/{id} and not /projects{id}
@@ -505,7 +507,7 @@ also ``/projects`` as there is a default for the id parameter.
505
507
doing it in a fixture like this).
506
508
507
509
Because you defined the ``{id} `` route parameter, your controller can expect an
508
- ``$id `` parameter. Additionally, because you called setRouteContent on the
510
+ ``$id `` parameter. Additionally, because you called `` setContent `` on the
509
511
route, your controller can expect the ``$contentDocument `` parameter.
510
512
The content could be used to define an intro section that is the same for each
511
513
project or other shared data. If you don't need content, you can just not set it
You can’t perform that action at this time.
0 commit comments