change class reference

This commit is contained in:
Julie Lenaerts 2022-09-08 10:17:22 +02:00
parent 4aaf75a1a4
commit e550d64fd4
3 changed files with 6 additions and 3 deletions

View File

@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters;
use Chill\ActivityBundle\Entity\Activity;
use Chill\ActivityBundle\Entity\ActivityType;
use Chill\MainBundle\Export\FilterInterface;
use Chill\MainBundle\Templating\TranslatableStringHelper;
@ -43,7 +44,7 @@ class ActivityTypeFilter implements FilterInterface
// we replace indicator 'from' clause by 'act', and put 'acp' in a join
$qb->resetDQLPart('from');
$qb->from('ChillActivityBundle:Activity', 'activity');
$qb->from(Activity::class, 'activity');
if (!in_array('actacp', $qb->getAllAliases(), true)) {
$qb->join('activity.accompanyingPeriod', 'actacp');

View File

@ -14,6 +14,7 @@ namespace Chill\PersonBundle\Export\Filter\PersonFilters;
use Chill\MainBundle\Export\FilterInterface;
use Chill\MainBundle\Form\Type\ChillDateType;
use Chill\MainBundle\Templating\TranslatableStringHelper;
use Chill\PersonBundle\Entity\Person\ResidentialAddress;
use Chill\PersonBundle\Export\Declarations;
use Chill\ThirdPartyBundle\Entity\ThirdPartyCategory;
use DateTime;
@ -39,7 +40,7 @@ class ResidentialAddressAtThirdpartyFilter implements FilterInterface
public function alterQuery(QueryBuilder $qb, $data)
{
$qb->resetDQLPart('from');
$qb->from('ChillPersonBundle:Person\ResidentialAddress', 'resaddr');
$qb->from(ResidentialAddress::class, 'resaddr');
if (!in_array('resaddrperson', $qb->getAllAliases(), true)) {
$qb->join('resaddr.person', 'resaddrperson');

View File

@ -12,6 +12,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Filter\PersonFilters;
use Chill\MainBundle\Export\FilterInterface;
use Chill\PersonBundle\Entity\Person\ResidentialAddress;
use Chill\PersonBundle\Export\Declarations;
use Doctrine\ORM\Query\Expr\Andx;
use Doctrine\ORM\QueryBuilder;
@ -26,7 +27,7 @@ class ResidentialAddressAtUserFilter implements FilterInterface
public function alterQuery(QueryBuilder $qb, $data)
{
$qb->resetDQLPart('from');
$qb->from('ChillPersonBundle:Person\ResidentialAddress', 'resaddr');
$qb->from(ResidentialAddress::class, 'resaddr');
if (!in_array('resaddrperson', $qb->getAllAliases(), true)) {
$qb->join('resaddr.person', 'resaddrperson');