@@ -48,8 +48,7 @@ |
||
48 | 48 | $real = $request->getRequestUri(); |
49 | 49 | |
50 | 50 | $expected = 'homepage' == $page->getSlug() ? |
51 | - $this->get('piedweb.page_canonical')->generatePathForHomepage() : |
|
52 | - $this->get('piedweb.page_canonical')->generatePathForPage($page->getRealSlug()) |
|
51 | + $this->get('piedweb.page_canonical')->generatePathForHomepage() : $this->get('piedweb.page_canonical')->generatePathForPage($page->getRealSlug()) |
|
53 | 52 | ; |
54 | 53 | |
55 | 54 | if ($real != $expected) { |
@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | 'to_string_callback' => function ($entity) { |
160 | 160 | return $entity->getQuestion(); |
161 | 161 | }, |
162 | - ]); |
|
162 | + ]); |
|
163 | 163 | } |
164 | 164 | |
165 | 165 | //var_dump($this->getContainer()->getParameter('app.entity_page')); exit; |
@@ -217,7 +217,7 @@ discard block |
||
217 | 217 | 'choices' => [ |
218 | 218 | 'admin.page.metaRobots.choice.noIndex' => 'no-index, no-follow', |
219 | 219 | ], |
220 | - 'label' => 'admin.page.metaRobots.label', |
|
220 | + 'label' => 'admin.page.metaRobots.label', |
|
221 | 221 | 'required' => false, |
222 | 222 | ]); |
223 | 223 | } |
@@ -236,16 +236,16 @@ discard block |
||
236 | 236 | |
237 | 237 | if ($this->exists('author')) { |
238 | 238 | $formMapper->add('author', EntityType::class, [ |
239 | - 'label' => 'admin.page.author.label', |
|
240 | - 'class' => $this->getContainer()->getParameter('app.entity_user'), 'label' => 'Auteur', |
|
241 | - 'required' => false, |
|
239 | + 'label' => 'admin.page.author.label', |
|
240 | + 'class' => $this->getContainer()->getParameter('app.entity_user'), 'label' => 'Auteur', |
|
241 | + 'required' => false, |
|
242 | 242 | ]); |
243 | 243 | } |
244 | 244 | |
245 | 245 | if ($this->exists('template')) { |
246 | 246 | $formMapper->add('template', null, [ |
247 | - 'label' => 'admin.page.template.label', |
|
248 | - 'required' => false, |
|
247 | + 'label' => 'admin.page.template.label', |
|
248 | + 'required' => false, |
|
249 | 249 | ]); |
250 | 250 | } |
251 | 251 | |
@@ -292,9 +292,9 @@ discard block |
||
292 | 292 | |
293 | 293 | if ($this->exists('author')) { |
294 | 294 | $formMapper->add('author', null, [ |
295 | - 'label' => 'admin.page.author.label', |
|
296 | - 'class' => $this->getContainer()->getParameter('app.entity_user'), |
|
297 | - 'required' => false, |
|
295 | + 'label' => 'admin.page.author.label', |
|
296 | + 'class' => $this->getContainer()->getParameter('app.entity_user'), |
|
297 | + 'required' => false, |
|
298 | 298 | ]); |
299 | 299 | } |
300 | 300 | } |
@@ -156,7 +156,7 @@ discard block |
||
156 | 156 | 'property' => 'question', // or any field in your media entity |
157 | 157 | 'label' => 'admin.page.faq.label', |
158 | 158 | 'btn_add' => true, |
159 | - 'to_string_callback' => function ($entity) { |
|
159 | + 'to_string_callback' => function($entity) { |
|
160 | 160 | return $entity->getQuestion(); |
161 | 161 | }, |
162 | 162 | ]); |
@@ -174,7 +174,7 @@ discard block |
||
174 | 174 | 'property' => 'title', // or any field in your media entity |
175 | 175 | 'label' => 'admin.page.relatedPage.label', |
176 | 176 | 'btn_add' => false, |
177 | - 'to_string_callback' => function ($entity) { |
|
177 | + 'to_string_callback' => function($entity) { |
|
178 | 178 | return $entity->getTitle(); |
179 | 179 | }, |
180 | 180 | ] |