Przeglądaj źródła

Merge branch 'packProduct' of https://forge.laclic.fr/Laclic/CaracoleBundle into packProduct

packProduct
Guillaume 2 lat temu
rodzic
commit
4557929e31
3 zmienionych plików z 6 dodań i 2 usunięć
  1. +1
    -0
      Repository/Order/OrderShopRepositoryQuery.php
  2. +3
    -1
      Repository/Order/OrderShopStore.php
  3. +2
    -1
      Statistic/Product/ProductsSalesStatistic.php

+ 1
- 0
Repository/Order/OrderShopRepositoryQuery.php Wyświetl plik

@@ -57,6 +57,7 @@ class OrderShopRepositoryQuery extends AbstractRepositoryQuery
);
}


public function selectSum(): self
{
$this->joinProduct();

+ 3
- 1
Repository/Order/OrderShopStore.php Wyświetl plik

@@ -10,6 +10,7 @@ use Lc\CaracoleBundle\Builder\File\DocumentBuilder;
use Lc\CaracoleBundle\Model\Distribution\DistributionInterface;
use Lc\CaracoleBundle\Model\Order\OrderShopInterface;
use Lc\CaracoleBundle\Model\Order\OrderStatusModel;
use Lc\CaracoleBundle\Model\Product\ProductFamilyInterface;
use Lc\CaracoleBundle\Model\Product\ProductInterface;
use Lc\CaracoleBundle\Model\Reduction\ReductionCartInterface;
use Lc\CaracoleBundle\Model\Reduction\ReductionCreditInterface;
@@ -590,6 +591,7 @@ class OrderShopStore extends AbstractStore
public function countValidOrderProductsOfDistributionsByProducts(
array $distributions,
array $products,
ProductFamilyInterface $productFamily,
$query = null
): array {
$query = $this->createDefaultQuery($query);
@@ -601,7 +603,7 @@ class OrderShopStore extends AbstractStore
->groupBy('distribution.cycleNumber, product.id');

//TODO vérifier ou est utilisé cette fonction ???
dump($query->find());
return $query->find();
}


+ 2
- 1
Statistic/Product/ProductsSalesStatistic.php Wyświetl plik

@@ -81,7 +81,8 @@ class ProductsSalesStatistic extends Statistic
{
$countsOrderedByCyclesAndProducts = $orderShopStore->countValidOrderProductsOfDistributionsByProducts(
$this->distributionList,
$this->productIds
$this->productIds,
$this->productFamily
);

foreach ($countsOrderedByCyclesAndProducts as $result) {

Ładowanie…
Anuluj
Zapisz