|
|
@@ -412,6 +412,9 @@ class OrderShopBuilder |
|
|
|
$orderShop->setStatDeliveryPriceWithTaxAndReduction( |
|
|
|
$this->priceSolver->getDeliveryPriceWithTaxAndReduction($orderShop) |
|
|
|
); |
|
|
|
$orderShop->setStatMarginDeliveryWithReductions( |
|
|
|
$this->priceSolver->getMarginDeliveryWithReductions($orderShop) |
|
|
|
); |
|
|
|
|
|
|
|
$this->entityManager->persist($orderShop); |
|
|
|
if ($flush) { |
|
|
@@ -573,29 +576,35 @@ class OrderShopBuilder |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public function setStatsInfo(OrderShopInterface $orderShop, $flush = true) |
|
|
|
{ |
|
|
|
$orderShop->setStatTotal($this->priceSolver->getTotal($orderShop)); |
|
|
|
$orderShop->setStatTotalWithTax($this->priceSolver->getTotalWithTax($orderShop)); |
|
|
|
$orderShop->setStatTotalOrderProductsWithReductions( |
|
|
|
$this->priceSolver->getTotalOrderProductsWithReductions($orderShop) |
|
|
|
); |
|
|
|
$orderShop->setStatTotalOrderProductsWithTaxAndReductions( |
|
|
|
$this->priceSolver->getTotalOrderProductsWithTaxAndReductions($orderShop) |
|
|
|
); |
|
|
|
$orderShop->setStatMarginOrderProductsWithReductions( |
|
|
|
$this->priceSolver->getMarginOrderProductsWithReductions($orderShop) |
|
|
|
); |
|
|
|
$orderShop->setStatDeliveryPriceWithReduction($this->priceSolver->getDeliveryPriceWithReduction($orderShop)); |
|
|
|
$orderShop->setStatDeliveryPriceWithTaxAndReduction( |
|
|
|
$this->priceSolver->getDeliveryPriceWithTaxAndReduction($orderShop) |
|
|
|
); |
|
|
|
|
|
|
|
$this->entityManager->update($orderShop); |
|
|
|
if ($flush) { |
|
|
|
$this->entityManager->flush(); |
|
|
|
} |
|
|
|
} |
|
|
|
//Semble ne jamais être utilisé |
|
|
|
//TODO : à supprimer si pas d'erreur arpès 1/01/2025 |
|
|
|
// public function setStatsInfo(OrderShopInterface $orderShop, $flush = true) |
|
|
|
// { |
|
|
|
// $orderShop->setStatTotal($this->priceSolver->getTotal($orderShop)); |
|
|
|
// $orderShop->setStatTotalWithTax($this->priceSolver->getTotalWithTax($orderShop)); |
|
|
|
// $orderShop->setStatTotalOrderProductsWithReductions( |
|
|
|
// $this->priceSolver->getTotalOrderProductsWithReductions($orderShop) |
|
|
|
// ); |
|
|
|
// $orderShop->setStatTotalOrderProductsWithTaxAndReductions( |
|
|
|
// $this->priceSolver->getTotalOrderProductsWithTaxAndReductions($orderShop) |
|
|
|
// ); |
|
|
|
// $orderShop->setStatMarginOrderProductsWithReductions( |
|
|
|
// $this->priceSolver->getMarginOrderProductsWithReductions($orderShop) |
|
|
|
// ); |
|
|
|
// $orderShop->setStatDeliveryPriceWithReduction($this->priceSolver->getDeliveryPriceWithReduction($orderShop)); |
|
|
|
// $orderShop->setStatDeliveryPriceWithTaxAndReduction( |
|
|
|
// $this->priceSolver->getDeliveryPriceWithTaxAndReduction($orderShop) |
|
|
|
// ); |
|
|
|
// $orderShop->setStatMarginDeliveryWithReductions( |
|
|
|
// $this->priceSolver->getMarginDeliveryWithReductions($orderShop) |
|
|
|
// ); |
|
|
|
// |
|
|
|
// |
|
|
|
// $this->entityManager->update($orderShop); |
|
|
|
// if ($flush) { |
|
|
|
// $this->entityManager->flush(); |
|
|
|
// } |
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
public function setHasReach(int $reachStep, OrderShopInterface $orderShop) |