<?php

namespace Myvetshop\Module\Clinique\Repository;

use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;
use Doctrine\Persistence\ManagerRegistry;
use Myvetshop\Module\Clinique\Entity\MyvetshopClinique;

class MyvetshopCliniqueRepository extends ServiceEntityRepository
{
    public function __construct(ManagerRegistry $registry)
    {
        parent::__construct($registry, MyvetshopClinique::class);
    }

    public function findByGroupId(int $groupId): ?MyvetshopClinique
    {
        // @phpstan-ignore-next-line
        return $this->findOneBy(['idGroup' => $groupId]);
    }
}
