laravel attribute model code example
Example: laravel add attribute to model
$user = User::find(1);
// add occupation to user instance
$user->setAttribute('occupation', 'Web Developer');
$user = User::find(1);
// add occupation to user instance
$user->setAttribute('occupation', 'Web Developer');