On an ecommerce feature,
On click of this cart button,
- a cart is created for the chosen item.
- I also create a custom states to hold this item like below.
- carts to order: a list of Carts
- Never mind the value part : Button shopping button bla bla… I just switched the custom states name.
After adding multiple items to this custom states (as well as the same number of created carts, each of which holds store each item), a ORDER button is clicked to create an order.
with the below workflow.
I’ve done this several times without any problem. Actually, before I revamped this project, this part worked fine.
The result is
The carts stored in the custom states are not saved in the db. But, in the later part of the above workflows, I make change to the carts to add this order and the result is
Order is well added to the carts.
I’ve been on this issue for 2 days now, but I failed to figure out what I am doing wrong.
Any help/comment?
Thanks.