I’m followed the tutorial for shopping cart using Data Store and all is working fine, except the check out part, where I need to record to the database the data from data store.
Below, my checkout page, where I show the cart content, complementary fields and a hidden repeat with the data from my shopping cart:
Now, I would like to insert a “order” to my database table + order details (cart data).
Before create all all the steps, I need to define my posts variables, importing from the checkout form, but the “repeat” doesn’t import as an array and I can’t use Multi-Insert Query:
Thanks Ben! I made a lot of validations using the Data Store already, change everything to local storage + arrays at this time of my project is a not a good idea
What I’m trying to do is wrong? Data Store is an array too, right?
I just tried to convert the data store to an array (flow) and using the array in the repeat, but the problem remains the same…
Also the customer (which is created in the insert_customer step is added to this table to the customer field, which is also of the Reference type.
For some reason which I can’t point out, the customer and order_lines data stay empty and are not inserted. Anyone a suggestion what might be the cause of this?