F
Filament10mo ago
D5300

Set description for CheckboxList dynamically

Hi, how can I access the collection which is loaded from the relations method? I dont see how I can access the relationship data
CheckboxList::make('menuSections')
->hiddenLabel()
->relationship('sections', 'title')
->descriptions(function ($collection) {
return $collection->pluck('description', 'id')->toArray();
})
->bulkToggleable()
CheckboxList::make('menuSections')
->hiddenLabel()
->relationship('sections', 'title')
->descriptions(function ($collection) {
return $collection->pluck('description', 'id')->toArray();
})
->bulkToggleable()
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server