Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix pricing when using with&without tax with customer groups
When using prices with and without taxes, there are multiple entries in the $fields array. When looping through the groups $product->getPriceModel()->getFinalPrice() is called for each group. This sets the data['final_price'] on the product model each time it is called. This means that on the second loop of the field array, when the call to set $special_price uses $product->getFinalPrice() it is getting value set for the final group in the previous iteration. This patch changes the assignment of special_price to recalculate the final_price everytime, it also moves it out of the currency loop because the result doesn't depend on the currency. (cherry picked from commit 77dad50c58c81b6e95772230bad89e05b60c9b2e)
- Loading branch information