PHP Class PartKeepr\PartBundle\Services\PartService

Afficher le fichier Open project: partkeepr/PartKeepr Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( EntityManager $entityManager, $partLimit = false, $checkInternalPartNumberUniqueness = false )
checkPartLimit ( ) : boolean Checks if the amount of parts is exceeded.
getPartCount ( ) : mixed Returns the number of parts present in the system.
isInternalPartNumberUnique ( string $internalPartNumber, Part $part = null ) : boolean Checks if the given internal part number is unique

Method Details

__construct() public méthode

public __construct ( EntityManager $entityManager, $partLimit = false, $checkInternalPartNumberUniqueness = false )
$entityManager Doctrine\ORM\EntityManager

checkPartLimit() public méthode

Checks if the amount of parts is exceeded.
public checkPartLimit ( ) : boolean
Résultat boolean

getPartCount() public méthode

Returns the number of parts present in the system.
public getPartCount ( ) : mixed
Résultat mixed

isInternalPartNumberUnique() public méthode

Checks if the given internal part number is unique
public isInternalPartNumberUnique ( string $internalPartNumber, Part $part = null ) : boolean
$internalPartNumber string The internal part number to checkl
$part PartKeepr\PartBundle\Entity\Part An optional part to exclude within the check
Résultat boolean