<?php

namespace App\Menu;

use Sebastienheyd\Boilerplate\Menu\Builder;

class Orders
{
    public function make(Builder $menu)
    {
        $menu->add('Commandes', ['icon' => 'shopping-basket'])
            ->id('orders')
            ->order(1);
        
        $menu->addTo('orders', 'Commandes', [
            'route' => 'Admin.Shop.Orders.index',
        ])->activeIfRoute(['Admin.Shop.Orders.*'])->order(1);
        
        $menu->addTo('orders', 'Factures', [
            'route' => 'Admin.Shop.Invoices.index',
        ])->activeIfRoute(['Admin.Shop.Invoices.*'])->order(2);
        
        $menu->addTo('orders', 'Avoirs', [
            'route' => 'Admin.Shop.Invoices.index',
        ])->activeIfRoute(['Admin.Shop.Invoices.*'])->order(3);
        
        $menu->addTo('orders', 'Bons de livraison', [
            'route' => 'Admin.Shop.Invoices.index',
        ])->activeIfRoute(['Admin.Shop.Invoices.*'])->order(4);
    }
}
