[WIP] Add some classes

This commit is contained in:
Ludovic CANDELLIER
2020-04-25 01:06:04 +02:00
parent e0fecd1a6e
commit 516ec2232e
36 changed files with 814 additions and 131 deletions

View File

@@ -9,19 +9,19 @@ class Botanic
{
public function make(Builder $menu)
{
$menu->add('Botanique', [ 'permission' => 'backend', 'icon' => 'leaf' ])
$menu->add('Botanique', [ 'permission' => 'backend_access', 'icon' => 'leaf' ])
->id('botanic')
->activeIfRoute('botanic')
->order(2);
$menu->addTo('botanic', 'Familles', [ 'route' => 'Botanic.Admin.Families.index', 'permission' => 'backend' ])
->activeIfRoute(['Botanic.Admin.Families.index'])->order(1);
$menu->addTo('botanic', 'Genres', [ 'route' => 'Botanic.Admin.Genres.index', 'permission' => 'backend' ])
->activeIfRoute(['Botanic.Admin.Genres.index'])->order(2);
$menu->addTo('botanic', 'Espèces', [ 'route' => 'Botanic.Admin.Species.index', 'permission' => 'backend' ])
->activeIfRoute(['Botanic.Admin.Species.index'])->order(3);
$menu->addTo('botanic', 'Variétés', [ 'route' => 'Botanic.Admin.Varieties.index', 'permission' => 'backend' ])
->activeIfRoute(['Botanic.Admin.Varieties.index'])->order(4);
$menu->addTo('botanic', 'Familles', [ 'route' => 'Botanic.Admin.Families.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Botanic.Admin.Families.*'])->order(1);
$menu->addTo('botanic', 'Genres', [ 'route' => 'Botanic.Admin.Genres.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Botanic.Admin.Genres.*'])->order(2);
$menu->addTo('botanic', 'Espèces', [ 'route' => 'Botanic.Admin.Species.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Botanic.Admin.Species.*'])->order(3);
$menu->addTo('botanic', 'Variétés', [ 'route' => 'Botanic.Admin.Varieties.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Botanic.Admin.Varieties.*'])->order(4);
}
}

View File

@@ -9,19 +9,23 @@ class Shop
{
public function make(Builder $menu)
{
$menu->add('Commerce', [ 'permission' => 'backend', 'icon' => 'shopping-basket' ])
$menu->add('Commerce', [ 'permission' => 'backend_access', 'icon' => 'shopping-basket' ])
->id('shop')
->activeIfRoute('shop')
->order(1);
$menu->addTo('shop', 'Categories', [ 'route' => 'Shop.Admin.Categories.index', 'permission' => 'backend' ])
->activeIfRoute(['Shop.Admin.Categories.index'])->order(1);
$menu->addTo('shop', 'Articles', [ 'route' => 'Shop.Admin.Articles.index', 'permission' => 'backend' ])
->activeIfRoute(['Shop.Admin.Articles.index'])->order(2);
$menu->addTo('shop', 'Commandes', [ 'route' => 'Shop.Admin.Orders.index', 'permission' => 'backend' ])
->activeIfRoute(['Shop.Admin.Orders.index'])->order(3);
$menu->addTo('shop', 'Factures', [ 'route' => 'Shop.Admin.Invoices.index', 'permission' => 'backend' ])
->activeIfRoute(['Shop.Admin.Invoices.index'])->order(4);
$menu->addTo('shop', 'Categories', [ 'route' => 'Shop.Admin.Categories.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Shop.Admin.Categories.*'])->order(1);
$menu->addTo('shop', 'Articles', [ 'route' => 'Shop.Admin.Articles.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Shop.Admin.Articles.*'])->order(2);
$menu->addTo('shop', 'Familles d\'articles', [ 'route' => 'Shop.Admin.ArticleFamilies.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Shop.Admin.ArticleFamilies.*'])->order(3);
$menu->addTo('shop', 'Commandes', [ 'route' => 'Shop.Admin.Orders.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Shop.Admin.Orders.*'])->order(4);
$menu->addTo('shop', 'Factures', [ 'route' => 'Shop.Admin.Invoices.index', 'permission' => 'backend_access' ])
->activeIfRoute(['Shop.Admin.Invoices.*'])->order(5);
}
}