Modal preview of form coming form blade view

Hi I am trying to work out the best way of getting form data that is not saved in to my preview modal, at the moment I have a modal with a blade view, pulling in data that is saved in the db and it is working well, but im not sure the best way to pull in data to the modal on new additions to the form that are not yet saved? In my edit application resource I have
Action::make('preview')
->label('Preview Profile')
->icon('heroicon-o-eye')
->modalContent(function () {
$record = $this->getRecord();
$formData = collect($this->data)->except(['status'])->toArray();
$record->fill($formData);

return view('application.preview', [
'application' => $record,
'isPreview' => true
]);
})
->modalWidth('7xl')
Action::make('preview')
->label('Preview Profile')
->icon('heroicon-o-eye')
->modalContent(function () {
$record = $this->getRecord();
$formData = collect($this->data)->except(['status'])->toArray();
$record->fill($formData);

return view('application.preview', [
'application' => $record,
'isPreview' => true
]);
})
->modalWidth('7xl')
the rich editor changes are showing in preview but normal fields or selects are not, what is the best way to achieve a preview with changes that are not yet saves in fIlament as I may be going the wrong route, thanks
0 Replies
No replies yetBe the first to reply to this messageJoin

Did you find this page helpful?