Conditions | 1 |
Paths | 1 |
Total Lines | 43 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
11 | public function __invoke() |
||
12 | { |
||
13 | return [ |
||
14 | 'templates' => [ |
||
15 | 'map' => [ |
||
16 | 'page/pagination' => __DIR__.'/../templates/partial/pagination.php', |
||
17 | ], |
||
18 | 'paths' => [ |
||
19 | 'page' => [__DIR__.'/../templates/page'], |
||
20 | ], |
||
21 | ], |
||
22 | |||
23 | 'dependencies' => [ |
||
24 | 'factories' => [ |
||
25 | Controller\PageController::class => Controller\PageControllerFactory::class, |
||
26 | Service\PageService::class => Service\PageServiceFactory::class, |
||
27 | Mapper\PageMapper::class => Mapper\PageMapperFactory::class, |
||
28 | Filter\PageFilter::class => InvokableFactory::class, |
||
29 | ], |
||
30 | ], |
||
31 | |||
32 | 'routes' => [ |
||
33 | [ |
||
34 | 'name' => 'admin.pages', |
||
35 | 'path' => '/admin/pages', |
||
36 | 'middleware' => Controller\PageController::class, |
||
37 | 'allowed_methods' => ['GET'], |
||
38 | ], |
||
39 | [ |
||
40 | 'name' => 'admin.pages.action', |
||
41 | 'path' => '/admin/pages/{action}/{id}', |
||
42 | 'middleware' => Controller\PageController::class, |
||
43 | 'allowed_methods' => ['GET', 'POST'], |
||
44 | ], |
||
45 | ], |
||
46 | |||
47 | 'view_helpers' => [ |
||
48 | 'factories' => [ |
||
49 | 'page' => View\Helper\PageHelperFactory::class, |
||
50 | ], |
||
51 | ], |
||
52 | ]; |
||
53 | } |
||
54 | } |
||
55 |