I have a quick question that I feel should be easy but somehow isn’t working for me.
I have an App Variable called “bank”, which is type Object with two properties: id (text), shares (array of numbers).
I also have a Page Variable called “amount” of type Number with the value 2, and another Page Variable called “property” of type Number with the value 1.
In a previous page I set the values in the ‘shares’ array to be [9,9,9,9,9,9,9,9,9].
What I would like to do now is set a specific array item (using “property” as the index) to the “amount” value via the Set app variable flow function.
In the ‘variable name’ I select “bank”, then “shares” and in the UI of composer the variable name is populated to read ‘bank.shares’.
Then I am lost on what to put in the ‘assigned value’ box below.
I thought of putting a formula in ‘variable name’ input field but the only two options I have is App Variable and Output of another node.
To resume: how do I execute the following operation using the Inputs provided in the Composer UI for the ‘Set app variable’ flow function
appVars.bank[property] = amount
With the result that the App Variable bank.shares would be [2,9,9,9,9,9,9,9]