Download the PHP package ebola/logging without Composer
On this page you can find all versions of the php package ebola/logging. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download ebola/logging
More information about ebola/logging
Files in ebola/logging
Package logging
Short Description Logging for PHP 7.1 and package spatie/laravel-activitylog
License MIT
Homepage https://github.com/VSiniy/test-laravel-packages
Informations about the package logging
Save and display global logs with log activity from Laravel Activitylog v.2
This Laravel >=5.5 package. It provides a simple API to work with and version Laravel Activitylog. To learn all about Laravel Activitylog, head over to the extensive documentation.
Here are a few short examples of what you can do:
It can display all user activity on front:
Or display form for download users activity:
Installation
You can install this package via composer using this command:
Next, you must install the service provider:
And add aliase:
You must publish activitylog migration:
You must migrate:
You can optionally publish the activitylog config file:
You can publish the views with:
You can publish the assets with:
You can publish the translations with:
You can publish the config-file with:
This is the contents of the published config file:
Usage
You can log users routing, user activity and mails:
You can log models events:
Display logs
You must make object of LoggingRender class. You can transfer as a parameter the user object to display only its logs, as well as a list of fields to display on the screen or save them. If the values are not transferred, you will output all the logs with the fields specified in the config file.
You have two protected methods for display logs:
If you use rendering methods, do not forget to call css and js for the correct display:
In each of them, methods are available to retrieve records and create a file to load it
There are also 2 static classes to help in the output of the properties of the logged models and the display of filters
License
The MIT License (MIT). Please see License File for more information.