Backend workflow for bulk add things from an option set list

Hi Bubble Makers,
I am creating an app for a training records managment system, and am struggling with how to map a training document for each user role. The list of user roles is kept in an option set, and simply consists of a text field (e.g. Staff, Board Member, Interpreter, etc.)

The illustration of the pop-up form below shows what I am trying to accomplish.
Prior to the pop-up form, the user clicks a button on a newly created document, which populates the pop-up with the current document. For a new document, the repeating group will be empty.


What I would like to accomplish is when the user clicks the + button, the repeating group will be populated with all current roles and the list of exposure type being blank.

The user can then select the exposure type for how the training will be measured.

Table setup for trainingMatix:
|Field Name | Field Type|

|— | —|
|Document | Document (table)|
|Exposure | osExposure (option set)|
|UserRole | osUserRole (option set)|
| | |
| | |
| | |
Data setup:
Document
trainingMatrix
userRole | Text
exposureType | Option Set

I know this will have to be done through a backend workflow, but I’m not sure how to loop through the list of userRoles to add to the trainingMatrix table.

Any guideance would be appreciated.

Schedule API workflow on a list should help? It supports option sets too.

1 Like

This worked!!!
I had to do a bit of tweaking, but it worked.
Thanks for the advice!

1 Like