@@ -108,6 +108,13 @@ class ProductRepositoryQuery extends AbstractRepositoryQuery | |||
} | |||
public function filterIsNotAvailableQuantitySupplierUnlimited():self | |||
{ | |||
$this->andWhere('productFamily.availableQuantitySupplierUnlimited != 1'); | |||
return $this; | |||
} | |||
public function filterAvailableQuantityNegative() :self | |||
{ | |||
@@ -66,6 +66,7 @@ class ProductStore extends AbstractStore | |||
$query->joinProductFamily(); | |||
$query->filterIsOnline(); | |||
$query->filterAvailableQuantitySupplierNegative(); | |||
$query->filterIsNotAvailableQuantitySupplierUnlimited(); | |||
$query->groupBy('productFamily.id'); | |||
$productListAvailableQuantityNegative = $query->find(); | |||