Skip to content

Latest commit

 

History

History
49 lines (36 loc) · 949 Bytes

README.md

File metadata and controls

49 lines (36 loc) · 949 Bytes

Tracelog Plugin

History changelog for eloquent models in October CMS.

Description

This plugin is a single Trait to append to your Eloquent models in OctoberCMS to be able to trace modifications on a changelog

Usage

Implement the LastEdit Trait in your model to be tracked.

use Icodemx\Tracelog\Classes\LastEdit;

For example

namespace Acme\Foo\Models;
use Icodemx\Tracelog\Classes\LastEdit;

class MyModel extends Model
{
    use LastEdit;
}

And that's it.

Your model now will be tracked

Extra options

/*
 *
 * Set this variable if you want to override the default "Updated/Deleted" msg
 *
 */

public $message;

/*
 *
 * Set this variable you want to save some column of your model
 * on the tracelog table
 *
 */
    
public $referenceLog;