2017 © Pedro Peláez
 

cakephp-plugin revision

Revision plugin for CakePHP

image

kicaj/revision

Revision plugin for CakePHP

  • Friday, February 9, 2018
  • by kicaj
  • Repository
  • 1 Watchers
  • 0 Stars
  • 5 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Revision plugin for CakePHP

NOTE: It's still in development mode, do not use in production yet!, (*1)

Requirements

It is developed for CakePHP 3.x., (*2)

Installation

You can install plugin into your CakePHP application using composer., (*3)

The recommended way to install composer packages is:, (*4)

composer require kicaj/revision dev-master

Load the Behavior

Load the Behavior in your src/Model/Table/YourTable.php (or if You have AppTable.php). Your table should have two additionals columns: revision_id and revision_hash., (*5)

public function initialize(array $config)
{
    parent::initialize($config);

    $this->addBehavior('Revision.Revision');
}

The field revision_id should have the same type like primary key of table., (*6)

TODOs

  • [ ] Block updating modified field when highest parent is deleted
  • [ ] Check with complex conditions
  • [ ] Check configuration
  • [ ] Exceptions for missing fields/columns
  • [ ] Create history view
  • [ ] Revert method
  • [ ] Field with hash should check unique before save (recurring)
  • [ ] Set excluded fields

The Versions

09/02 2018

dev-master

9999999-dev

Revision plugin for CakePHP

  Sources   Download

MIT

The Requires

 

by Avatar kicaj