FilamentF
Filament15mo ago
Juju

$data does not contain Detail Data from Repeater

I have Master Detail create form with Repeater to handle the detail data input. How can I access the detail data in the repeater before and after save?

here is the code of the repeater:
Repeater::make('details')
                                ->label('')
                                ->relationship('details')
                                ->schema([
                                    TextInput::make('details.name')
                                        ->label('Nama Pemesan')
                                        ->autocapitalize('words')
                                        ->minLength(3)
                                        ->validationAttribute('Nama pemesan')
                                        ->validationMessages([
                                            'min' => ':attribute harus lebih dari 3 karakter',
                                            'required' => ':attribute tidak boleh kosong',
                                        ])
                                        ->required()
                                        ->autofocus(),



If it's only master I use mutateFormDataBeforeCreate() and handleRecordCreation().

Thank you in advance
Was this page helpful?