Hi FlutterFlow Community,
I'm trying to create an app-wide action block in FlutterFlow that involves a loop to add entries to a list in a Firebase document.
The loop needs to:
Add X entries of type A.
Add Y entries of type B.
*A and B are enums. X and Y are variables. It needs to be ordered as in AAABB.
Since this is an app-wide action block, I can't use a local page variable for the index. I need to track the index position within the loop.
How can I manage the index position in this loop? Is there a way to use global variables or another method to keep track of the current loop index?
Any detailed steps or guidance would be greatly appreciated!
Thanks!