{"id":28479263,"url":"https://github.com/scolib/laravel-action-log","last_synced_at":"2025-10-04T00:21:48.877Z","repository":{"id":62541304,"uuid":"89337140","full_name":"ScoLib/laravel-action-log","owner":"ScoLib","description":"Logging user actions into the database for Larave v5.*","archived":false,"fork":false,"pushed_at":"2018-04-19T05:41:03.000Z","size":45,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-03T09:41:48.250Z","etag":null,"topics":["action","laravel","log","scolib"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ScoLib.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-04-25T08:35:43.000Z","updated_at":"2021-09-18T06:20:09.000Z","dependencies_parsed_at":"2022-11-02T16:15:57.594Z","dependency_job_id":null,"html_url":"https://github.com/ScoLib/laravel-action-log","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/ScoLib/laravel-action-log","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScoLib%2Flaravel-action-log","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScoLib%2Flaravel-action-log/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScoLib%2Flaravel-action-log/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScoLib%2Flaravel-action-log/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ScoLib","download_url":"https://codeload.github.com/ScoLib/laravel-action-log/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ScoLib%2Flaravel-action-log/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267298357,"owners_count":24065880,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-27T02:00:11.917Z","response_time":82,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["action","laravel","log","scolib"],"created_at":"2025-06-07T18:08:42.478Z","updated_at":"2025-10-04T00:21:43.849Z","avatar_url":"https://github.com/ScoLib.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Laravel Action Log\n\n[![StyleCI][ico-styleci]][link-styleci]\n[![Latest Version on Packagist][ico-version]][link-packagist]\n[![Software License][ico-license]](LICENSE.md)\n[![Build Status][ico-travis]][link-travis]\n[![Coverage Status][ico-scrutinizer]][link-scrutinizer]\n[![Quality Score][ico-code-quality]][link-code-quality]\n[![Total Downloads][ico-downloads]][link-downloads]\n\n## Install\n\n### Laravel 5.5.*\n\n``` bash\n$ composer require scolib/laravel-action-log:1.3.*\n```\n\nLaravel 5.5 uses Package Auto-Discovery, so doesn't require you to manually add the ServiceProvider.\n\n### Laravel 5.4.*\n\n``` bash\n$ composer require scolib/laravel-action-log:1.2.*\n```\n\nAdd the ServiceProvider to the `providers` array in `config/app.php`\n\n```php\n\\Sco\\ActionLog\\LaravelServiceProvider::class,\n```\n\nIf you want to use the facade to logging actions, add this to the `aliases` array in `config/app.php`\n\n```php\n'ActionLog' =\u003e Sco\\ActionLog\\Facade::class,\n```\n\n## Publish config file\n\nCopy the package config to your local config with the publish command:\n\n```php\nphp artisan vendor:publish --provider=\"Sco\\ActionLog\\LaravelServiceProvider\"\n```\n\nDefault action log table name is `action_logs`, If you want to customize it, edit the `config/actionlog.php`\n\nNow run the artisan migrate command:\n```php\nphp artisan migrate\n```\n\n## Usage\n\n### Method 1\n\nOverride the property `$events` in your Model\n\n```php\n    protected $events = [\n        'created'  =\u003e \\Sco\\ActionLog\\Events\\ModelWasCreated::class,\n    ];\n```\n\n\u003e ⚠ Note: Laravel 5.5   \n\u003e Renamed `$events` to `$dispatchesEvents` ([#17961](https://github.com/laravel/framework/pull/17961), [b6472bf](https://github.com/laravel/framework/commit/b6472bf6fec1af6e76604aaf3f7fed665440ac66), [3dbe12f](https://github.com/laravel/framework/commit/3dbe12f16f470e3bca868576d517d57876bc50af))\n\nAll available event\n\n```php\n[\n    'created'   =\u003e \\Sco\\ActionLog\\Events\\ModelWasCreated::class,\n    'deleted'   =\u003e \\Sco\\ActionLog\\Events\\ModelWasDeleted::class,\n    'restored'  =\u003e \\Sco\\ActionLog\\Events\\ModelWasRestored::class,\n    'saved'     =\u003e \\Sco\\ActionLog\\Events\\ModelWasSaved::class,\n    'updated'   =\u003e \\Sco\\ActionLog\\Events\\ModelWasUpdated::class,\n    'creating'  =\u003e \\Sco\\ActionLog\\Events\\ModelWillCreating::class,\n    'deleting'  =\u003e \\Sco\\ActionLog\\Events\\ModelWillDeleting::class,\n    'restoring' =\u003e \\Sco\\ActionLog\\Events\\ModelWillRestoring::class,\n    'saving'    =\u003e \\Sco\\ActionLog\\Events\\ModelWillSaving::class,\n    'updating'  =\u003e \\Sco\\ActionLog\\Events\\ModelWillUpdating::class,\n]\n```\n\n### Method 2\nManual logging actions\n\n```php\n// use event\nevent(new \\Sco\\ActionLog\\Events\\ManualEvent($type, $content));\n\n// use factory\n\\Sco\\ActionLog\\Factory::info(LogInfo $info);\n```\n\n\n## Change log\n\nPlease see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.\n\n## Contributing\n\nPlease see [CONTRIBUTING](CONTRIBUTING.md) and [CONDUCT](CONDUCT.md) for details.\n\n## Security\n\nIf you discover any security related issues, please email slice1213@gmail.com instead of using the issue tracker.\n\n## Credits\n\n- [klgd][link-author]\n- [All Contributors][link-contributors]\n\n## License\n\nThe MIT License (MIT). Please see [License File](LICENSE.md) for more information.\n\n[ico-styleci]: https://styleci.io/repos/89337140/shield?branch=master\n[ico-version]: https://img.shields.io/packagist/v/ScoLib/laravel-action-log.svg?style=flat-square\n[ico-license]: https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square\n[ico-travis]: https://img.shields.io/travis/ScoLib/laravel-action-log/master.svg?style=flat-square\n[ico-scrutinizer]: https://img.shields.io/scrutinizer/coverage/g/ScoLib/laravel-action-log.svg?style=flat-square\n[ico-code-quality]: https://img.shields.io/scrutinizer/g/ScoLib/laravel-action-log.svg?style=flat-square\n[ico-downloads]: https://img.shields.io/packagist/dt/ScoLib/laravel-action-log.svg?style=flat-square\n\n[link-styleci]: https://styleci.io/repos/89337140\n[link-packagist]: https://packagist.org/packages/ScoLib/laravel-action-log\n[link-travis]: https://travis-ci.org/ScoLib/laravel-action-log\n[link-scrutinizer]: https://scrutinizer-ci.com/g/ScoLib/laravel-action-log/code-structure\n[link-code-quality]: https://scrutinizer-ci.com/g/ScoLib/laravel-action-log\n[link-downloads]: https://packagist.org/packages/ScoLib/laravel-action-log\n[link-author]: https://github.com/klgd\n[link-contributors]: ../../contributors\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscolib%2Flaravel-action-log","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fscolib%2Flaravel-action-log","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscolib%2Flaravel-action-log/lists"}