@@ -34,7 +34,7 @@ |
||
| 34 | 34 | // the name property changes for ListAssociationField |
| 35 | 35 | $name = $property->getName(); |
| 36 | 36 | if ($annotation instanceof ListAssociationField) { |
| 37 | - $name .= '.'.$annotation->getField(); |
|
| 37 | + $name .= '.' . $annotation->getField(); |
|
| 38 | 38 | } |
| 39 | 39 | |
| 40 | 40 | if (!$annotation->hasPosition()) { |
@@ -33,7 +33,7 @@ |
||
| 33 | 33 | // the name property changes for ShowAssociationField |
| 34 | 34 | $name = $property->getName(); |
| 35 | 35 | if ($annotation instanceof ShowAssociationField) { |
| 36 | - $name .= '.'.$annotation->getField(); |
|
| 36 | + $name .= '.' . $annotation->getField(); |
|
| 37 | 37 | } |
| 38 | 38 | |
| 39 | 39 | if (!$annotation->hasPosition()) { |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | // the name property changes for DatagridAssociationField |
| 30 | 30 | $name = $property->getName(); |
| 31 | 31 | if ($annotation instanceof DatagridAssociationField) { |
| 32 | - $name .= '.'.$annotation->getField(); |
|
| 32 | + $name .= '.' . $annotation->getField(); |
|
| 33 | 33 | } |
| 34 | 34 | |
| 35 | 35 | if (!$annotation->hasPosition()) { |
@@ -121,15 +121,15 @@ discard block |
||
| 121 | 121 | * @param string|null $baseControllerName Admin controller. |
| 122 | 122 | */ |
| 123 | 123 | public function __construct( |
| 124 | - ActionButtonReader $actionButtonReader, |
|
| 125 | - DatagridReader $datagridReader, |
|
| 126 | - DatagridValuesReader $datagridValuesReader, |
|
| 127 | - DashboardActionReader $dashboardActionReader, |
|
| 128 | - ExportReader $exportReader, |
|
| 129 | - FormReader $formReader, |
|
| 130 | - ListReader $listReader, |
|
| 131 | - RouteReader $routeReader, |
|
| 132 | - ShowReader $showReader, |
|
| 124 | + ActionButtonReader $actionButtonReader, |
|
| 125 | + DatagridReader $datagridReader, |
|
| 126 | + DatagridValuesReader $datagridValuesReader, |
|
| 127 | + DashboardActionReader $dashboardActionReader, |
|
| 128 | + ExportReader $exportReader, |
|
| 129 | + FormReader $formReader, |
|
| 130 | + ListReader $listReader, |
|
| 131 | + RouteReader $routeReader, |
|
| 132 | + ShowReader $showReader, |
|
| 133 | 133 | ?string $code = null, |
| 134 | 134 | ?string $class = null, |
| 135 | 135 | ?string $baseControllerName = null |
@@ -156,7 +156,7 @@ discard block |
||
| 156 | 156 | public function getExportFormats(): array |
| 157 | 157 | { |
| 158 | 158 | return $this->exportReader->getFormats( |
| 159 | - $this->getReflectionClass() |
|
| 159 | + $this->getReflectionClass() |
|
| 160 | 160 | ) ?: parent::getExportFormats(); |
| 161 | 161 | } |
| 162 | 162 | |
@@ -171,19 +171,19 @@ discard block |
||
| 171 | 171 | * @throws ReflectionException |
| 172 | 172 | */ |
| 173 | 173 | protected function configureActionButtons( |
| 174 | - array $buttonList, |
|
| 175 | - string $action, |
|
| 174 | + array $buttonList, |
|
| 175 | + string $action, |
|
| 176 | 176 | ?object $object = null |
| 177 | 177 | ): array { |
| 178 | 178 | return $this->actionButtonReader |
| 179 | - ->getActions( |
|
| 179 | + ->getActions( |
|
| 180 | 180 | $this->getReflectionClass(), |
| 181 | 181 | parent::configureActionButtons( |
| 182 | - $buttonList, |
|
| 183 | - $action, |
|
| 184 | - $object |
|
| 182 | + $buttonList, |
|
| 183 | + $action, |
|
| 184 | + $object |
|
| 185 | 185 | ) |
| 186 | - ); |
|
| 186 | + ); |
|
| 187 | 187 | } |
| 188 | 188 | |
| 189 | 189 | /** |
@@ -197,10 +197,10 @@ discard block |
||
| 197 | 197 | protected function configureDashboardActions(array $actions): array |
| 198 | 198 | { |
| 199 | 199 | return $this->dashboardActionReader |
| 200 | - ->getActions( |
|
| 200 | + ->getActions( |
|
| 201 | 201 | $this->getReflectionClass(), |
| 202 | 202 | parent::configureDashboardActions($actions) |
| 203 | - ); |
|
| 203 | + ); |
|
| 204 | 204 | } |
| 205 | 205 | |
| 206 | 206 | /** |
@@ -214,8 +214,8 @@ discard block |
||
| 214 | 214 | protected function configureDatagridFilters(DatagridMapper $filter): void |
| 215 | 215 | { |
| 216 | 216 | $this->datagridReader->configureFields( |
| 217 | - $this->getReflectionClass(), |
|
| 218 | - $filter |
|
| 217 | + $this->getReflectionClass(), |
|
| 218 | + $filter |
|
| 219 | 219 | ); |
| 220 | 220 | } |
| 221 | 221 | |
@@ -228,7 +228,7 @@ discard block |
||
| 228 | 228 | protected function configureExportFields(): array |
| 229 | 229 | { |
| 230 | 230 | return $this->exportReader->getFields( |
| 231 | - $this->getReflectionClass() |
|
| 231 | + $this->getReflectionClass() |
|
| 232 | 232 | ) ?: parent::getExportFields(); |
| 233 | 233 | } |
| 234 | 234 | |
@@ -244,15 +244,15 @@ discard block |
||
| 244 | 244 | { |
| 245 | 245 | if ($this->getRequest()->get($this->getIdParameter())) { |
| 246 | 246 | $this->formReader->configureEditFields( |
| 247 | - $this->getReflectionClass(), |
|
| 248 | - $form |
|
| 247 | + $this->getReflectionClass(), |
|
| 248 | + $form |
|
| 249 | 249 | ); |
| 250 | 250 | return; |
| 251 | 251 | } |
| 252 | 252 | |
| 253 | 253 | $this->formReader->configureCreateFields( |
| 254 | - $this->getReflectionClass(), |
|
| 255 | - $form |
|
| 254 | + $this->getReflectionClass(), |
|
| 255 | + $form |
|
| 256 | 256 | ); |
| 257 | 257 | } |
| 258 | 258 | |
@@ -267,10 +267,10 @@ discard block |
||
| 267 | 267 | protected function configureListFields(ListMapper $list): void |
| 268 | 268 | { |
| 269 | 269 | $this->listReader |
| 270 | - ->configureFields( |
|
| 270 | + ->configureFields( |
|
| 271 | 271 | $this->getReflectionClass(), |
| 272 | 272 | $list |
| 273 | - ); |
|
| 273 | + ); |
|
| 274 | 274 | } |
| 275 | 275 | |
| 276 | 276 | /** |
@@ -284,16 +284,16 @@ discard block |
||
| 284 | 284 | protected function configureRoutes(RouteCollectionInterface $collection |
| 285 | 285 | ): void { |
| 286 | 286 | [$addRoutes, $removeRoutes] = $this->routeReader->getRoutes( |
| 287 | - $this->getReflectionClass() |
|
| 287 | + $this->getReflectionClass() |
|
| 288 | 288 | ); |
| 289 | 289 | |
| 290 | 290 | /** @var AddRoute $route */ |
| 291 | 291 | foreach ($addRoutes as $route) { |
| 292 | 292 | $collection->add( |
| 293 | - $route->getName(), |
|
| 294 | - $route->path ? $this->replaceIdParameterInRoutePath( |
|
| 293 | + $route->getName(), |
|
| 294 | + $route->path ? $this->replaceIdParameterInRoutePath( |
|
| 295 | 295 | $route->path |
| 296 | - ) : $route->getName() |
|
| 296 | + ) : $route->getName() |
|
| 297 | 297 | ); |
| 298 | 298 | } |
| 299 | 299 | |
@@ -314,8 +314,8 @@ discard block |
||
| 314 | 314 | protected function configureShowFields(ShowMapper $show): void |
| 315 | 315 | { |
| 316 | 316 | $this->showReader->configureFields( |
| 317 | - $this->getReflectionClass(), |
|
| 318 | - $show |
|
| 317 | + $this->getReflectionClass(), |
|
| 318 | + $show |
|
| 319 | 319 | ); |
| 320 | 320 | } |
| 321 | 321 | |
@@ -330,9 +330,9 @@ discard block |
||
| 330 | 330 | private function replaceIdParameterInRoutePath(string $path): string |
| 331 | 331 | { |
| 332 | 332 | return str_replace( |
| 333 | - AddRoute::ID_PARAMETER, |
|
| 334 | - $this->getRouterIdParameter(), |
|
| 335 | - $path |
|
| 333 | + AddRoute::ID_PARAMETER, |
|
| 334 | + $this->getRouterIdParameter(), |
|
| 335 | + $path |
|
| 336 | 336 | ); |
| 337 | 337 | } |
| 338 | 338 | |
@@ -24,7 +24,7 @@ |
||
| 24 | 24 | $config['directory'] ?? $container->getParameter('kernel.project_dir') . '/src/' |
| 25 | 25 | ); |
| 26 | 26 | |
| 27 | - $loader = new XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config')); |
|
| 27 | + $loader = new XmlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config')); |
|
| 28 | 28 | $loader->load('reader.xml'); |
| 29 | 29 | } |
| 30 | 30 | } |
@@ -54,7 +54,7 @@ |
||
| 54 | 54 | } |
| 55 | 55 | |
| 56 | 56 | $roles[$annotation->getRole()] = array_map( |
| 57 | - function (string $permission) use ($prefix) { |
|
| 57 | + function(string $permission) use ($prefix) { |
|
| 58 | 58 | return $prefix . strtoupper($permission); |
| 59 | 59 | }, |
| 60 | 60 | $annotation->permissions |