You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm encountering an issue with the React JSON Form library where omit and liveOmit functionality seems to be working only on onChange but not on onSubmit, particularly when the user proceeds to submit the form without making any changes. When I use omit or liveOmit to exclude certain fields from the form submission, it behaves as expected during user interaction (onChange), but the omitted fields still get submitted when the form is submitted (onSubmit) without any user modifications.
Is there a known workaround or configuration setting to ensure that omitted fields are also excluded from the final form submission (onSubmit) in cases where the user hasn't made any changes? Alternatively, is there a recommended approach to achieve omitting fields specifically on form submission?
Here's how you can replicate the issue in react playground:
Thank you for linking to me the related issue. I found the link very helpful, but needed an immediate fix. Given this, the solution we have come in the interim is to use a custom Widget that calls onChange with the desired data when the component is loaded.
Prerequisites
What theme are you using?
bootstrap-4
What is your question?
I'm encountering an issue with the React JSON Form library where omit and liveOmit functionality seems to be working only on onChange but not on onSubmit, particularly when the user proceeds to submit the form without making any changes. When I use omit or liveOmit to exclude certain fields from the form submission, it behaves as expected during user interaction (onChange), but the omitted fields still get submitted when the form is submitted (onSubmit) without any user modifications.
Is there a known workaround or configuration setting to ensure that omitted fields are also excluded from the final form submission (onSubmit) in cases where the user hasn't made any changes? Alternatively, is there a recommended approach to achieve omitting fields specifically on form submission?
Here's how you can replicate the issue in react playground:
Any insights or guidance on resolving this issue would be greatly appreciated!
The text was updated successfully, but these errors were encountered: