Browse Source

Nouveau système PriceUtils

feature/export_comptable
Guillaume 4 years ago
parent
commit
f600707b03
1 changed files with 7 additions and 1 deletions
  1. +7
    -1
      ShopBundle/Services/Price/OrderShopPriceUtils.php

+ 7
- 1
ShopBundle/Services/Price/OrderShopPriceUtils.php View File

@@ -78,10 +78,16 @@ class OrderShopPriceUtils implements OrderShopPriceUtilsInterface

public function getTotalOrderProductsWithReductions(OrderShopInterface $orderShop)
{
$total = $this->getTotalOrderProducts($orderShop) ;

$totalReductionAmount = 0 ;
foreach ($orderShop->getOrderReductionCarts() as $orderReductionCart) {
$reductionAmount = $this->amountOrderProductsReductionCart($orderShop,$orderReductionCart);
$totalReductionAmount += $this->amountOrderProductsReductionCart($orderShop,$orderReductionCart);
}

$total -= $totalReductionAmount ;

return $total ;
}



Loading…
Cancel
Save