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

Correct vouchers reductions display values in cart summary #16235



Copy link

matthieu-rolland commented Oct 31, 2019

Questions Answers
Branch? develop
Description? See below for display rules
Type? bug fix
Category? FO
BC breaks? no
Deprecations? no
Fixed ticket? Fixes #9702
How to test? See below

On the cart summary, where reductions are displayed, here are the rules that should be respected:

  • Cart rule with free shipping only: Display free shipping instead of 0,00%
  • Cart rule with free shipping + discount (amount or %): Display price of the carrier + Discount amount added
  • Cart rule with % discount: Display the discount amount (not the percentage)

This change is Reviewable

@matthieu-rolland matthieu-rolland requested a review from PrestaShop/prestashop-core-developers as a code owner Oct 31, 2019
return isset($cartVoucher['reduction_amount']) && $cartVoucher['reduction_amount'] > 0;

This comment has been minimized.

Copy link

matthieu-rolland Oct 31, 2019

Author Contributor

Those are three legacy conditions that I extracted in functions with a self explaining name for readability purpose.

@matthieu-rolland matthieu-rolland removed the WIP label Oct 31, 2019
matthieu-rolland and others added 2 commits Nov 4, 2019
Co-Authored-By: LouiseBonnard <>
Co-Authored-By: LouiseBonnard <>
matthieu-rolland and others added 2 commits Nov 5, 2019
Co-Authored-By: GoT <>
Co-Authored-By: GoT <>
@matks matks added the waiting for QA label Nov 5, 2019
@Robin-Fischer-PS Robin-Fischer-PS self-assigned this Nov 6, 2019
@Robin-Fischer-PS Robin-Fischer-PS added this to the milestone Nov 6, 2019

This comment has been minimized.

Copy link

matks commented Nov 6, 2019

Thank you @matthieu-rolland

@matks matks merged commit 8fb32b8 into PrestaShop:develop Nov 6, 2019
2 checks passed
2 checks passed
PrettyCI Code formatting
Travis CI - Pull Request Build Passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.