How i can load Models that belongs to user, if any selected.
A user can have some brands and models already in table, if a user selected, list should be only that belongs to user, otherwise load all models
In other words for brands ->load('model_id', '/admin/load-models') only brand id passed and available in controller, how i can pass additional criteria.
Description:
I have an optional user_id select/dropdown in form
$form->select('user_id', __('User'))->options(User::where([['status','=',1]])->pluck('name', 'id'));
and 2 more dropdown to load brands and models
How i can load Models that belongs to user, if any selected.
A user can have some brands and models already in table, if a user selected, list should be only that belongs to user, otherwise load all models
In other words for brands
->load('model_id', '/admin/load-models')
only brand id passed and available in controller, how i can pass additional criteria.Steps To Reproduce: