浏览代码

Added info about how role names are built.

Adam Quaile 10 年之前
父节点
当前提交
c73455c72d
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      Resources/doc/reference/security.rst

+ 2 - 0
Resources/doc/reference/security.rst

@@ -116,6 +116,8 @@ The permissions are:
 Each permission is relative to an admin: if you try to get a list in FooAdmin (declared as ``sonata.admin.demo.foo``
 service), Sonata will check if the user has the ``ROLE_SONATA_ADMIN_DEMO_FOO_EDIT`` role.
 
+The role name will be based on the name of your admin service. For instance, `acme.blog.post.admin` will become `ROLE_ACME_BLOG_POST_ADMIN_{ACTION}`.
+
 So our ``security.yml`` file may look to something like this:
 
 .. configuration-block::