Module Maintenance + création du module Recette

This commit is contained in:
2021-04-01 20:44:45 +02:00
parent a887f6892b
commit 8d8ca3fe2f
92 changed files with 6334 additions and 6 deletions

View File

@@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8" ?>
<config xmlns="http://thelia.net/schema/dic/config"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://thelia.net/schema/dic/config http://thelia.net/schema/dic/config/thelia-1.0.xsd">
<forms>
<form name="admin_maintenance_settings" class="Maintenance\Form\MaintenanceSettingsForm" />
</forms>
<services>
<service id="maintenance.listener" class="Maintenance\EventListener\MaintenanceListener">
<argument>%kernel.debug%</argument>
<tag name="kernel.event_subscriber"/>
</service>
</services>
<hooks>
<hook id="maintenance.warning" class="Maintenance\Hook\HookManager">
<tag name="hook.event_listener" event="main.body-top" type="front" method="onMainBodyTop" />
</hook>
<hook id="maintenance.configuration.hook" class="Maintenance\Hook\HookManager">
<tag name="hook.event_listener" event="module.configuration" type="back" method="onModuleConfigure" />
</hook>
<hook id="maintenance.menutools.hook" class="Maintenance\Hook\HookManager">
<tag name="hook.event_listener" event="main.top-menu-tools" type="back" method="onMainTopMenuTools" />
</hook>
</hooks>
</config>

View File

@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="http://thelia.net/schema/dic/module"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://thelia.net/schema/dic/module http://thelia.net/schema/dic/module/module-2_1.xsd">
<fullnamespace>Maintenance\Maintenance</fullnamespace>
<descriptive locale="en_US">
<title>Maintenance mode</title>
</descriptive>
<descriptive locale="fr_FR">
<title>Mode Maintenance</title>
</descriptive>
<languages>
<language>en_US</language>
<language>fr_FR</language>
</languages>
<version>0.8</version>
<author>
<name>Nicolas Léon, Franck Allimant</name>
<email>nicolas@omnitic.com, thelia@cqfdev.fr</email>
</author>
<type>classic</type>
<thelia>2.3.0</thelia>
<stability>prod</stability>
</module>

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8" ?>
<routes xmlns="http://symfony.com/schema/routing"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://symfony.com/schema/routing http://symfony.com/schema/routing/routing-1.0.xsd">
<route id="maintenance.front" path="/maintenance">
<default key="_controller">Maintenance\Controller\MaintenanceController::displayMaintenance</default>
</route>
<route id="maintenance.back-preview" path="/maintenance-preview">
<default key="_controller">Maintenance\Controller\MaintenanceController::displayMaintenance</default>
</route>
<route id="maintenance.home" path="/admin/module/maintenance">
<default key="_controller">Maintenance\Controller\MaintenanceAdminController::indexAction</default>
</route>
<route id="maintenance.update" path="/admin/module/maintenance/configure" methods="post">
<default key="_controller">Maintenance\Controller\MaintenanceAdminController::configureAction</default>
</route>
</routes>