configuration.rst 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. Configuration
  2. =============
  3. Configuration options
  4. * ``security``
  5. * ``handler``
  6. * ``sonata.admin.security.handler.role`` : The default value
  7. * ``sonata.admin.security.handler.acl`` : Use this service if you want ACL
  8. * ``title`` : The admin's title, can be the client name for instance (default: Sonata Admin)
  9. * ``title_logo`` : logo to use, must be an image with a height of 28px (default : /bundles/sonataadmin/logo_title.png)
  10. Please see :doc:`templates` for more information on how to configure default templates.
  11. Full Configuration Options
  12. --------------------------
  13. .. code-block:: yaml
  14. sonata_admin:
  15. security:
  16. handler: sonata.admin.security.handler.role
  17. title: Sonata Project
  18. title_logo: /bundles/sonataadmin/logo_title.png
  19. templates:
  20. # default global templates
  21. layout: SonataAdminBundle::standard_layout.html.twig
  22. ajax: SonataAdminBundle::ajax_layout.html.twig
  23. dashboard: SonataAdminBundle:Core:dashboard.html.twig
  24. # default actions templates, should extend a global templates
  25. list: SonataAdminBundle:CRUD:list.html.twig
  26. show: SonataAdminBundle:CRUD:show.html.twig
  27. edit: SonataAdminBundle:CRUD:edit.html.twig
  28. dashboard:
  29. blocks:
  30. # display a dashboard block
  31. - { position: left, type: sonata.admin.block.admin_list }
  32. # Customize this part to add new block configuration
  33. - { position: right, type: sonata.block.service.text, settings: { content: "<h2>Welcome to the Sonata Admin</h2> <p>This is a <code>sonata.block.service.text</code> from the Block Bundle, you can create and add new block in these area by configuring the <code>sonata_admin</code> section.</p> <br /> For instance, here a RSS feed parser (<code>sonata.block.service.rss</code>):"} }
  34. - { position: right, type: sonata.block.service.rss, settings: { title: Sonata Project's Feeds, url: http://sonata-project.org/blog/archive.rss }}
  35. # set to true to persist filter settings per admin module in the user's session
  36. persist_filters: false
  37. sonata_block:
  38. default_contexts: [cms]
  39. blocks:
  40. sonata.admin.block.admin_list:
  41. contexts: [admin]