NAPOSCA / pantryplus

A curbside service for food pantries
http://pantryplus.herokuapp.com
Apache License 2.0
2 stars 0 forks source link

Shopping view adds all items to the cart with id=1L #74

Closed alexjamesmalcolm closed 6 years ago

alexjamesmalcolm commented 6 years ago

This is because JavaScript was hardcoded with the cartId=1 and doesn't depend on the cartId parameter the shopping view was passed. JavaScript should have a way to grab the parameter from the URL to use when calling the add/remove item methods.

alexjamesmalcolm commented 6 years ago

Since your branch that you're working on fixes this I've assigned it to you.

alexjamesmalcolm commented 6 years ago

LineItems should get assigned to user's current cart for that session, rather than all getting assigned to cart 1 because cart 1 is currently hard-coded into JS AJAX requests