Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[5.x] Update error indexes when sets/rows are removed #11341

Open
wants to merge 2 commits into
base: 5.x
Choose a base branch
from

Conversation

duncanmcclean
Copy link
Member

@duncanmcclean duncanmcclean commented Jan 10, 2025

This pull request attempts to fix an issue where errors in Replicator/Grid fields would be displayed on the wrong set/row after a set/row has been removed.

This PR attempts to fix it by updating the indexes in error keys whenever sets/rows are removed.

It's a bit gnarly... I'm not entirely convinced this is the right solution, so let me know if you can think of a better one.

Fixes #10704.
Fixes #11286.

return acc;
}, {});

this.$store.commit(`publish/${this.storeName}/setErrors`, errors);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like publish/storeName/setErrors updates the errors in the Vuex state, but it doesn't affect the errors property in the PublishForm component.... not sure if that'll end up being an issue? 🤔

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
1 participant