Added 'low stock' statistics.

This commit is contained in:
Hannes Matuschek 2020-08-30 13:57:33 +02:00
parent 6fa2003d32
commit 226fe2f4ba
3 changed files with 43 additions and 0 deletions

View file

@ -80,6 +80,17 @@ class StatisticsHelper
return $this->part_repo->getPartsCountWithPrice();
}
/**
* Returns the number of all parts with low stock.
*
* @throws \Doctrine\ORM\NoResultException
* @throws \Doctrine\ORM\NonUniqueResultException
*/
public function getPartCountWithLowStock(): int
{
return $this->part_repo->getPartCountWithLowStock();
}
/**
* Returns the number of datastructures for the given type.
*/