|
- <?php
-
- namespace Lc\CaracoleBundle\Controller\Dashboard;
-
- use EasyCorp\Bundle\EasyAdminBundle\Config\Assets;
- use EasyCorp\Bundle\EasyAdminBundle\Config\Crud;
- use EasyCorp\Bundle\EasyAdminBundle\Config\MenuItem;
- use EasyCorp\Bundle\EasyAdminBundle\Config\UserMenu;
- use Lc\CaracoleBundle\Controller\ControllerTrait;
- use Lc\SovBundle\Controller\Dashboard\DashboardAdminController as SovDashboardController;
- use Symfony\Component\Security\Core\User\UserInterface;
-
- class DashboardAdminAdminController extends SovDashboardController
- {
- use ControllerTrait;
-
- public function configureCrud(): Crud
- {
- $crud = parent::configureCrud();
-
- $crud
- ->overrideTemplate('layout', '@LcCaracole/adminlte/layout.html.twig');
-
- return $crud;
- }
-
- public function configureAssets(): Assets
- {
- $assets = parent::configureAssets(); // TODO: Change the autogenerated stub
-
- $assets->addWebpackEncoreEntry('carac-common');
- $assets->addWebpackEncoreEntry('carac-switch-merchant');
- $assets->addWebpackEncoreEntry('carac-duplicate');
- $assets->addWebpackEncoreEntry('carac-product');
-
- return $assets;
- }
-
- public function configureUserMenu(UserInterface $user): UserMenu
- {
- return parent::configureUserMenu($user)
- ->setMenuItems(
- [
- MenuItem::linkToRoute('Mon profil', 'fa fa-id-card', 'sov_admin_account_profile'),
- MenuItem::linkToLogout('Déconnexion', 'sign-out-alt'),
- ]
- );
- }
-
- }
|