astalpaert / laravel-blamable Goto Github PK
View Code? Open in Web Editor NEWBlamable Eloquent models for Laravel.
Blamable Eloquent models for Laravel.
Currently, the package does not take into account custom set values for any of the blameable fields.
Example: When creating an entity, and setting the created_by
value to a specific value, that value will not be persisted as desired.
This happens for all blameable fields and for each state (creating, updating, deleting).
The package should persist any manually set values.
When you use removeBlamableFields
on migration using SQLite (For example in unit tests) an exception is thrown.
I created a PR which demonstrates the bug.
1) Astalpaert\LaravelBlamable\Tests\Unit\Models\DummyModelTest::it_adds_created_by_when_creating with data set #0 ('default value', 'SYSTEM')
[19](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:20)
BadMethodCallException: SQLite doesn't support multiple calls to dropColumn / renameColumn in a single modification.
[20](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:21)
[21](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:22)
/home/runner/work/laravel-blamable/laravel-blamable/vendor/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php:156
[22](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:23)
/home/runner/work/laravel-blamable/laravel-blamable/vendor/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php:129
[23](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:24)
/home/runner/work/laravel-blamable/laravel-blamable/vendor/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php:108
[24](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:25)
/home/runner/work/laravel-blamable/laravel-blamable/vendor/laravel/framework/src/Illuminate/Database/Schema/Builder.php:363
[25](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:26)
/home/runner/work/laravel-blamable/laravel-blamable/vendor/laravel/framework/src/Illuminate/Database/Schema/Builder.php:210
[26](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:27)
/home/runner/work/laravel-blamable/laravel-blamable/vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php:337
[27](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:28)
/home/runner/work/laravel-blamable/laravel-blamable/tests/Support/Migrations/remove_blamable_fields.php.stub:21
[28](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:29)
/home/runner/work/laravel-blamable/laravel-blamable/tests/TestCase.php:42
[29](https://github.com/astalpaert/laravel-blamable/actions/runs/3199786523/jobs/5225947272#step:5:30)
/home/runner/work/laravel-blamable/laravel-blamable/tests/TestCase.php:16
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.