I have a page displaying a deck on model “programs.” A click interaction opens a modal that displays a table of eligible enrollees from another model (“contacts”). I’d like to add a mass action that will create one row for each contact selected in another model (“enrollments”) which will have the selected contact’s Id and the modal’s “program Id.”
I have tried several options:
A) On the click interaction (on the deck), I create a new row in a temporary model called “selectedProgram” which successfully prepopulates the id of the program. In the mass action on the “contacts” table, I specify create rows on my “enrollments” model and select the Program Id from the “selectedProgram” model, but it does not work.
B) I gave a unique Id to my modal “enrollModal” and tried using mustaches to grab the Id, but I must be doing something wrong, because I can’t get it to populate.
C) I tried selecting use a field from another model, but that always returns the first row, and I need the row in context of the modal.
D) I tried setting context on the “contacts” but there is no direct link to Programs.