z-song / laravel-admin

Build a full-featured administrative interface in ten minutes
https://laravel-admin.org
MIT License
11.13k stars 2.81k forks source link

how to get pivot values from a form? #5729

Closed r-shaygan closed 1 year ago

r-shaygan commented 1 year ago

$form->multipleSelect('roles','Role')->options(Role::all()->pluck('name','id'));

in the code above we can just get the related model value.. what if it has pivot fields?