From 63ba1ceeda345e302ba4f7294b8da24795ab221d Mon Sep 17 00:00:00 2001 From: Etienne Roudeix Date: Fri, 20 Dec 2013 11:12:03 +0100 Subject: [PATCH] make it magic last stand --- core/lib/Thelia/Core/Template/Loop/ProductSaleElements.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/lib/Thelia/Core/Template/Loop/ProductSaleElements.php b/core/lib/Thelia/Core/Template/Loop/ProductSaleElements.php index e1d54ff90..687bf7fdb 100755 --- a/core/lib/Thelia/Core/Template/Loop/ProductSaleElements.php +++ b/core/lib/Thelia/Core/Template/Loop/ProductSaleElements.php @@ -37,6 +37,7 @@ use Thelia\Model\Base\ProductSaleElementsQuery; use Thelia\Model\CountryQuery; use Thelia\Model\CurrencyQuery; use Thelia\Model\Map\ProductSaleElementsTableMap; +use Thelia\TaxEngine\TaxEngine; use Thelia\Type\TypeCollection; use Thelia\Type; @@ -145,7 +146,7 @@ class ProductSaleElements extends BaseLoop implements PropelSearchLoopInterface public function parseResults(LoopResult $loopResult) { - $taxCountry = CountryQuery::create()->findPk(64); // @TODO : make it magic + $taxCountry = TaxEngine::getInstance($this->request->getSession())->getTaxCountry(); foreach ($loopResult->getResultDataCollection() as $PSEValue) { $loopResultRow = new LoopResultRow($PSEValue);