I am using the package in my Laravel app to log the model's edits.
In addition to this, I have also implemented a supervisor class to listen to specific model events (updates, delete, etc.) and to listen to actions (like clear cache etc.). This supervisor has been given an immediate form in the model using the boot ()
method:
class client {use \ vecherrachraft \ revisionable \ modifed; Public Stable Function Boot () {Origin: Boot (); Client :: Inspection (new app / observer / client observer); }}
What do I know that when I define a boot ()
method in my model, the modified attribute stops working And does not log changes - possibly because it also uses a boot
method that is being overridden by one in the model.
How do I fix this to allow the model to use the modified package as well?
This link helped me
I Used in Laravel 5.1 I hope this will work for you
Use RevisionableTrait, UuidTrait {UuidTrait :: RevisionableTrait instead of Boot; }
Comments
Post a Comment