Skip to content

steffenborup/blame

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Blame

Build Status Latest Stable Version Total Downloads Latest Unstable Version License

CakePHP 3.0 plugin to update created_by and modified_by fields.

Installation

Add the following lines to your application's composer.json:

    "require": {
        "ceeram/cakephp-blame": "~1.0"
    }

followed by the command:

composer update

Or run the following command directly without changing your composer.json:

composer require ceeram/cakephp-blame:~1.0

Usage

In your app's config/bootstrap.php add: Plugin::load('Ceeram/Blame');

Configuration

Add the following line to your AppController:

    use \Ceeram\Blame\Controller\BlameTrait;

Add the following inside your AppController Class

class AppController extends Controller
{
    use BlameTrait;
}

Attach the behavior in the models you want with:

    public function initialize(array $config) {
        $this->addBehavior('Ceeram/Blame.Blame');
    }

About

CakePHP 3.0 plugin to update created_by and modified_by fields

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 100.0%