Set custom data on RepeatableEntry
I need to set custom data on RepeatableEntry:
I'm returning an array with the title, description, and notified fields, but the data isn't displayed. The total is loading correctly, though.
Tables\Actions\ViewAction::make('generateNewsProd') //Esto para produccion
->hidden(fn(Model $record) => !$record->notifiedPapers)
->label('Generar Noticias')
->modalAutofocus(false)
->infolist([
RepeatableEntry::make('papers')
->label('Noticias Procesadas')
->schema([
TextEntry::make('title')->label('Título'),
TextEntry::make('description')->label('Resumen'),
TextEntry::make('notified')->label('Notificado'),
// TextEntry::make('additional_data')->label('Datos Adicionales'), // Campo adicional
Actions::make([
Action::make('generateNews')
->label('Generar Noticia')
->action(fn(array $data) => dd($data)) // Procesar la noticia
->icon('heroicon-o-document-text')
])
])
->default(fn (Model $record) => $record->getProcessedNews())
])Tables\Actions\ViewAction::make('generateNewsProd') //Esto para produccion
->hidden(fn(Model $record) => !$record->notifiedPapers)
->label('Generar Noticias')
->modalAutofocus(false)
->infolist([
RepeatableEntry::make('papers')
->label('Noticias Procesadas')
->schema([
TextEntry::make('title')->label('Título'),
TextEntry::make('description')->label('Resumen'),
TextEntry::make('notified')->label('Notificado'),
// TextEntry::make('additional_data')->label('Datos Adicionales'), // Campo adicional
Actions::make([
Action::make('generateNews')
->label('Generar Noticia')
->action(fn(array $data) => dd($data)) // Procesar la noticia
->icon('heroicon-o-document-text')
])
])
->default(fn (Model $record) => $record->getProcessedNews())
])I'm returning an array with the title, description, and notified fields, but the data isn't displayed. The total is loading correctly, though.