Hi I would like to access a field of a parent Repeated Group inside a nested repeated group, just how Loops work for example in PHP.
What I want to do:
- I loop over Projects (parent repeated group)
- In every single Project I loop over the 7 days of the week (child repeated group)
- I show the names of the days of the week: Mon, Tue, Wed, etc.
- When I click on a day for example “Mon” then I want to save: The day(child) + project(parent) inside another data type called "Packages"
What i cannot do:
When I click on “Mon” I cannot access the Project from the parent repeated group, but only the day of the week (“Mon”) from the current child repeated group (days of the week).
Question:
Is it possible to get access to the Project name of the parent repeated group inside the element of the child repeated group?
I found the solution! You need to make:
- Create Repeated group named Projects - Repeated Group
- Set Repeated group “Type of content” (in this case Project)
- Set “Data source” to Search for Projects
- Create group inside Repeated group named Project item - Group
- Set group “Type of content” to Project
- Set “Data source” to “Current cell’s Project”
- Create repeated group (in this case “Dates - Repeated Group”) nested inside group (made at 4.)
- Set repeated group “Type of content” and Data source to what you want.
- You can now use Value’s from the upper parent Repeated group “Projects” by clicking “Insert dynamic data” (See screenshots)
4 Likes
Many thanks Ruben for this solution explanation which helped me a lot.
Another issue related to the nested repeating group : mine is sourced by a list in a page’s custom state, and is not updated when the list is updated outside the group, the nested repeating group is not refreshed automatically.
Any solution for that by any chance ?
A workflow “Repeating Group / display list” cannot work as the nested repeating group is not seen outside the group