Skip to main content

Keeps a record of consents. Required by EU law

Project description

Setup

Add:

'consent_log'

to INSTALLED_APPS in settings.py and also a set an integer value CONSENT_LOG_DAYS_EXPIRY to settings.py to configure the length of time that consent record live for.

You must also set the boolean value CONSENT_LOG_AUTO_EXPIRE, this setting is treated as a booleand and if true expire_consent_log() is call on every request to the confirm or reject views.

If you use the expire_consent_log() model function (such as via the auto expire setting above), or expireconset management command you can set a maximum frequency at which the the expire run will happen.

CONSENT_LOG_EXPIRY_MIN_PERIOD = 7 # Only run expiry once a week maxmum.

you must set ths variable if you use these entrypoints.

To Use

Add something like the following to your projects urls.py..

path("consent_log/", include("consent_log.urls"))

This add the modules endpoints to your defined urls, our urls are reversable and named consent-log:confirm and ‘consent-log:reject`` within django url namespace so can be reference as those insire your django templates.

You will need to write or import your own frontend integration to send the actions to record to this module.

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

consent_log-0.1.tar.gz (7.6 kB view hashes)

Uploaded Source

Built Distribution

consent_log-0.1-py3-none-any.whl (11.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page