FilamentF
Filament2y ago
Phil

Update Form from Action Modal

I have a form with a repeater list. Products with prices can be added there.

To make a quick selection, there is an additional button that opens a modal where I can select many products at once.

How can I return the selected products to the create form, inside the action() method of the button, so that a repeater entry is created for each product?

As the data record has not yet been saved, I cannot use
->action(array $data, MyObj $obj) { $obj->products()->attach(...); })
2024-06-14_16_06_18-shopware-essentials_OfferResource.php.png
2024-06-14_16_06_43-Angebot_erstellen_-_Shopware_Essentials.png
Solution
maybe injecting Set $set ?
Was this page helpful?