New API - RoomCategory

This commit is contained in:
2024-04-22 18:10:16 +02:00
parent 2079188760
commit fcfe2f9250
12 changed files with 1085 additions and 3 deletions
+48
View File
@@ -0,0 +1,48 @@
<?php
namespace App\Repository;
use App\Entity\RoomCategory;
use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;
use Doctrine\Persistence\ManagerRegistry;
/**
* @extends ServiceEntityRepository<RoomCategory>
*
* @method RoomCategory|null find($id, $lockMode = null, $lockVersion = null)
* @method RoomCategory|null findOneBy(array $criteria, array $orderBy = null)
* @method RoomCategory[] findAll()
* @method RoomCategory[] findBy(array $criteria, array $orderBy = null, $limit = null, $offset = null)
*/
class RoomCategoryRepository extends ServiceEntityRepository
{
public function __construct(ManagerRegistry $registry)
{
parent::__construct($registry, RoomCategory::class);
}
// /**
// * @return RoomCategory[] Returns an array of RoomCategory objects
// */
// public function findByExampleField($value): array
// {
// return $this->createQueryBuilder('r')
// ->andWhere('r.exampleField = :val')
// ->setParameter('val', $value)
// ->orderBy('r.id', 'ASC')
// ->setMaxResults(10)
// ->getQuery()
// ->getResult()
// ;
// }
// public function findOneBySomeField($value): ?RoomCategory
// {
// return $this->createQueryBuilder('r')
// ->andWhere('r.exampleField = :val')
// ->setParameter('val', $value)
// ->getQuery()
// ->getOneOrNullResult()
// ;
// }
}