Rajout d'un export Excel
[zf2.biz/galerie.git] / module / Galerie / config / module.config.php
index 830cf49..21c80cc 100644 (file)
@@ -4,7 +4,13 @@ return array(
     'controllers' => array(
         'invokables' => array(
             'Galerie\Controller\Index' =>
-                'Galerie\Controller\IndexController'
+                'Galerie\Controller\IndexController',
+        ),
+    ),
+    'controller_plugins' => array(
+        'invokables' => array(
+            'MessageGetter' =>
+                'Custom\Mvc\Controller\Plugin\MessageGetter',
         ),
     ),
     'view_manager' => array(
@@ -21,6 +27,9 @@ return array(
         'template_path_stack' => array(
             'galerie' => __DIR__ . '/../view',
         ),
+        'strategies' => array(
+            'ViewJsonStrategy',
+        ),
     ),
     'router' => array(
         'routes' => array(
@@ -37,7 +46,6 @@ return array(
                 'verb' => 'get',
                 'may_terminate' => true,
                 'child_routes' => array(
-
                     'add' => array(
                         'type'    => 'Literal',
                         'options' => array(
@@ -100,6 +108,37 @@ return array(
                         ),
                         'verb' => 'get,post',
                     ),
+                    'list' => array(
+                        'type'    => 'Literal',
+                        'options' => array(
+                            'route'    => '/liste',
+                            'defaults' => array(
+                                'action' => 'list',
+                            ),
+                        ),
+                        'verb' => 'get',
+                    ),
+                    'csv' => array(
+                        'type'    => 'Literal',
+                        'options' => array(
+                            'route'    => '/csv',
+                            'defaults' => array(
+                                'action' => 'csv',
+                            ),
+                        ),
+                        'verb' => 'get',
+                    ),
+                    'excel' => array(
+                        'type'    => 'Literal',
+                        'options' => array(
+                            'route'    => '/excel',
+                            'defaults' => array(
+                                'action' => 'excel',
+                            ),
+                        ),
+                        'verb' => 'get',
+                    ),
+/*
                     'default' => array(
                         'type'    => 'Segment',
                         'options' => array(
@@ -111,7 +150,7 @@ return array(
                             'defaults' => array(
                             ),
                         ),
-                    ),
+                    ),*/
                 ),
             ),
         ),