Completed
Push — master ( 74410c...455573 )
by Dev
06:45 queued 03:15
created
src/Controller/PageController.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -48,8 +48,7 @@
 block discarded – undo
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) {
Please login to merge, or discard this patch.
src/Admin/PageAdmin.php 2 patches
Indentation   +31 added lines, -31 removed lines patch added patch discarded remove patch
@@ -140,30 +140,30 @@  discard block
 block discarded – undo
140 140
         if (method_exists($this->getConfigurationPool()->getContainer()->getParameter('app.entity_page'), 'getfaq')) {
141 141
             $formMapper->add('faq', ModelAutocompleteType::class, [
142 142
                 'required' => false,
143
-                 'multiple' => true,
144
-                 'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_faq'),
145
-                 'property' => 'question',   // or any field in your media entity
146
-                 'label' => 'admin.page.faq.label',
147
-                 'btn_add' => true,
148
-                 'to_string_callback' => function ($entity) {//, $property) {
149
-                     return $entity->getQuestion();
150
-                 },
151
-             ]);
143
+                    'multiple' => true,
144
+                    'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_faq'),
145
+                    'property' => 'question',   // or any field in your media entity
146
+                    'label' => 'admin.page.faq.label',
147
+                    'btn_add' => true,
148
+                    'to_string_callback' => function ($entity) {//, $property) {
149
+                        return $entity->getQuestion();
150
+                    },
151
+                ]);
152 152
         }
153 153
 
154 154
         //var_dump($this->getConfigurationPool()->getContainer()->getParameter('app.entity_page')); exit;
155 155
         if (method_exists($this->getConfigurationPool()->getContainer()->getParameter('app.entity_page'), 'getrelatedPages')) {
156 156
             $formMapper->add('relatedPages', ModelAutocompleteType::class, [
157 157
                 'required' => false,
158
-                 'multiple' => true,
159
-                 'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_page'),
160
-                 'property' => 'title',   // or any field in your media entity
161
-                 'label' => 'admin.page.relatedPage.label',
162
-                 'btn_add' => false,
163
-                 'to_string_callback' => function ($entity) { //, $property) {
164
-                     return $entity->getTitle();
165
-                 },
166
-             ]);
158
+                    'multiple' => true,
159
+                    'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_page'),
160
+                    'property' => 'title',   // or any field in your media entity
161
+                    'label' => 'admin.page.relatedPage.label',
162
+                    'btn_add' => false,
163
+                    'to_string_callback' => function ($entity) { //, $property) {
164
+                        return $entity->getTitle();
165
+                    },
166
+                ]);
167 167
         }
168 168
         $formMapper->end();
169 169
 
@@ -199,7 +199,7 @@  discard block
 block discarded – undo
199 199
             'choices' => [
200 200
                 'admin.page.metaRobots.choice.noIndex' => 'no-index, no-follow',
201 201
             ],
202
-             'label' => 'admin.page.metaRobots.label',
202
+                'label' => 'admin.page.metaRobots.label',
203 203
             'required' => false,
204 204
         ]);
205 205
         }
@@ -213,7 +213,7 @@  discard block
 block discarded – undo
213 213
             'dp_calendar_weeks' => false,
214 214
             'dp_view_mode' => 'days',
215 215
             'dp_min_view_mode' => 'days',
216
-             'label' => 'admin.page.createdAt.label',
216
+                'label' => 'admin.page.createdAt.label',
217 217
         ]);
218 218
         $formMapper->add('updatedAt', DateTimePickerType::class, [
219 219
             //'date_format' => 'd MMMM y H:mm',
@@ -225,21 +225,21 @@  discard block
 block discarded – undo
225 225
             'dp_calendar_weeks' => false,
226 226
             'dp_view_mode' => 'days',
227 227
             'dp_min_view_mode' => 'days',
228
-             'label' => 'admin.page.updatedAt.label',
228
+                'label' => 'admin.page.updatedAt.label',
229 229
         ]);
230 230
 
231 231
         if (method_exists($this->getConfigurationPool()->getContainer()->getParameter('app.entity_page'), 'getauthor')) {
232 232
             $formMapper->add('author', EntityType::class, [
233
-             'label' => 'admin.page.author.label',
234
-             'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_user'), 'label' => 'Auteur',
235
-             'required' => false,
233
+                'label' => 'admin.page.author.label',
234
+                'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_user'), 'label' => 'Auteur',
235
+                'required' => false,
236 236
         ]);
237 237
         }
238 238
 
239 239
         if (method_exists($this->getConfigurationPool()->getContainer()->getParameter('app.entity_page'), 'gettemplate')) {
240 240
             $formMapper->add('template', null, [
241
-             'label' => 'admin.page.template.label',
242
-             'required' => false,
241
+                'label' => 'admin.page.template.label',
242
+                'required' => false,
243 243
             ]);
244 244
         }
245 245
 
@@ -271,7 +271,7 @@  discard block
 block discarded – undo
271 271
             'choices' => [
272 272
                 'admin.page.metaRobots.choice.noIndex' => 'no-index, no-follow',
273 273
             ],
274
-             'label' => 'admin.page.metaRobots.label',
274
+                'label' => 'admin.page.metaRobots.label',
275 275
         ]);
276 276
         }
277 277
         /*
@@ -286,10 +286,10 @@  discard block
 block discarded – undo
286 286
 
287 287
         if (method_exists($this->getConfigurationPool()->getContainer()->getParameter('app.entity_page'), 'getauthor')) {
288 288
             $formMapper->add('author', null, [
289
-             'label' => 'admin.page.author.label',
290
-             'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_user'),
291
-             'label' => 'Auteur',
292
-             'required' => false,
289
+                'label' => 'admin.page.author.label',
290
+                'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_user'),
291
+                'label' => 'Auteur',
292
+                'required' => false,
293 293
             ]);
294 294
         }
295 295
     }
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -142,10 +142,10 @@  discard block
 block discarded – undo
142 142
                 'required' => false,
143 143
                  'multiple' => true,
144 144
                  'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_faq'),
145
-                 'property' => 'question',   // or any field in your media entity
145
+                 'property' => 'question', // or any field in your media entity
146 146
                  'label' => 'admin.page.faq.label',
147 147
                  'btn_add' => true,
148
-                 'to_string_callback' => function ($entity) {//, $property) {
148
+                 'to_string_callback' => function($entity) {//, $property) {
149 149
                      return $entity->getQuestion();
150 150
                  },
151 151
              ]);
@@ -157,10 +157,10 @@  discard block
 block discarded – undo
157 157
                 'required' => false,
158 158
                  'multiple' => true,
159 159
                  'class' => $this->getConfigurationPool()->getContainer()->getParameter('app.entity_page'),
160
-                 'property' => 'title',   // or any field in your media entity
160
+                 'property' => 'title', // or any field in your media entity
161 161
                  'label' => 'admin.page.relatedPage.label',
162 162
                  'btn_add' => false,
163
-                 'to_string_callback' => function ($entity) { //, $property) {
163
+                 'to_string_callback' => function($entity) { //, $property) {
164 164
                      return $entity->getTitle();
165 165
                  },
166 166
              ]);
Please login to merge, or discard this patch.