No project description provided
Project description
Implentation of ACL for ckan.
When extension enabled, new tab Permissions added to admin interface. Here you can manage user permissions on per-user level.
In order to add new managed permission, one should implement ckanext.acl.interfaces.IACL and define update_permission_list method in plugin and change perm - first positional argument passed into this method. perms is ckanext.acl.access_permissions.AccessPermissions object so you can check available actions there.
- Example of code that you can use in your plugin(will allow any user to create new organization)::
from ckanext.acl.interfaces import IACL
plugins.implements(IACL)
# IACL
- def update_permission_list(self, perms):
perms.create_permission(‘organization_create’)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ckanext-acl-0.1.2.tar.gz
(9.8 kB
view hashes)
Built Distribution
Close
Hashes for ckanext_acl-0.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | facdea73326e8dc6907caf081510b9f566a5ce1679419907fbf007142c8b0262 |
|
MD5 | 92bbaa08c53df1161fbea4847c5a5493 |
|
BLAKE2b-256 | 306374d5f2ec7ae4230c067ef9caf41a1b0c042877604d5df094edab324f7b96 |