Modification nom du dispatcher -> ResourcesDispatcher
This commit is contained in:
parent
82fd46cd43
commit
8a57bfc94b
|
@ -41,7 +41,7 @@
|
||||||
$R->get('settings/', function(){ include __ROOT__.'/view.php'; });
|
$R->get('settings/', function(){ include __ROOT__.'/view.php'; });
|
||||||
|
|
||||||
// Dispatcher
|
// Dispatcher
|
||||||
$R->get('f(?:/([\w-]+))*/?', function(){ new manager\Dispatcher($_GET['url']); });
|
$R->get('f(?:/([\w-]+))*/?', function(){ new manager\ResourcesDispatcher($_GET['url']); });
|
||||||
|
|
||||||
// N'importe -> page d'accueil
|
// N'importe -> page d'accueil
|
||||||
$R->get('.+', function(){ header('Location: /dashboard/'); });
|
$R->get('.+', function(){ header('Location: /dashboard/'); });
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
namespace manager;
|
namespace manager;
|
||||||
|
|
||||||
|
|
||||||
class Dispatcher{
|
class ResourcesDispatcher{
|
||||||
|
|
||||||
// Constantes (a dispatcher dans un .conf)
|
// Constantes (a dispatcher dans un .conf)
|
||||||
public static $extension_config_path = '/config/dispatcher-extensions.json';
|
public static $extension_config_path = '/config/dispatcher-extensions.json';
|
10
view.php
10
view.php
|
@ -42,11 +42,11 @@
|
||||||
|
|
||||||
<!-- MENU DE LA PAGE -->
|
<!-- MENU DE LA PAGE -->
|
||||||
<nav id='MENU-SIDE'>
|
<nav id='MENU-SIDE'>
|
||||||
<span data-link='dashboard' data-desc='Tableau de bord' ><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/menu-dashboard/st/menu-side'; ?></span>
|
<span data-link='dashboard' data-desc='Tableau de bord' ><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/menu-dashboard/st/menu-side' ); ?></span>
|
||||||
<span data-link='machines' data-desc='Véhicules' ><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/menu-machines/st/menu-side/'; ?></span>
|
<span data-link='machines' data-desc='Véhicules' ><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/menu-machines/st/menu-side/' ); ?></span>
|
||||||
<span data-link='users' data-desc='Utilisateurs' ><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/users2/st/menu-side/'; ?></span>
|
<span data-link='users' data-desc='Utilisateurs' ><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/users2/st/menu-side/' ); ?></span>
|
||||||
<span data-link='sync' data-desc='Synchronisation' ><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/menu-sync/st/menu-side/'; ?></span>
|
<span data-link='sync' data-desc='Synchronisation' ><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/menu-sync/st/menu-side/' ); ?></span>
|
||||||
<span data-link='settings' data-desc='Paramètres' ><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/menu-settings/st/menu-side/'; ?></span>
|
<span data-link='settings' data-desc='Paramètres' ><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/menu-settings/st/menu-side/' ); ?></span>
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,12 +1,25 @@
|
||||||
<!-- [1] Gestion du sous-menu de gauche -->
|
<!-- [1] Gestion du sous-menu de gauche -->
|
||||||
|
|
||||||
<nav class='sub-menu-side'>
|
<nav class='sub-menu-side'>
|
||||||
<span>menu item 1</span>
|
<span data-sublink='displayall'>
|
||||||
<span>menu item 2</span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/view/st/sub-menu-side' ); ?></span>
|
||||||
<span>menu item 3</span>
|
<span>Tout afficher</span>
|
||||||
<span>menu item 4</span>
|
</span>
|
||||||
<span>menu item 5</span>
|
|
||||||
<span>menu item 6</span>
|
<span data-sublink='filter' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/filter/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Filtrer</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='search' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/search/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Recherche</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='remove' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/remove/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Vider l'historique</span>
|
||||||
|
</span>
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
Bienvenue sur le DASHBOARD
|
Bienvenue sur le DASHBOARD
|
|
@ -2,32 +2,32 @@
|
||||||
|
|
||||||
<nav class='sub-menu-side'>
|
<nav class='sub-menu-side'>
|
||||||
<span data-sublink='displayall'>
|
<span data-sublink='displayall'>
|
||||||
<span class='svg'><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/view/st/sub-menu-side'; ?></span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/view/st/sub-menu-side' ); ?></span>
|
||||||
<span>Tout afficher</span>
|
<span>Tout afficher</span>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<span data-sublink='create' >
|
<span data-sublink='create' >
|
||||||
<span class='svg'><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/create/st/sub-menu-side'; ?></span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/create/st/sub-menu-side' ); ?></span>
|
||||||
<span>Creation</span>
|
<span>Creation</span>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<span data-sublink='remove' >
|
<span data-sublink='remove' >
|
||||||
<span class='svg'><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/remove/st/sub-menu-side'; ?></span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/remove/st/sub-menu-side' ); ?></span>
|
||||||
<span>Suppression</span>
|
<span>Suppression</span>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<span data-sublink='edit' >
|
<span data-sublink='edit' >
|
||||||
<span class='svg'><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/edit/st/sub-menu-side'; ?></span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/edit/st/sub-menu-side' ); ?></span>
|
||||||
<span>Modification</span>
|
<span>Modification</span>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<span data-sublink='filter' >
|
<span data-sublink='filter' >
|
||||||
<span class='svg'><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/filter/st/sub-menu-side'; ?></span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/filter/st/sub-menu-side' ); ?></span>
|
||||||
<span>Filtrer</span>
|
<span>Filtrer</span>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<span data-sublink='search' >
|
<span data-sublink='search' >
|
||||||
<span class='svg'><?php include 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/search/st/sub-menu-side'; ?></span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/search/st/sub-menu-side' ); ?></span>
|
||||||
<span>Recherche</span>
|
<span>Recherche</span>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
|
|
|
@ -1,12 +1,36 @@
|
||||||
<!-- [1] Gestion du sous-menu de gauche -->
|
<!-- [1] Gestion du sous-menu de gauche -->
|
||||||
|
|
||||||
<nav class='sub-menu-side'>
|
<nav class='sub-menu-side'>
|
||||||
<span>menu item 1</span>
|
<span data-sublink='displayall'>
|
||||||
<span>menu item 2</span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/view/st/sub-menu-side' ); ?></span>
|
||||||
<span>menu item 3</span>
|
<span>Tout afficher</span>
|
||||||
<span>menu item 4</span>
|
</span>
|
||||||
<span>menu item 5</span>
|
|
||||||
<span>menu item 6</span>
|
<span data-sublink='create' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/create/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Creation</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='remove' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/remove/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Suppression</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='edit' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/edit/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Modification</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='filter' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/filter/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Filtrer</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='search' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/search/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Recherche</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
Bienvenue sur la page des PARAMETRES
|
Bienvenue sur la page des PARAMETRES
|
|
@ -1,12 +1,36 @@
|
||||||
<!-- [1] Gestion du sous-menu de gauche -->
|
<!-- [1] Gestion du sous-menu de gauche -->
|
||||||
|
|
||||||
<nav class='sub-menu-side'>
|
<nav class='sub-menu-side'>
|
||||||
<span>menu item 1</span>
|
<span data-sublink='displayall'>
|
||||||
<span>menu item 2</span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/view/st/sub-menu-side' ); ?></span>
|
||||||
<span>menu item 3</span>
|
<span>Tout afficher</span>
|
||||||
<span>menu item 4</span>
|
</span>
|
||||||
<span>menu item 5</span>
|
|
||||||
<span>menu item 6</span>
|
<span data-sublink='create' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/create/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Creation</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='remove' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/remove/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Suppression</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='edit' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/edit/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Modification</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='filter' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/filter/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Filtrer</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='search' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/search/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Recherche</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
Bienvenue sur la page de SYNCHRONISATION
|
Bienvenue sur la page de SYNCHRONISATION
|
|
@ -1,12 +1,36 @@
|
||||||
<!-- [1] Gestion du sous-menu de gauche -->
|
<!-- [1] Gestion du sous-menu de gauche -->
|
||||||
|
|
||||||
<nav class='sub-menu-side'>
|
<nav class='sub-menu-side'>
|
||||||
<span>menu item 1</span>
|
<span data-sublink='displayall'>
|
||||||
<span>menu item 2</span>
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/view/st/sub-menu-side' ); ?></span>
|
||||||
<span>menu item 3</span>
|
<span>Tout afficher</span>
|
||||||
<span>menu item 4</span>
|
</span>
|
||||||
<span>menu item 5</span>
|
|
||||||
<span>menu item 6</span>
|
<span data-sublink='create' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/create/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Creation</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='remove' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/remove/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Suppression</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='edit' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/edit/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Modification</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='filter' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/filter/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Filtrer</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span data-sublink='search' >
|
||||||
|
<span class='svg'><?php echo file_get_contents( 'http://'.$_SERVER['HTTP_HOST'].'/f/svg/search/st/sub-menu-side' ); ?></span>
|
||||||
|
<span>Recherche</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
Bienvenue sur la page de gestion des UTILISATEURS
|
Bienvenue sur la page de gestion des UTILISATEURS
|
Loading…
Reference in New Issue