Skip to content

manaakiwhenua/ckanext-datasetapproval

 
 

Repository files navigation

CKAN

ckanext-datasetapproval

An extension which enforces private visibility of a dataset until it has been reviewed and approved by an organisation admin.

Installation

To install ckanext-datasetapproval:

Note: if you're using ckanext_scheming extension, add new field to the schema configuration YAML file.

- field_name          : publishing_status
     label            : Publishing Status
     form_snippet     : null
     display_snippet  : null
     validators       : ignore_missing
- field_name          : chosen_visibility
     label            : Visibility
     form_snippet     : visibility.html
     display_snippet  : null
     validators       : ignore_empty unicode_safe
     default          : true

  1. Activate your CKAN virtual environment, for example:

    . /usr/lib/ckan/default/bin/activate

  2. Clone the source and install it on the virtualenv

    git clone https://github.com//ckanext-datasetapproval.git cd ckanext-datasetapproval pip install -e . pip install -r requirements.txt

  3. Add dataset_approval to the ckan.plugins setting in your CKAN config file (by default the config file is located at /etc/ckan/default/ckan.ini).

  4. Add ckanext.approval.turn_on_email_notifications to the config file, to turn on/off review mail (this is set to true by default)
    Note: if you are using a dockerised CKAN environment add this environment variable to your .env file CKANEXT__APPROVAL__TURN_ON_EMAIL_NOTIFICATIONS=false

  5. Restart CKAN. For example if you've deployed CKAN with Apache on Ubuntu:

    sudo service apache2 reload

Approval Flow for Dataset

  1. On create/update of a dataset, all editors can save their datasets as in progress to work on datasets without submitting for review.
image image
  1. Only editors within any given organisation can submit a dataset for review.
image


Editors get this message: image


Note: All organisation admins are able to create and update datasets without having to submit for review.

  1. When a dataset is submitted for review, an email is sent to all admins (reviewers) of the specified organisation.
image
  1. Users are able to view both their own datasets pending review and any submitted datasets they need to review
    An editor can see datasets they have requested for review
image


An admin can see datasets that they need to review image

  1. To review, an admin of the organisation can choose to approve or reject the dataset
image

a. on reject they can add a rejection reason image

b. user is emailed their review outcome image

  1. All datasets are enforced private until the dataset is approved. During in progress or on rejection, the dataset will remain private a. this means in progress and rejected datasets are only visible to organisation members

  2. At any point (during or after dataset review), an editor can go back into the dataset, make changes, and submit for review again

About

Dataset review workflow implementation for CKAN.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 59.5%
  • HTML 34.2%
  • JavaScript 5.5%
  • Other 0.8%