Skip to content

A SilverStripe module which Audits updates to and deletion of DataObject class instances.

License

Notifications You must be signed in to change notification settings

fspringveldt/silverstripe-dataobject-auditor

Repository files navigation

SilverStripe DataObject auditor

Build Status Scrutinizer Code Quality Code coverage License Total Downloads

A SilverStripe module which audits updates to and deletions from DataObject subclasses.

Installation

composer require silverstripe/dataobject-auditor

Setup

No setup is required as the AuditExtension is automatically added to DataObject.

Changes are added to two tables viz. DataObjectAuditor_Audit which has a $has_many to DataObjectAuditor_AuditValues. Only changed records are added to the DataObjectAuditor_AuditValues table to prevent duplication. In the case of deletion though, the entire record is written.

Configuration/Usage instructions

By default all DataObjects, except Audit and AuditValue are audited.

You can exclude some items by adding them to the AuditExtension::audit_exclusions config setting:

SilverStripe\DataObjectAuditor\Extensions\AuditExtension:
  audit_exclusions:
    - Namespaced\ClassName1
    - Namespaced\ClassName2

Bugtracker

Bugs are tracked on github.com.

About

A SilverStripe module which Audits updates to and deletion of DataObject class instances.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages