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
Built Distribution
File details
Details for the file ckanext-acl-0.1.0.tar.gz
.
File metadata
- Download URL: ckanext-acl-0.1.0.tar.gz
- Upload date:
- Size: 9.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6429b22d8954e8bb3200b0bdcfda49ea9e7a56c37265337e34a88a46ced015bc |
|
MD5 | d0aedc541ee227683620171c0f080276 |
|
BLAKE2b-256 | c2c775caf5911882c8f69fe4ddc5ccb6dac619cfc0dbc81d18f0014c977790fd |
File details
Details for the file ckanext_acl-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: ckanext_acl-0.1.0-py3-none-any.whl
- Upload date:
- Size: 24.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5a3cfaad6764f918e7e4960abb7773f915e5fea531732faad58593019e0a4d26 |
|
MD5 | fff2fd18e4e6043ce39447c85536e7f2 |
|
BLAKE2b-256 | e092a98359ffbab32181ebfb1ab0ad89b1f8c3c658f57c3d2845cbb2a4f2cda5 |