Darumaotoshi: "Archive and delete" (slide delete) plugin for CakePHP 3
PHP
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
config/Migrations
src/Model
tests
.editorconfig
.travis.yml
README.md
composer.json
phpunit.xml.dist

README.md

Darumaotoshi Build Status

だるま落とし

"Archive and delete" (slide delete) plugin for CakePHP 3

Installation

$ composer require k1low/darumaotoshi

Enable plugin

$ bin/cake plugin load Darumaotoshi

Load required database table

$ bin/cake migrations migrate --plugin Darumaotoshi

Usage

// in the initialize() method
$this->addBehavior('Darumaotoshi.Darumaotoshi');

Cascading deletion

If you'd like to have related records marked as trashed when deleting a parent item, you can just attach the behavior to the related table classes, and set the 'dependent' => true, 'cascadeCallbacks' => true options in the table relationships.

Code References

UseMuffin/Trash

Copyright (c) 2015, Use Muffin and licensed under The MIT License.

License

under The MIT License.