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

Reset quantity value to min value after adding to cart #11661

Merged
merged 2 commits into from Dec 20, 2018

Conversation

Projects
None yet
6 participants
@jolelievre
Copy link
Contributor

jolelievre commented Dec 7, 2018

Questions Answers
Branch? develop
Description? Reset quantity value to min value after adding to cart
Type? improvement
Category? FO
BC breaks? no
Deprecations? no
Fixed ticket? Fixes #9743
How to test? Add a product to your cart after changing the quantity, preferably one which has a min quantity superior to 1, and at the best with some discount depending on the quantity. After the product is added to the cart the quantity field is automatically updated to "min value" and the promotion is no longer visible.

This change is Reviewable

@jolelievre jolelievre added this to the 1.7.6.0 milestone Dec 7, 2018

Show resolved Hide resolved themes/_core/js/product.js Outdated
return;
}
const $productActions = $('.product-actions');
const $quantityWantedInput = $productActions.find('#quantity_wanted:first');

This comment has been minimized.

@PierreRambaud

PierreRambaud Dec 10, 2018

Contributor

#quantity_wanted:first it's an idea, you don't need to add :first and select it from .product-actions, you need to fix the duplicate id :/

This comment has been minimized.

@jolelievre

jolelievre Dec 10, 2018

Contributor

I actually simply copied the existing code, but indeed the :first is useless since there is only one element with this id. I corrected it in other places as well.

@PierreRambaud
Copy link
Contributor

PierreRambaud left a comment

Wrong selectors

@PierreRambaud
Copy link
Contributor

PierreRambaud left a comment

❤️

@marionf marionf self-assigned this Dec 14, 2018

@marionf

This comment has been minimized.

Copy link
Contributor

marionf commented Dec 17, 2018

@jolelievre I see changes requested but the issue is in to be tested column, is it ready for QA or you need to make changes ?

@jolelievre

This comment has been minimized.

Copy link
Contributor

jolelievre commented Dec 17, 2018

Yes, changes have been merged in the meantime. I think it's safer if I rebase it before testing.

@jolelievre jolelievre force-pushed the jolelievre:reset-quantity branch from 230ef44 to 0c47453 Dec 17, 2018

@jolelievre jolelievre force-pushed the jolelievre:reset-quantity branch from 0c47453 to c71e5a9 Dec 19, 2018

@marionf marionf removed their assignment Dec 19, 2018

@Quetzacoalt91 Quetzacoalt91 merged commit 2160d12 into PrestaShop:develop Dec 20, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment