Current path: home/webdevt/cryptoimpot.fr/module/Application/config/
?? Go up: /home/webdevt/cryptoimpot.fr/module/Application
<?php
/**
* @link http://github.com/zendframework/ZendSkeletonApplication for the canonical source repository
* @copyright Copyright (c) 2005-2016 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
namespace Application;
use Laminas\Router\Http\Literal;
use Laminas\Router\Http\Segment;
use Laminas\ServiceManager\Factory\InvokableFactory;
use Doctrine\DBAL\Driver\PDOMySql\Driver as PDOMySqlDriver;
use Doctrine\ORM\Mapping\Driver\AnnotationDriver;
use Application\Form\Validator\RecaptchaValidator;
use Application\Form\Element\Recaptcha;
use Application\Factory\Form\Element\RecaptchaFactory;
use Application\View\Helper\Recaptcha as RecaptchaHelper;
use Application\Factory\Validator\RecaptchaValidatorFactory;
return [
'router' => [
'routes' => [
'home' => [
'type' => Literal::class,
'options' => [
'route' => '/',
'defaults' => [
'controller' => Controller\HomeController::class,
'action' => 'index',
],
],
'may_terminate' => true,
],
'mention' => [
'type' => Literal::class,
'options' => [
'route' => '/mention',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'mention',
],
],
'may_terminate' => true,
],
'guide-fiscal' => [
'type' => Literal::class,
'options' => [
'route' => '/guide-fiscal',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'guideFiscal',
],
],
'may_terminate' => true,
],
'justificatifs' => [
'type' => Literal::class,
'options' => [
'route' => '/justificatifs-declaration-fiscale-crypto-monnaie',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'justificatifs',
],
],
'may_terminate' => true,
],
'sitemap' => [
'type' => Literal::class,
'options' => [
'route' => '/sitemap.xml',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'sitemap',
],
],
'may_terminate' => true,
],
'contact' => [
'type' => Literal::class,
'options' => [
'route' => '/contact',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'contact',
],
],
'may_terminate' => true,
],
'mentions-legales' => [
'type' => Literal::class,
'options' => [
'route' => '/mentions-legales',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'mentionsLegales',
],
],
'may_terminate' => true,
],
'protection-donnees' => [
'type' => Literal::class,
'options' => [
'route' => '/protection-donnees',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'protectionDonnees',
],
],
'may_terminate' => true,
],
'politique-cookie' => [
'type' => Literal::class,
'options' => [
'route' => '/politique-cookie',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'politiqueCookie',
],
],
'may_terminate' => true,
],
'questions-activite' => [
'type' => Literal::class,
'options' => [
'route' => '/fiscalite-crypto-test-questionnaire-regime-occasionnel-particulier-professionnel',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'questionsActivite',
],
],
'may_terminate' => true,
],
'questions-activite-old' => [
'type' => Literal::class,
'options' => [
'route' => '/questions-activite',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'questionsActiviteOld',
],
],
'may_terminate' => true,
],
'cgs' => [
'type' => Literal::class,
'options' => [
'route' => '/cgs',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'cgs',
],
],
'may_terminate' => true,
],
'cgs-accept' => [
'type' => Literal::class,
'options' => [
'route' => '/cgs-accept',
'defaults' => [
'controller' => Controller\AccueilController::class,
'action' => 'cgsAccept',
],
],
'may_terminate' => true,
],
'message' => [
'type' => Literal::class,
'options' => [
'route' => '/message',
'defaults' => [
'controller' => Controller\InformationController::class,
'action' => 'message',
],
],
'may_terminate' => true,
],
'declaration-compte' => [
'type' => Literal::class,
'options' => [
'route' => '/declaration-compte',
'defaults' => [
'controller' => Controller\DeclarationCompteController::class,
'action' => 'index',
],
],
'may_terminate' => true,
'child_routes' => [
'generation-rapport' => [
'type' => Segment::class,
'options' => [
'route' => '/generation-rapport',
'defaults' => [
'controller' => Controller\DeclarationCompteController::class,
'action' => 'generationRapport',
],
],
],
],
],
'information' => [
'type' => Literal::class,
'options' => [
'route' => '/information',
'defaults' => [
'controller' => Controller\InformationController::class,
'action' => 'add',
],
],
'may_terminate' => true,
'child_routes' => [
'update-exchange' => [
'type' => Literal::class,
'options' => [
'route' => '/update-exchange',
'defaults' => [
'controller' => Controller\InformationController::class,
'action' => 'updateExchange',
],
],
],
],
],
'exchange-pub' => [
'type' => Literal::class,
'options' => [
'route' => '/exchange',
'defaults' => [
'controller' => Controller\ExchangeController::class,
'action' => 'index'
],
],
'may_terminate' => true,
'child_routes' => [
'infos-pub' => [
'type' => Segment::class,
'options' => [
'route' => '/infos/:exchange',
'constraints' => [
'exchange' => '[a-zA-Z0-9_-]+',
],
'defaults' => [
'controller' => Controller\ExchangeController::class,
'action' => 'infos'
],
],
],
],
],
'admin' => [
'type' => Literal::class,
'options' => [
'route' => '/admin',
'defaults' => [
'controller' => Controller\AdminController::class,
'action' => 'index',
],
],
'may_terminate' => true,
'child_routes' => [
'exchange' => [
'type' => Literal::class,
'options' => [
'route' => '/exchange',
'defaults' => [
'controller' => Controller\ExchangeController::class,
'action' => 'index'
],
],
'may_terminate' => true,
'child_routes' => [
'update-exchange' => [
'type' => Segment::class,
'options' => [
'route' => '/:exchange',
'constraints' => [
'exchange' => '[a-zA-Z0-9_-]+',
],
'defaults' => [
'controller' => Controller\ExchangeController::class,
'action' => 'show',
],
],
],
],
],
'crypto' => [
'type' => Literal::class,
'options' => [
'route' => '/crypto',
'defaults' => [
'controller' => Controller\CryptoController::class,
'action' => 'index'
],
],
'may_terminate' => true,
'child_routes' => [
'show-crypto' => [
'type' => Segment::class,
'options' => [
'route' => '/:crypto',
'constraints' => [
'crypto' => '[a-zA-Z0-9_-]+',
],
'defaults' => [
'controller' => Controller\CryptoController::class,
'action' => 'show',
],
],
],
'update-crypto' => [
'type' => Segment::class,
'options' => [
'route' => '/update/:crypto',
'constraints' => [
'crypto' => '[a-zA-Z0-9_-]+',
],
'defaults' => [
'controller' => Controller\CryptoController::class,
'action' => 'updateCoursAuto',
],
],
],
],
],
// 'liste-exchange' => [
// 'type' => Segment::class,
// 'options' => [
// 'route' => '/liste-exchange',
//// 'constraints' => [
//// 'exchange' => '[a-zA-Z0-9_-]+',
//// ],
// 'defaults' => [
// 'controller' => Controller\ExchangeController::class,
// 'action' => 'index'
// ],
// ],
// ],
// 'exchange' => [
// 'type' => Segment::class,
// 'options' => [
// 'route' => '/exchange/:exchange',
// 'constraints' => [
// 'exchange' => '[a-zA-Z0-9_-]+',
// ],
// 'defaults' => [
// 'controller' => Controller\ExchangeController::class,
// 'action' => 'show'
// ],
// ],
// ],
],
],
'importation' => [
'type' => Literal::class,
'options' => [
'route' => '/importation',
'defaults' => [
'controller' => Controller\ImportationController::class,
'action' => 'index',
],
],
'may_terminate' => true,
'child_routes' => [
'exchange' => [
'type' => Segment::class,
'options' => [
'route' => '/trades/:exchange',
'constraints' => [
'exchange' => '[a-zA-Z0-9_-]+',
],
'defaults' => [
'controller' => Controller\ImportationController::class,
'action' => 'index'
],
],
],
'upload' => [
'type' => Segment::class,
'options' => [
'route' => '/upload',
'defaults' => [
'controller' => Controller\ImportationController::class,
'action' => 'upload'
],
],
],
'api' => [
'type' => Segment::class,
'options' => [
'route' => '/api',
'defaults' => [
'controller' => Controller\ImportationController::class,
'action' => 'api'
],
],
],
'delete-all' => [
'type' => Segment::class,
'options' => [
'route' => '/delete-all',
'defaults' => [
'controller' => Controller\ImportationController::class,
'action' => 'deleteAll'
],
],
],
'delete' => [
'type' => Segment::class,
'options' => [
'route' => '/delete',
'defaults' => [
'controller' => Controller\ImportationController::class,
'action' => 'delete'
],
],
],
],
],
/* step 4 apercu */
'autres-transactions' => [
'type' => Literal::class,
'options' => [
'route' => '/autres-transactions',
'defaults' => [
'controller' => Controller\AutresTransactionsController::class,
'action' => 'add',
],
],
],
/* step 4 apercu */
'apercu' => [
'type' => Literal::class,
'options' => [
'route' => '/apercu',
'defaults' => [
'controller' => Controller\ApercuController::class,
'action' => 'index',
],
],
],
'update-ledgio' => [
'type' => Literal::class,
'options' => [
'route' => '/update-ledgio',
'defaults' => [
'controller' => Controller\ApercuController::class,
'action' => 'updateLedgio',
],
],
],
'generation-rapport-erreurs-portefeuille' => [
'type' => Literal::class,
'options' => [
'route' => '/generation-rapport-erreurs-portefeuille',
'defaults' => [
'controller' => Controller\RapportController::class,
'action' => 'generateWarningRapport',
],
],
],
'correction' => [
'type' => Literal::class,
'options' => [
'route' => '/correction',
'defaults' => [
'controller' => Controller\ApercuController::class,
'action' => 'correction',
],
],
],
/* step 5 rapport */
'rapport' => [
'type' => Literal::class,
'options' => [
'route' => '/rapport',
'defaults' => [
'controller' => Controller\RapportController::class,
'action' => 'index',
],
],
'may_terminate' => true,
'child_routes' => [
'apercu' => [
'type' => Segment::class,
'options' => [
'route' => '/apercu/:year',
'constraints' => [
'year' => '[0-9]*',
],
'defaults' => [
'controller' => Controller\RapportController::class,
'action' => 'apercu',
],
],
],
'generate' => [
'type' => Segment::class,
'options' => [
'route' => '/generate/:year',
'constraints' => [
'year' => '[0-9]*',
],
'defaults' => [
'controller' => Controller\RapportController::class,
'action' => 'generate',
],
],
],
'download' => [
'type' => Segment::class,
'options' => [
'route' => '/download/:year/:mode/[:type]',
'constraints' => [
'year' => '[0-9]*',
'mode' => '[a-zA-Z0-9_-]*',
'type' => '[a-zA-Z0-9_-]*',
],
'defaults' => [
'controller' => Controller\RapportController::class,
'action' => 'download',
],
],
],
'validation-commande' => [
'type' => Segment::class,
'options' => [
'route' => '/validation-commande/:year/:orderId/',
'constraints' => [
'year' => '[0-9]*',
'orderId' => '[a-zA-Z0-9_-]*',
],
'defaults' => [
'controller' => Controller\RapportController::class,
'action' => 'validationCommande',
],
],
],
]
],
// 'myauth' => [
// 'type' => Segment::class,
// 'options' => [
// 'route' => '/myauth[/:action[/:id]]',
// 'constraints' => [
// 'action' => '[a-zA-Z][a-zA-Z0-9_-]*',
// 'id' => '[a-zA-Z0-9_-]*',
// ],
// 'defaults' => [
// 'controller' => Controller\IndexController::class,
// 'action' => 'index',
// ],
// ],
// ],
'register' => [
'type' => Literal::class,
'options' => [
'route' => '/inscription',
'defaults' => [
'controller' => Controller\AuthController::class,
'action' => 'register',
],
],
],
'login' => [
'type' => Literal::class,
'options' => [
'route' => '/connexion',
'defaults' => [
'controller' => Controller\AuthController::class,
'action' => 'login',
],
],
],
// 'logout' => [
// 'type' => Literal::class,
// 'options' => [
// 'route' => '/logout',
// 'defaults' => [
// 'controller' => 'zfcuser',
// 'action' => 'logout',
// ],
// ],
// ],
'application' => [
'type' => Segment::class,
'options' => [
'route' => '/application[/:action]',
'defaults' => [
'controller' => Controller\HomeController::class,
'action' => 'index',
],
],
],
],
],
// 'console' => [
// 'router' => [
// 'routes' => [
// 'list-users' => [
// 'options' => [
// 'route' => 'show [all|disabled|deleted]:mode users [--verbose|-v]',
// 'defaults' => [
// 'controller' => Application\Controller\Index::class,
// 'action' => 'show-users',
// ],
// ],
// ],
// ],
// ],
// ],
'controllers' => [
'factories' => [
Controller\IndexController::class => InvokableFactory::class,
Controller\HomeController::class => InvokableFactory::class,
Controller\AccueilController::class => Controller\Factory\AccueilControllerFactory::class,
Controller\InformationController::class => Controller\Factory\InformationControllerFactory::class,
Controller\ImportationController::class => Controller\Factory\ImportationControllerFactory::class,
Controller\AutresTransactionsController::class => Controller\Factory\AutresTransactionsControllerFactory::class,
Controller\ApercuController::class => Controller\Factory\ApercuControllerFactory::class,
Controller\RapportController::class => Controller\Factory\RapportControllerFactory::class,
Controller\UserController::class => InvokableFactory::class,
Controller\AdminController::class => Controller\Factory\AdminControllerFactory::class,
Controller\ExchangeController::class => Controller\Factory\ExchangeControllerFactory::class,
Controller\CryptoController::class => Controller\Factory\CryptoControllerFactory::class,
Controller\DeclarationCompteController::class => Controller\Factory\DeclarationCompteControllerFactory::class,
],
// 'aliases' => [
// 'zfcuser' => 'Application\Controller\User',
// ]
],
'access_filter' => [
'controllers' => [
Controller\HomeController::class => [
// Give access to "resetPassword", "message" and "setPassword" actions
// to anyone.
['actions' => ['index'], 'allow' => '*'],
// Give access to "index", "add", "edit", "view", "changePassword" actions to authorized users only.
['actions' => ['index', 'add', 'edit', 'view', 'changePassword'], 'allow' => '@']
],
Controller\AccueilController::class => [
// Give access to "resetPassword", "message" and "setPassword" actions
// to anyone.
['actions' => ['mention', 'mentionsLegales', 'protectionDonnees', 'politiqueCookie', 'contact', 'questionsActiviteOld', 'questionsActivite', 'guideFiscal', 'justificatifs', 'sitemap'], 'allow' => '*'],
// Give access to "index", "add", "edit", "view", "changePassword" actions to authorized users only.
],
Controller\InformationController::class => [
// Give access to "resetPassword", "message" and "setPassword" actions
// to anyone.
//['actions' => ['index'], 'allow' => '*'],
// Give access to "index", "add", "edit", "view", "changePassword" actions to authorized users only.
['actions' => ['add', 'updateExchange'], 'allow' => '*']
],
Controller\CryptoController::class => [
// Give access to "index", "add", "edit", "view", "changePassword" actions to authorized users only.
['actions' => ['index', 'show'], 'allow' => '*']
],
Controller\ExchangeController::class => [
// Give access to "index", "add", "edit", "view", "changePassword" actions to authorized users only.
['actions' => ['index', 'show', 'infos'], 'allow' => '*']
],
]
],
'service_manager' => [
'factories' => [
\Service\AuthenticationService::class
=> \Application\Service\Factory\AuthenticationServiceFactory::class,
\Laminas\I18n\Translator\TranslatorInterface::class => \Laminas\I18n\Translator\TranslatorServiceFactory::class,
Service\NavManager::class => Service\Factory\NavManagerFactory::class,
\TCPDF::class => Service\Factory\TCPDFFactory::class,
Service\FPDIFormulaire2048m::class => Service\Factory\FPDIFormulaire2048mFactory::class,
Service\TCPDFBrouillon::class => Service\Factory\TCPDFBrouillonFactory::class,
Service\TCPDFRapport::class => Service\Factory\TCPDFRapportFactory::class,
//Middleware\AuthorizationMiddleware::class => Middleware\AuthorizationMiddleware::class,
// 'Job\ImportAPI' => 'Job\Factory\ImportAPIFactory',
//Job\ImportAPI::class, Job\Factory\ImportAPIFactory::class
],
'shared' => [
\TCPDF::class => false
]
],
'form_elements' => [
'factories' => [
Recaptcha::class => RecaptchaFactory::class,
],
],
'validators' => [
'factories' => [
RecaptchaValidator::class => RecaptchaValidatorFactory::class,
],
],
'view_helpers' => [
'factories' => [
'currentRoute' => \Application\Factory\View\Helper\CurrentRouteFactory::class,
View\Helper\Menu::class => View\Helper\Factory\MenuFactory::class,
View\Helper\Breadcrumbs::class => InvokableFactory::class,
View\Helper\Amount::class => InvokableFactory::class,
],
'invokables' => [
'translate' => \Laminas\I18n\View\Helper\Translate::class,
'recaptcha' => RecaptchaHelper::class,
// 'Laminas\Form\View\Helper\FormRadio' => \Application\Form\View\Helper\FormRadio::class
],
'aliases' => [
'mainMenu' => View\Helper\Menu::class,
'pageBreadcrumbs' => View\Helper\Breadcrumbs::class,
'amount' => View\Helper\Amount::class,
],
],
'translator' => [
'locale' => 'en_US',
'translation_file_patterns' => [
[
'type' => 'gettext',
'base_dir' => __DIR__ . '/../language',
'pattern' => '%s.mo',
],
],
],
'view_manager' => [
'display_not_found_reason' => true,
'display_exceptions' => true,
'doctype' => 'HTML5',
'not_found_template' => 'error/404',
'exception_template' => 'error/index',
'template_map' => [
'layout/layout' => __DIR__ . '/../view/layout/layout-ledgio.phtml',
'layout/questions' => __DIR__ . '/../view/layout/layout-questions.phtml',
'layout/rapport' => __DIR__ . '/../view/layout/rapport.phtml',
'layout/warning-rapport' => __DIR__ . '/../view/layout/warning-rapport.phtml',
'layout/annexe-acquisition-avant-01-01-2019' => __DIR__ . '/../view/layout/annexe-acquisition-avant-01-01-2019.phtml',
'application/index/index' => __DIR__ . '/../view/application/index/index.phtml',
'error/404' => __DIR__ . '/../view/error/404.phtml',
'error/index' => __DIR__ . '/../view/error/index.phtml',
'partial/importation/tab' => __DIR__ . '/../view/application/partial/importation/tab.phtml',
'partial/importation/tab-content' => __DIR__ . '/../view/application/partial/importation/tab-content.phtml',
'partial/report/table-header-annexe-V' => __DIR__ . '/../view/application/partial/report/table-header-annexe-V.phtml',
'partial/admin/tab' => __DIR__ . '/../view/application/partial/admin/tab.phtml',
'partial/admin/tab-content' => __DIR__ . '/../view/application/partial/admin/tab-content.phtml',
// Paypal form
'partial/paypal/form-300' => __DIR__ . '/../view/application/partial/paypal/form-300.phtml',
'partial/paypal/payment' => __DIR__ . '/../view/application/partial/paypal/payment.phtml',
'application/partial/flash-messenger/flash-message' => __DIR__ . '/../view/application/partial/flash-messenger/flash-message.phtml',
],
'template_path_stack' => [
__DIR__ . '/../view',
],
],
'doctrine' => [
'driver' => [
__NAMESPACE__ . '_driver' => [
'class' => AnnotationDriver::class,
'cache' => 'array',
'paths' => [__DIR__ . '/../src/Entity']
],
'orm_default' => [
'drivers' => [
__NAMESPACE__ . '\Entity' => __NAMESPACE__ . '_driver'
]
]
], 'migrations_configuration' => [
'orm_default' => [
'directory' => 'data/migrations',
'namespace' => 'Migrations',
'table' => 'migrations',
],
],
],
];