PartKeepr\PartBundle\Services\PartService::getPartCount PHP 메소드

getPartCount() 공개 메소드

Returns the number of parts present in the system.
public getPartCount ( ) : mixed
리턴 mixed
    public function getPartCount()
    {
        $dql = 'SELECT COUNT(p) FROM PartKeepr\\PartBundle\\Entity\\Part p';
        $query = $this->entityManager->createQuery($dql);
        return $query->getSingleScalarResult();
    }