mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
[export] Fixed: the scope aggregator (accompanying course) group by
period's scope (and the label didn't show this) + extract ScopeRepository and create ScopeRepositoryInterface
This commit is contained in:
parent
307ed4fb1b
commit
491570a21c
@ -14,9 +14,10 @@ namespace Chill\MainBundle\Repository;
|
||||
use Chill\MainBundle\Entity\Scope;
|
||||
use Doctrine\ORM\EntityManagerInterface;
|
||||
use Doctrine\ORM\EntityRepository;
|
||||
use Doctrine\ORM\QueryBuilder;
|
||||
use Doctrine\Persistence\ObjectRepository;
|
||||
|
||||
final class ScopeRepository implements ObjectRepository
|
||||
final class ScopeRepository implements ScopeRepositoryInterface
|
||||
{
|
||||
private EntityRepository $repository;
|
||||
|
||||
@ -25,7 +26,7 @@ final class ScopeRepository implements ObjectRepository
|
||||
$this->repository = $entityManager->getRepository(Scope::class);
|
||||
}
|
||||
|
||||
public function createQueryBuilder($alias, $indexBy = null)
|
||||
public function createQueryBuilder($alias, $indexBy = null): QueryBuilder
|
||||
{
|
||||
return $this->repository->createQueryBuilder($alias, $indexBy);
|
||||
}
|
||||
@ -59,7 +60,7 @@ final class ScopeRepository implements ObjectRepository
|
||||
return $this->repository->findOneBy($criteria, $orderBy);
|
||||
}
|
||||
|
||||
public function getClassName()
|
||||
public function getClassName(): string
|
||||
{
|
||||
return Scope::class;
|
||||
}
|
||||
|
@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
namespace Chill\MainBundle\Repository;
|
||||
|
||||
use Chill\MainBundle\Entity\Scope;
|
||||
use Doctrine\ORM\QueryBuilder;
|
||||
use Doctrine\Persistence\ObjectRepository;
|
||||
|
||||
interface ScopeRepositoryInterface extends ObjectRepository
|
||||
{
|
||||
public function createQueryBuilder($alias, $indexBy = null): QueryBuilder;
|
||||
|
||||
public function find($id, $lockMode = null, $lockVersion = null): ?Scope;
|
||||
|
||||
/**
|
||||
* @return Scope[]
|
||||
*/
|
||||
public function findAll(): array;
|
||||
|
||||
/**
|
||||
* @return Scope[]
|
||||
*/
|
||||
public function findBy(array $criteria, ?array $orderBy = null, $limit = null, $offset = null): array;
|
||||
|
||||
public function findOneBy(array $criteria, ?array $orderBy = null): ?Scope;
|
||||
|
||||
public function getClassName(): string;
|
||||
}
|
@ -83,6 +83,6 @@ final class ScopeAggregator implements AggregatorInterface
|
||||
|
||||
public function getTitle(): string
|
||||
{
|
||||
return 'Group by user scope';
|
||||
return 'Group course by scope';
|
||||
}
|
||||
}
|
||||
|
@ -437,7 +437,8 @@ Filtered by person having an activity between %date_from% and %date_to% with rea
|
||||
## accompanying course filters/aggr
|
||||
Filter by user scope: Filtrer les parcours par service du référent
|
||||
"Filtered by user main scope: only %scope%": "Filtré par service du référent: uniquement %scope%"
|
||||
Group by user scope: Grouper les parcours par service du référent
|
||||
|
||||
Group course by scope: Grouper les parcours par service
|
||||
|
||||
Filter by user job: Filtrer les parcours par métier du référent
|
||||
"Filtered by user job: only %job%": "Filtré par métier du référent: uniquement %job%"
|
||||
|
Loading…
x
Reference in New Issue
Block a user