Searchable select using model's attribute as label
Hi all,
I have a model
However, I have a problem creating a new Pet for a specific User:
The problem is, that no matter what I do in
Thank you.
I have a model
Pet, that belongs to User: However, I have a problem creating a new Pet for a specific User:
The problem is, that no matter what I do in
getSearchResultsUsing and getOptionLabelUsing, I won't get User's fullName to be shown. I tried:- Using
pluck('last_name', 'id')instead ofget. This shows thelast_name, butgetOptionLabelUsingis not called. - Using
relationship('owner', 'last_name'). This does not allow usingfullNameinstead oflastName.
Thank you.