im using webflow plugin, i create at the start action state 2 variables in flow scope one as a map and the other one as a list, then i pick up values among states until state 3 i add does values to a map and finally add the map to a list, until here is fine, the problem is when i try to add a second item just when I add the second map to the list, all previous map are overwrites.
If i change does variables created in the start action from flow scope to session scope map are not overwrites.
any idea? i would like to use flow variables. thanks for your time
def controllerNameFlow = {
init {
flow.items = [:]
flow.itemsCollection = []
}
on("success").to "state1"
on("error").to "done"
state1 = {
flow.item = "abc"
}
on("confirm").to "state2"
state2 = {
flow.presentation = "a123"
}
on("confirm").to "state3"
state3 = {
flow.items.put("item", flow.item)
flow.items.put("presentation", flow.presentation)
flow.itemsCollection.add flow.items
}
on("confirm").to "state1"
}