How to set the permissions for admins of Django/Me

2019-05-04 22:07发布

I'm not sure what permissions I have to assign to a group so that users of that group can login to the admin area of the specific Mezzanine site that they are assigned to. The user have Staff status checked.

I want the group to have limited access to settings such as:

sites (all)
redirects (all)
core (all)
auth | can add user
auth | can delete user
auth | permission (all)
auth | group (all)

I'm note sure what this permissions are suppost to do (but when adding them I can't login anyway):

admin | log entry (all)

The error message I get is:

You don't have permission to access the admin for this site.

1条回答
\"骚年 ilove
2楼-- · 2019-05-04 22:46

You have to actually click on the site name in the "Site permissions" part of the user's screen in the admin. It isn't obvious that just clicking on the site name does anything but once you do this and save the user info, a record gets added to the core_sitepermission and core_sitepermission_sites table that associates this user with a site.

Without this, the Mezzanine SitePermissionMiddleware.process_view will cause an exception which will show this particular message. Once I made this change, the user was able to log in to the admin site and then was able to edit the other site features that they were given permissions on.

查看更多
登录 后发表回答