advance.rst 1.3 KB

1234567891011121314151617181920212223242526272829303132
  1. Advance
  2. =======
  3. By default services who are injected to an admin instance are
  4. ==================== =============================================
  5. method name Service Id
  6. ==================== =============================================
  7. model_manager sonata.admin.manager.%manager-type%
  8. form_contractor sonata.admin.builder.%manager-type%_form
  9. show_builder sonata.admin.builder.%manager-type%_show
  10. list_builder sonata.admin.builder.%manager-type%_list
  11. datagrid_builder sonata.admin.builder.%manager-type%_datagrid
  12. translator translator
  13. configuration_pool sonata.admin.pool
  14. router router
  15. validator validator
  16. security_handler sonata.admin.security.handler
  17. ==================== =============================================
  18. Note: %manager-type% is replace by the manager type (orm, odm...)
  19. If you want to modify the service who are going to be injected, add the following code to your
  20. application's config file:
  21. .. code-block:: yaml
  22. # app/config/config.yml
  23. admins:
  24. sonata_admin: #method name, you can find the list in the table above
  25. sonata.order.admin.order: #id of the admin service's
  26. model_manager: sonata.order.admin.order.manager #id of the your service