Abacchus Posted June 29, 2022 Share Posted June 29, 2022 (edited) Hello, My products have 2 discounts : 10% for 1 unit 25% for minimum 6 units (not for all products). Issue : product-list.tpl displays $product.specific_prices.reduction which is only 10% in my case. I want to have display instead the 25% which is the best reduction. In the Model SpecificPrice.php, I see 2 functions : getSpecificPrice () which generates the specific_prices reduction getQuantityDiscounts () which will allow to get the 25% My idea is to add to the model a new variable $bestreduc and a function getBestReduction() to update it. Then product-list.tpl would display i$product.specific_prices.bestreduct Am i on the right path (I'm newby to PS core dev) ? Thanks Edited July 2, 2022 by Abacchus (see edit history) Link to comment Share on other sites More sharing options...
knacky Posted July 3, 2022 Share Posted July 3, 2022 And why not show the customer both options? Use hook to show flag and show all. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now