codedge/hookable

Laravel Eloquent hooks system - improved.

5.5 2017-10-30 21:21 UTC

This package is auto-updated.

Last update: 2022-06-13 17:44:52 UTC


README

Improved version of Jarek Tkaczyk superb hook system for Laravel.

Hooks are available for the following methods:

  • Model::getAttribute
  • Model::setAttribute
  • Model::save
  • Model::toArray
  • Model::replicate
  • Model::isDirty
  • Model::__isset
  • Model::__unset

and all methods available on the Illuminate\Database\Eloquent\Builder class.

Additional hooks, mostly for all relation types, are:

  • Model::hasOne

Installation

Clone the repo or pull as composer dependency:

composer require codedge/hookable

Usage

Please see the original package for usage.