2017 © Pedro Peláez
 

symfony-bundle admin

Bundle for easy integrations admin genetion

image

youshido/admin

Bundle for easy integrations admin genetion

  • Friday, April 28, 2017
  • by portey
  • Repository
  • 4 Watchers
  • 1 Stars
  • 499 Installations
  • CSS
  • 1 Dependents
  • 0 Suggesters
  • 5 Forks
  • 0 Open issues
  • 22 Versions
  • 0 % Grown

The README.md

AdminBundle

1. Install required bundles via composer:

``` console composer require youshido/admin composer require liip/imagine-bundle, (*1)


### 2. Enable bundles: ``` php //AppKernel.php $bundles = [ //... new Youshido\AdminBundle\YAdminBundle(), new Liip\ImagineBundle\LiipImagineBundle(), ];

3. Create your own Admin Bundle:

``` console php app/console generate:bundle --namespace=AdminBundle --bundle-name=AdminBundle --dir=src, (*2)


### 4. Create action in your AdminBundle default controller: ``` php //AdminBundle\Controller\DefaultController /** * @return \Symfony\Component\HttpFoundation\Response * * @Route("/", name="admin.dashboard") * @Route("/dashboard", name="project.admin.dashboard") */ public function indexAction() { $this->get('admin.context')->setActiveModuleName('dashboard'); return $this->render('YAdminBundle:Default:index.html.twig', [ 'siteStatistics' => null, 'widgets' => [ ], ] ); }

5. Enable routing:

``` yaml //routing.yml, (*3)

admin: resource: "@YAdminBundle/Controller/" type: annotation prefix: /admin, (*4)

app_admin: #your admin bundle resource: "@AdminBundle/Controller/" type: annotation prefix: /admin, (*5)

_liip_imagine: resource: "@LiipImagineBundle/Resources/config/routing.xml", (*6)


### 6. Add to your config.yml: ``` yaml //config.yml liip_imagine: resolvers: default: web_path: ~ filter_sets: cache: ~ thumbnail_120x90: quality: 75 filters: thumbnail: { size: [120, 90], mode: outbound } thumbnail_50x50: quality: 75 filters: thumbnail: { size: [50, 50], mode: outbound } !!! twig: //... globals: adminContext: '@admin.context'

7. Add to your security.yml

``` yaml role_hierarchy: ROLE_ADMIN: [ROLE_USER] ROLE_SUPER_ADMIN: [ROLE_ADMIN], (*7)

providers:
    admin_provider:
        entity:
            class: Youshido\AdminBundle\Entity\AdminUser
            property: login


encoders:
    Youshido\AdminBundle\Entity\AdminUser: md5

firewalls:
    admin_free:
        pattern: ^/admin/login$ # ^/(?:ua/)?admin/login$ - if you have internationalization
        context: admin
        anonymous: ~

    admin_firewall:
        pattern: ^/admin # ^/(?:ua/)?admin - if you have internationalization
        provider: admin_provider
        context: admin
        form_login:
            login_path: admin.login
            check_path: admin.login_check
        logout:
            path:   admin.logout
            target: /admin

### 8. Create 'structure.yml' file in app/config/admin directory with content: ``` yaml name: "Your project name" modules: dashboard: icon: fa fa-home route: admin.dashboard type: ~ imports: - { resource: ../../../vendor/youshido/admin/Resources/config/admin/structure.admin.yml }

9. Run in console

``` console php app/console doctrine:schema:update --force php app/console admin:setup, (*8)


### 10. Generate configuration for you entity ``` console php app/console admin:generate
!!! Don't forget to import generated file to structure.yml

11. Config if you use internationalization

yaml //app/admin/structure.yml internationalization: enable: true locales: en: ~ ua: ~ ru: ~, (*9)

The Versions

28/04 2017

dev-master

9999999-dev https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

19/03 2017

dev-sf2-version

dev-sf2-version https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

16/03 2017

v0.2.6

0.2.6.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

04/03 2017

v0.2.5

0.2.5.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

02/03 2017

v0.2.4

0.2.4.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

02/03 2017

v0.2.3

0.2.3.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

26/12 2016

v0.0.11

0.0.11.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

05/09 2016

v0.0.10

0.0.10.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

25/08 2016

v0.0.9

0.0.9.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

15/08 2016

v0.2.1

0.2.1.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

22/07 2016

v0.0.8

0.0.8.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

22/07 2016

v0.0.7

0.0.7.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

22/07 2016

v0.0.6

0.0.6.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

21/05 2016

v0.2

0.2.0.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

13/04 2016

v0.0.5

0.0.5.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

01/03 2016

v0.0.4

0.0.4.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

10/02 2016

v0.0.3

0.0.3.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

11/01 2016

dev-develop

dev-develop https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

19/11 2015

v0.0.2

0.0.2.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

21/10 2015

0.0.1

0.0.1.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

08/07 2015

v0.1

0.1.0.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator

06/07 2015

1.0.0

1.0.0.0 https://github.com/Youshido/AdminBundle

Bundle for easy integrations admin genetion

  Sources   Download

MIT

The Requires

 

by Alexandr Viniychuk

bundle symfony admin admin generator