bfg/admin-audit

The auditing viewer for bfg admin

Installs: 9 040

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 2

Forks: 0

Open Issues: 0

Type:bfg-admin-extension

0.1.3 2023-12-26 21:47 UTC

This package is auto-updated.

Last update: 2024-04-26 22:39:26 UTC


README

Laravel Logo

Total Downloads Latest Stable Version License

Install

composer require bfg/admin-audit

Admin install

php artisan admin:extension bfg/admin-audit --install

Setup auditing

For more information on how to use the package, please refer to our official documentation available on laravel-auditing.com or in the repository documentation file. Our documentation provides detailed instructions on how to install and use the package, as well as examples and best practices for auditing in Laravel applications.

Publish configs

php artisan vendor:publish --provider "OwenIt\Auditing\AuditingServiceProvider" --tag="config"

Publish migrations

php artisan vendor:publish --provider "OwenIt\Auditing\AuditingServiceProvider" --tag="migrations"

Migrate

php artisan migrate

Enable console audit

Open configs/audit.php and enable console config:

...
   /*
    |--------------------------------------------------------------------------
    | Audit Console
    |--------------------------------------------------------------------------
    |
    | Whether console events should be audited (eg. php artisan db:seed).
    |
    */

    'console' => true,
...

Add audit to model

Add implement

use OwenIt\Auditing\Contracts\Auditable;
...
class User extends Authenticatable implements Auditable
{
    use \OwenIt\Auditing\Auditable;
    
    ...
}