Download the PHP package mazyvan/userstamps without Composer
On this page you can find all versions of the php package mazyvan/userstamps. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download mazyvan/userstamps
More information about mazyvan/userstamps
Files in mazyvan/userstamps
Package userstamps
Short Description A fork from WildSide. Eloquent trait to automatically maintain created_by and updated_by (and deleted_by when using SoftDeletes) on your models
License MIT
Informations about the package userstamps
Mazyvan/Userstamps
MAYBE UNSTABLE. READ BELOW
Warning: This is a fork from WildSideUK/Laravel-Userstamps that doesn't fire the laravel "update" events on deletions. It's only purpouse is for the Virtuamx team to work with this lib while the WildSideUK team check for the issue 23. If they approve the pull request. This fork will be deprecated.
Stability Important Note: I have experienced issues with this plugin using Passport. This issue is reported here -> https://github.com/WildSideUK/Laravel-Userstamps/issues/17
So I tried the solution of setting manually the 'web'
guard. This plugin also have that workaround.
I think you should not have problems unless you use different models for your 'web' and 'api' logins. That's my thoughts.
Provides an Eloquent trait to automatically maintain created_by and updated_by (and deleted_by when using SoftDeletes) on your models.
Requirements
- This package requires PHP 5.6+
- It works with Laravel 5.x (and may work with earlier versions too).
Installation
Require this package with composer
`
Migrate your Model's table to include a created_by
and updated_by
(and deleted_by
if using SoftDeletes
).
Load the trait in your Model.
The following methods become available on your models to help retrieve the users creating, updating and deleting (if using SoftDeletes).
If you want to manually set the created_by
or updated_by
properties on your model you can stop Userstamps being automatically maintained using the stopUserstamping
method.
If you want to define the created_by
, updated_by
, or deleted_by
column names, add the following class constants to your model(s).
License
This open-source software is licensed under the MIT license.
All versions of userstamps with dependencies
illuminate/support Version 5.0.*|5.1.*|5.2.*|5.3.*|5.4.*|5.5.*|5.6.*|5.7.*