GuardsAttributes
trait GuardsAttributes (View source)
Properties
Methods
Get the fillable attributes for the model.
Set the fillable attributes for the model.
Merge new fillable attributes with existing fillable attributes on the model.
Get the guarded attributes for the model.
Set the guarded attributes for the model.
Merge new guarded attributes with existing guarded attributes on the model.
Disable all mass assignable restrictions.
Enable the mass assignment restrictions.
Determine if the current state is "unguarded".
Run the given callable while being unguarded.
Determine if the given attribute may be mass assigned.
Determine if the given key is guarded.
Determine if the given column is a valid, guardable column.
Determine if the model is totally guarded.
Get the fillable attributes of a given array.
Details
$this
mergeFillable(array $fillable)
Merge new fillable attributes with existing fillable attributes on the model.
$this
mergeGuarded(array $guarded)
Merge new guarded attributes with existing guarded attributes on the model.
protected bool
isGuardableColumn(string $key)
Determine if the given column is a valid, guardable column.