Fix on AdminLTE 3, and add some features
This commit is contained in:
@@ -12,7 +12,7 @@ class Botanic
|
||||
$menu->add('Botanique', [ 'permission' => 'backend_access', 'icon' => 'leaf' ])
|
||||
->id('botanic')
|
||||
->activeIfRoute('botanic')
|
||||
->order(2);
|
||||
->order(4);
|
||||
|
||||
$menu->addTo('botanic', 'Familles', [ 'route' => 'Botanic.Admin.Families.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Botanic.Admin.Families.*'])->order(1);
|
||||
|
||||
21
app/Menu/Customers.php
Normal file
21
app/Menu/Customers.php
Normal file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
|
||||
namespace App\Menu;
|
||||
|
||||
use Sebastienheyd\Boilerplate\Menu\Builder;
|
||||
|
||||
class Customers
|
||||
{
|
||||
public function make(Builder $menu)
|
||||
{
|
||||
$menu->add('Clients', [ 'permission' => 'backend_access', 'icon' => 'address-card' ])
|
||||
->id('customers')
|
||||
->activeIfRoute('customers')
|
||||
->order(3);
|
||||
|
||||
$menu->addTo('customers', 'Clients', [ 'route' => 'Shop.Admin.Customers.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.Customers.*'])->order(1);
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
26
app/Menu/Orders.php
Normal file
26
app/Menu/Orders.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace App\Menu;
|
||||
|
||||
use Sebastienheyd\Boilerplate\Menu\Builder;
|
||||
|
||||
class Orders
|
||||
{
|
||||
public function make(Builder $menu)
|
||||
{
|
||||
$menu->add('Commandes', [ 'permission' => 'backend_access', 'icon' => 'shopping-basket' ])
|
||||
->id('orders')
|
||||
->activeIfRoute('orders')
|
||||
->order(1);
|
||||
|
||||
$menu->addTo('orders', 'Commandes', [ 'route' => 'Shop.Admin.Orders.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.Orders.*'])->order(1);
|
||||
$menu->addTo('orders', 'Factures', [ 'route' => 'Shop.Admin.Invoices.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.Invoices.*'])->order(2);
|
||||
$menu->addTo('orders', 'Avoirs', [ 'route' => 'Shop.Admin.Invoices.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.Invoices.*'])->order(3);
|
||||
$menu->addTo('orders', 'Bons de livraison', [ 'route' => 'Shop.Admin.Invoices.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.Invoices.*'])->order(4);
|
||||
|
||||
}
|
||||
}
|
||||
@@ -3,33 +3,31 @@
|
||||
namespace App\Menu;
|
||||
|
||||
use Sebastienheyd\Boilerplate\Menu\Builder;
|
||||
use App\Repositories\Users;
|
||||
|
||||
class Shop
|
||||
{
|
||||
public function make(Builder $menu)
|
||||
{
|
||||
$menu->add('Commerce', [ 'permission' => 'backend_access', 'icon' => 'shopping-basket' ])
|
||||
$menu->add('Catalogue', [ 'permission' => 'backend_access', 'icon' => 'store' ])
|
||||
->id('shop')
|
||||
->activeIfRoute('shop')
|
||||
->order(1);
|
||||
->order(2);
|
||||
|
||||
$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);
|
||||
->activeIfRoute(['Shop.Admin.Articles.*'])->order(1);
|
||||
$menu->addTo('shop', 'Categories', [ 'route' => 'Shop.Admin.Categories.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.Categories.*'])->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', 'Familles d\'attributs', [ 'route' => 'Shop.Admin.ArticleAttributeFamilies.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.ArticleAttributeFamilies.*'])->order(4);
|
||||
$menu->addTo('shop', 'Attributs', [ 'route' => 'Shop.Admin.ArticleAttributeValues.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.ArticleAttributeValues.*'])->order(5);
|
||||
$menu->addTo('shop', 'Réductions', [ 'route' => 'Shop.Admin.ArticleAttributeValues.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.ArticleAttributeValues.*'])->order(6);
|
||||
$menu->addTo('shop', 'Stock', [ 'route' => 'Shop.Admin.ArticleAttributeValues.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.ArticleAttributeValues.*'])->order(7);
|
||||
|
||||
$menu->addTo('shop', 'Commandes', [ 'route' => 'Shop.Admin.Orders.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.Orders.*'])->order(6);
|
||||
$menu->addTo('shop', 'Factures', [ 'route' => 'Shop.Admin.Invoices.index', 'permission' => 'backend_access' ])
|
||||
->activeIfRoute(['Shop.Admin.Invoices.*'])->order(7);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user