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

Product page : can't change the quantity via input, the quantity 1 is always displayed #642

Conversation

boherm
Copy link
Member

@boherm boherm commented Jul 1, 2024

Questions Answers
Description? The way of listening quantity input in product page is a problem.
In fact, we need to check quantity min not when we are typing but only on change. If we do this check on keyup or keydown, we can't type a backspace to empty the input before typing our new value, and also, if the min quantity of the product is set at 5, if we want to type 10 after a backspace, we force to 5 when the 1 key is typed and before the 0 of 10.
Type? bug fix
BC breaks? no
Deprecations? no
Fixed ticket? Fixes #36456
Sponsor company PrestaShop SA
How to test? See #36456

@boherm boherm requested a review from florine2623 July 1, 2024 14:53
@florine2623 florine2623 self-assigned this Jul 1, 2024
Copy link

@florine2623 florine2623 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello @boherm ,

Thanks for the PR !

Tested with/out debug mode.
Tested with minimum quantity ≠ 1.
Tested with Combination products.
Tested with backspace key, arrows, and select input to change quantity.

LGTM ✅

Screen.Recording.2024-07-01.at.17.29.05.mov

@boherm boherm merged commit 55999f5 into PrestaShop:develop Jul 1, 2024
6 checks passed
@boherm boherm deleted the #36456-fix-qte-input-behaviour-in-product-page branch July 1, 2024 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

hummingbird - Product page : can't change the quantity via input, the quantity 1 is always displayed
4 participants