承接 aropixel/page-bundle 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

aropixel/page-bundle

最新稳定版本:v2.0.11

Composer 安装命令:

composer require aropixel/page-bundle

包简介

Gestion de page pour admin Aropixel

README 文档

README

Aropixel logo

Aropixel Page Bundle

Aropixel Page Bundle is a complementray bundle of Aropixel Admin Bundle. It gives possibility to manage standard pages for your website.

GitHub last commit GitHub issues License

Aropixel Page Preview

Aropixel Page Preview

Table of contents

Quick start

  • Create your symfony 4 project & install Aropixel AdminBundle
  • Require Aropixel Page Bundle : composer require aropixel/page-bundle
  • Apply migrations
  • Include the routes :
aropixel_page:
  resource: '@AropixelPageBundle/Resources/config/routing.yml'
  prefix:   /admin
  • create a ConfigureMenuListener class, register it as an event listener and include the page menu in the listener:
    App\EventListener\ConfigureMenuListener:
        tags:
            - { name: kernel.event_listener, event: aropixel.admin_menu_configure, method: onMenuConfigure }
<?php

declare(strict_types=1);

// src/AppBundle/EventListener/ConfigureMenuListener.php

namespace App\EventListener;

use Aropixel\AdminBundle\Event\ConfigureMenuEvent;
use Aropixel\AdminBundle\Menu\AbstractMenuListener;

class ConfigureMenuListener extends AbstractMenuListener
{
    /**
     * @param ConfigureMenuEvent $event
     */
    public function onMenuConfigure(ConfigureMenuEvent $event)
    {
        $request = $this->requestStack->getCurrentRequest();
        $this->factory = $event->getFactory();
        $this->em = $event->getEntityManager();
        $this->routeName = $request->get('_route');
        $this->routeParameters = $request->get('_route_params');

        $this->menu = $event->getAppMenu('main');
        if (!$this->menu) {
            $this->menu = $this->createRoot();
        }

        $pageMenu = [
            'route' => 'aropixel_page_index',
            'routeParameters' => [
                'type' => 'default'
            ]
        ];

        $this->addItem('Pages', $pageMenu, 'far fa-file');
        
        $event->addAppMenu($this->menu, false, 'main');
    }
}

License

Aropixel Page Bundle is under the MIT License

统计信息

  • 总下载量: 4.43k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2019-06-12