silverstripe/dataobject-auditor

Audits delete and write operations on DataObjects

Installs: 150

Dependents: 0

Suggesters: 0

Security: 0

Stars: 5

Watchers: 3

Forks: 0

Open Issues: 0

Type:silverstripe-vendormodule

1.1.0 2018-02-06 04:28 UTC

This package is auto-updated.

Last update: 2024-04-13 09:01:51 UTC


README

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.