Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

updateCart #11

Closed
macrozone opened this issue Feb 23, 2019 · 3 comments
Closed

updateCart #11

macrozone opened this issue Feb 23, 2019 · 3 comments
Labels
enhancement New feature or request

Comments

@macrozone
Copy link
Contributor

currently, checkout and addCartProduct works without providing the orderId of the cart.

on the other hand, if you want to update the order with e.g. the billig address, you have to know the orderID.

introduce a updateCart mutation to fix that

@pozylon
Copy link
Member

pozylon commented Feb 23, 2019

Yeah lack of consistency.

Also, the current implementation of checkout and addCartProduct needs to be redone: We have a big feature request at a customer who needs to have multiple carts per user for his requirements. I guess we could fix this while implementing the new "Multi-Cart" feature, consistently asking for the orderId to update.

@pozylon
Copy link
Member

pozylon commented Feb 26, 2019

I will solve these requirements like this:

New cart convenience mutations:

  • updateCart

Renamed (BREAKING):

  • checkout to checkoutCart

New order manipulating mutations in preparation of "multi-cart":

  • checkoutOrder
  • addOrderProduct
  • updateOrderItemQuantity
  • removeOrderItem
  • addOrderDiscount
  • removeOrderDiscount

That way, a very simple checkout is possible without fetching the orderId once in one big query but the full feature set is only available when using the indirect methods.

@pozylon pozylon added the enhancement New feature or request label Feb 26, 2019
@pozylon
Copy link
Member

pozylon commented Feb 26, 2019

Done in PR #18

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants