StoreMerge
class StoreMerge extendsFormRequest
Properties
LabelTree | $tree | The label tree to create/remove the labels of. | |
array | $create | Flat array of labels to create. | |
array | $remove | Array of label IDs to remove. |
Methods
Determine if the user is authorized to make this request.
Get the validation rules that apply to the request.
Configure the validator instance.
Validate the create labels.
Validate the remove labels.
Returns a flat list of a nested array of labels and assigns a parent_index to each label, which indicates the position of the parent label in the list (as opposed to a parent_id, sinde the labels have no ID yet).
Details
at line41
bool
authorize()
Determine if the user is authorized to make this request.
at line55
array
rules()
Get the validation rules that apply to the request.
at line69
void
withValidator(Validator$validator)
Configure the validator instance.
at line82
protected
validateCreate(Validator$validator)
Validate the create labels.
at line122
protected
validateRemove(Validator$validator)
Validate the remove labels.
at line159
protectedarray
getFlatLabels(array$labels,array$carry =[],int$index =-1)
Returns a flat list of a nested array of labels and assigns a parent_index to each label, which indicates the position of the parent label in the list (as opposed to a parent_id, sinde the labels have no ID yet).