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

Open in your IDE?
  1. <?php
  2. /*
  3.  * This file has been created by developers from BitBag.
  4.  * Feel free to contact us once you face any issues or want to start
  5.  * another great project.
  6.  * You can find more information about us on https://bitbag.shop and write us
  7.  * an email on mikolaj.krol@bitbag.pl.
  8.  */
  9. declare(strict_types=1);
  10. namespace BitBag\SyliusCmsPlugin\Menu;
  11. use Sylius\Bundle\UiBundle\Menu\Event\MenuBuilderEvent;
  12. final class ContentManagementMenuBuilder
  13. {
  14.     public function buildMenu(MenuBuilderEvent $menuBuilderEvent): void
  15.     {
  16.         $menu $menuBuilderEvent->getMenu();
  17.         $cmsRootMenuItem $menu
  18.             ->addChild('bitbag_cms')
  19.             ->setLabel('bitbag_sylius_cms_plugin.ui.cms')
  20.         ;
  21.         $cmsRootMenuItem
  22.             ->addChild('blocks', [
  23.                 'route' => 'bitbag_sylius_cms_plugin_admin_block_index',
  24.             ])
  25.             ->setLabel('bitbag_sylius_cms_plugin.ui.blocks')
  26.             ->setLabelAttribute('icon''block layout')
  27.         ;
  28.         $cmsRootMenuItem
  29.             ->addChild('media', [
  30.                 'route' => 'bitbag_sylius_cms_plugin_admin_media_index',
  31.             ])
  32.             ->setLabel('bitbag_sylius_cms_plugin.ui.media')
  33.             ->setLabelAttribute('icon''file')
  34.         ;
  35.         $cmsRootMenuItem
  36.             ->addChild('pages', [
  37.                 'route' => 'bitbag_sylius_cms_plugin_admin_page_index',
  38.             ])
  39.             ->setLabel('bitbag_sylius_cms_plugin.ui.pages')
  40.             ->setLabelAttribute('icon''sticky note')
  41.         ;
  42.         $cmsRootMenuItem
  43.             ->addChild('faq', [
  44.                 'route' => 'bitbag_sylius_cms_plugin_admin_frequently_asked_question_index',
  45.             ])
  46.             ->setLabel('bitbag_sylius_cms_plugin.ui.faq')
  47.             ->setLabelAttribute('icon''help')
  48.         ;
  49.         $cmsRootMenuItem
  50.             ->addChild('sections', [
  51.                 'route' => 'bitbag_sylius_cms_plugin_admin_section_index',
  52.             ])
  53.             ->setLabel('bitbag_sylius_cms_plugin.ui.sections')
  54.             ->setLabelAttribute('icon''grid layout')
  55.         ;
  56.     }
  57. }