djangoauditorialog 0.1
AuditLog is a simple django-app for saving logs of activities performed on models.
Quick start
Add auditlog to your INSTALLED_APPS setting like this:
` INSTALLED_APPS = [`
` …`
` ‘auditlog’,`
` ]`
Include the auditlog_db database settings:
DATABASES = {
` …,`
` ‘auditlog_db’: {`
` ‘ENGINE’: ‘django.db.backends.sqlite3’,`
` ‘NAME’: os.path.join(BASE_DIR, ‘auditlog.sqlite3’),`
` }`
` }`
Run python manage.py migrate to create the auditlog models.
To saving log use the piece of code in each view that you want to saving audit:
AuditLogDispatcher.send(sender=NotaFiscal, user=request.user, instance=instance, acao=’some action’)
The acao parameter can be:
1. create
1. update
1. delete
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.