Closed brianakidd closed 1 year ago
I wonder if this is a bug in the filament repeater or a livewire issue? Can you update to the latest filament and if the issue is still there try to replicate it in a regular repeater?
This plugin uses the filament repeater under the hood it just changes the layout. So there's nothing in the plugin, that I can think of, that would have a direct conflict with saving data.
@awcodes Sorry I'm just getting back to you. I changed my form to use the Filament Repeater and the value is retained after save. Seems odd if you are using the Filament Repeater in the background but I can confirm it is behaving differently. Let me know how I can help.
If you could provide a reproduction repo, that would be a huge help.
I've created the repo and found that during create, the TableRepeater Select retains the created relationship but during edit, it does not. Provided high-level steps to reproduce in the readme. Hope this helps.
https://github.com/brianakidd/filament-table-repeater-error.git
Thank you. I will look at it as soon as I can and get back to you.
Filament Version
v3
Plugin Version
v2
PHP Version
8.1
Problem description
Using a Form Select inside the repeater with a
createOptionForm
, the created option is saved and associated with the repeater relationship but, after save, the select is cleared. Refreshing the page then shows the select value.https://github.com/awcodes/filament-table-repeater/assets/6431835/5546f16b-01e7-47ce-b5ac-6b67b4aa6f45
Expected behavior
The expected behavior is that the select value would remain after saving.
Steps to reproduce
In a form, add the TableRepeater referencing a relationship and within the TableRepeater schema, include a Select with a createOptionForm. Open an existing record that contains the TableRepeater and attempt to add a new relationship by clicking the suffix create action then save.
Reproduction repository
No response
Relevant log output
No response