Open dartandrevinsky opened 3 years ago
Presently:
The above commit backs these UI changes:
Presently the UI looks thus:
POST <api>/cart
Description: Creates a new cart object
Body: <empty>
Response:
{
id, // id of the cart
items // Array<CartItem>
}
PUT <api>/cart/:cartId
Description: Updated the cart item's quantity or adds one to it
Body:
{
cartId, // id of the current cart
restaurantId, // id of the restaurant the menu item belongs to
itemId, // id of the menu item
qty // desired quantity of the item in the cart
}
Response:
// CartItem:
{
id,
count,
meta: {
restaurantId
}
}
Empty tray:
Tray with Items:
Subtotal added:
Use this sketch as a guideline: