Save record and repeater with all Relationships on add item click
I'm trying to figure out how to save a record and all entries on the page while editing a repeater component.
I thought about going over the getCachedExistingRecords method and saving the state one by one. But that produces kinda unexpected behaviour. For example when deleting items from the repeater.
Do you have any hint for the right direction?
3 Replies
Bump
Is this save on the edit or save on the create? The issue you have with create is theres no record so really you then need to go to edit.
If doing edit, you should be able to just save after state updated run save method?
Okay, fair point.
I had issues on the edit page.
I have the record, a related hasMany Repeater and within a hasMany select.
And I want to save the state of all on addItem button click.
Can I really just hook into the stateUpdated event for this?