Download the PHP package alkhachatryan/laravel-loggable without Composer
On this page you can find all versions of the php package alkhachatryan/laravel-loggable. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download alkhachatryan/laravel-loggable
More information about alkhachatryan/laravel-loggable
Files in alkhachatryan/laravel-loggable
Package laravel-loggable
Short Description Laravel Loggable - Log your model changes in multiple ways.
License MIT
Informations about the package laravel-loggable
Laravel Loggable - Log you model changes
Laravel Loggable is a package for eloquent models, which will monitor the changes on the models and log. It supports two drivers: File and Database.
Features
- High-configurable
- Two drivers (database and file)
- Possibillity to use two drivers at once
- Possibillity to select the columns for the model which should be logged
- Possibillity to select the actions for the model which should be logged (create, edit, delete)
- Facade-based structure to fetch the logs for specific model
- Much more
Installation
Install the package.
composer require alkhachatryan/laravel-loggable
Publish the configuration file
php artisan vendor:publish --tag=loggable
Run migration
php artisan migrate
Configuration
Open the configuration file at /config/loggable.php
Set the driver whhich will log the model changes (can be both). However, it's recommended to use the database driver so you can fetch the logs in the future.
That's it!
Usage
Retriving the model logs via Facade
Retriving the model logs via Model
Event
You can use the event Alkhachatryan\LaravelLoggable\Events\Logged in pair with your listeners.
Changelog
Please see CHANGELOG for more information what has changed recently.
Todo
Tests!!! Tests!!! Tests!!!
Security
If you discover any security-related issues, please email [email protected] instead of using the issue tracker.
License
The MIT License (MIT). Please see License File for more information.