Filament Table

How can I show $table->json('data') for repeater in filament table?
4 Replies
Patrick Boivin
Not sure if this is the best approach but I think I would use formatStateUsing, and call a method on the record to prepare the JSON into something that makes sense for the column:
TextColumn::make('my_field')
->formatStateUsing(fn ($record): string => $record->formatRepeaterData()))
TextColumn::make('my_field')
->formatStateUsing(fn ($record): string => $record->formatRepeaterData()))
Shaung Bhone
Shaung BhoneOP2y ago
Where the formatRepeaterData is come from?
Patrick Boivin
This would be a method on your model
Shaung Bhone
Shaung BhoneOP2y ago
Ok
Want results from more Discord servers?
Add your server