How do I reset the state of a repeating group?

Use Case:

I have a job opening with a checklist. This checklist is a repeating group, where users select which documents are required for this specific job opening. In this repeating group, I have a custom state where it turns “yes” if currently selected by users, (which means that the specific document is required for the specific job opening). Then no if not selected.

Everything works fine, however the issue is when everthing is submitted, the custom states remains the same as per previous submission / selection. So I am looking at, how do I reset the custom states back to “no” for each item in the repeating group as soon as the form is submitted?

In the photo example, I left “super choice form” not being selected then proceed with data creation, etc… When redo the entire process (e.g. Add another job opening), I get the same checklist where super choice form is left blank (as per my previous input).

Thanks All.

What does your state look like? If you have a state called “Selected Job Openings” that is a list of Job Openings, you can simply use the :plus item and :minus item operators to add and remove job openings when the user ticks or unticks a checkbox. When the form is submitted, you simply set the state to be an empty list.

If that didn’t make sense, this video explains the concept for a slightly different use-case, but the structure is the same:

This topic was automatically closed after 70 days. New replies are no longer allowed.