entrust icon indicating copy to clipboard operation
entrust copied to clipboard

add $fillable to EntrustRole & EntrustPermission

Open wgqi1126 opened this issue 9 years ago • 1 comments

by default $fillable is null, when use

$owner = Role::firstOrCreate([
            'name' => 'owner',
            'display_name' => 'Project Owner',
            'description' => 'User is the owner of a given project',
        ]);`

is cause MassAssignmentException because it can't fill field.

So is it possible add protected $fillable = ['name', 'display_name', 'description']; in EntrustRole & EntrustPermission?

wgqi1126 avatar Sep 09 '15 06:09 wgqi1126

Thought i'd bump this by saying the issue encountered is still present. Appreciate if not mass assigning attributes this isn't a problem, however when bulk assigning this is very useful.

mstephens avatar Oct 15 '15 14:10 mstephens