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

Cart items can not be exceeded then Maximum quantity #35

Open
nomi-ramzan opened this issue Aug 25, 2015 · 2 comments · May be fixed by #42
Open

Cart items can not be exceeded then Maximum quantity #35

nomi-ramzan opened this issue Aug 25, 2015 · 2 comments · May be fixed by #42

Comments

@nomi-ramzan
Copy link

Hi
In cart view using + button you can exceed the max quantity of item. like if you have max 1 quantity in cart view you can add more then 1 items.
1st suggestion can be before this line we can add
if(this._data.quantityMax && this._data.maxQuantity < ( this._quantity+quantityInt )) return;
Exactly that variable which we are using here like
<ngcart-addtocart id="{{ item.id }}" name="{{ item.name }}" price="{{ item.price }}" quantity="{{item.quantity}}" quantity-max="{{ item.maxQuantity }}" data="item">Add to Cart</ngcart-addtocart>
In my case maxQuantity is that variable which can be use for this.

Best regards

@celsomtrindade
Copy link

Same here.
On the cartView i can add infinite items with the '+' button.
But on the page view, the amount is limited correctly.

Also, if we change the amount on the cartView, the number from the select option on the pageView doesn't update.

@sateesh2499
Copy link

sateesh2499 commented Sep 21, 2016

I am also facing the same issue. Seems like this issue is not fixed yet. How to get maximum quantity value in cart view so that I can restrict the increment of quantity.

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

Successfully merging a pull request may close this issue.

3 participants