vendor/bitbag/cms-plugin/src/Menu/ContentManagementMenuBuilder.php line 17

Open in your IDE?
  1. <?php
  2. /*
  3.  * This file was created by developers working at BitBag
  4.  * Do you need more information about us and what we do? Visit our https://bitbag.io website!
  5.  * We are hiring developers from all over the world. Join us and start your new, exciting adventure and become part of us: https://bitbag.io/career
  6. */
  7. declare(strict_types=1);
  8. namespace BitBag\SyliusCmsPlugin\Menu;
  9. use Sylius\Bundle\UiBundle\Menu\Event\MenuBuilderEvent;
  10. final class ContentManagementMenuBuilder
  11. {
  12.     public function buildMenu(MenuBuilderEvent $menuBuilderEvent): void
  13.     {
  14.         $menu $menuBuilderEvent->getMenu();
  15.         $cmsRootMenuItem $menu
  16.             ->addChild('bitbag_cms')
  17.             ->setLabel('bitbag_sylius_cms_plugin.ui.cms')
  18.         ;
  19.         $cmsRootMenuItem
  20.             ->addChild('blocks', [
  21.                 'route' => 'bitbag_sylius_cms_plugin_admin_block_index',
  22.             ])
  23.             ->setLabel('bitbag_sylius_cms_plugin.ui.blocks')
  24.             ->setLabelAttribute('icon''block layout')
  25.         ;
  26.         $cmsRootMenuItem
  27.             ->addChild('media', [
  28.                 'route' => 'bitbag_sylius_cms_plugin_admin_media_index',
  29.             ])
  30.             ->setLabel('bitbag_sylius_cms_plugin.ui.media')
  31.             ->setLabelAttribute('icon''file')
  32.         ;
  33.         $cmsRootMenuItem
  34.             ->addChild('pages', [
  35.                 'route' => 'bitbag_sylius_cms_plugin_admin_page_index',
  36.             ])
  37.             ->setLabel('bitbag_sylius_cms_plugin.ui.pages')
  38.             ->setLabelAttribute('icon''sticky note')
  39.         ;
  40.         $cmsRootMenuItem
  41.             ->addChild('faq', [
  42.                 'route' => 'bitbag_sylius_cms_plugin_admin_frequently_asked_question_index',
  43.             ])
  44.             ->setLabel('bitbag_sylius_cms_plugin.ui.faq')
  45.             ->setLabelAttribute('icon''help')
  46.         ;
  47.         $cmsRootMenuItem
  48.             ->addChild('sections', [
  49.                 'route' => 'bitbag_sylius_cms_plugin_admin_section_index',
  50.             ])
  51.             ->setLabel('bitbag_sylius_cms_plugin.ui.sections')
  52.             ->setLabelAttribute('icon''grid layout')
  53.         ;
  54.     }
  55. }