LaravelPackages.net
Acme Inc.
Toggle sidebar
hpolthof/laravel-eloquent-settings

Allow for dynamic blobbed settings in Eloquent models.

52
1
v0.1.7
About hpolthof/laravel-eloquent-settings

hpolthof/laravel-eloquent-settings is a Laravel package for allow for dynamic blobbed settings in eloquent models.. It currently has 1 GitHub stars and 52 downloads on Packagist (latest version v0.1.7). Install it with composer require hpolthof/laravel-eloquent-settings. Discover more Laravel packages by hpolthof or browse all Laravel packages to compare alternatives.

Last updated

Allow for dynamic blobbed settings in Eloquent models.

This package was created for an internal project, but as the idea is reusable, I encourage others to make use of this package.

The main goal was to create a way to store variables dynamicly into a database field without having to rewrite the database structure.

Usage

Just use the HasSettings trait in your Eloquent model and add a field named settings to your table with a type of MEDIUMTEXT.

You can also use another field name, but be sure to set the protected $settingsField to that specific fieldname.

Star History Chart