Merge branch '146_parcours_annules' into rector/rules-symfony

This commit is contained in:
2023-10-16 17:52:06 +02:00
28 changed files with 314 additions and 16 deletions

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\ExportInterface;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
@@ -30,7 +31,7 @@ class CountAccompanyingCourse implements ExportInterface, GroupedExportInterface
protected EntityRepository $repository;
public function __construct(
EntityManagerInterface $em
EntityManagerInterface $em,
) {
$this->repository = $em->getRepository(AccompanyingPeriod::class);
}
@@ -111,6 +112,8 @@ class CountAccompanyingCourse implements ExportInterface, GroupedExportInterface
->setParameter('count_acp_step', AccompanyingPeriod::STEP_DRAFT)
->setParameter('authorized_centers', $centers);
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
$qb->select('COUNT(DISTINCT acp.id) AS export_result');
return $qb;

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\ExportInterface;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
@@ -106,6 +107,8 @@ class CountAccompanyingPeriodWork implements ExportInterface, GroupedExportInter
$qb->select('COUNT(DISTINCT acpw.id) as export_result');
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
return $qb;
}

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\ExportInterface;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
@@ -29,7 +30,6 @@ class CountEvaluation implements ExportInterface, GroupedExportInterface
public function buildForm(FormBuilderInterface $builder)
{
// TODO: Implement buildForm() method.
}
public function getFormDefaultData(): array
{
@@ -104,6 +104,8 @@ class CountEvaluation implements ExportInterface, GroupedExportInterface
)
->setParameter('authorized_centers', $centers);
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
$qb->select('COUNT(DISTINCT workeval.id) AS export_result');
return $qb;

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\ExportInterface;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
@@ -30,7 +31,7 @@ class CountPersonWithAccompanyingCourse implements ExportInterface, GroupedExpor
private readonly EntityRepository $repository;
public function __construct(
EntityManagerInterface $em
EntityManagerInterface $em,
) {
$this->repository = $em->getRepository(AccompanyingPeriod::class);
}
@@ -111,6 +112,8 @@ class CountPersonWithAccompanyingCourse implements ExportInterface, GroupedExpor
)
)->setParameter('authorized_centers', $centers);
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
$qb->select('COUNT(DISTINCT person.id) AS export_result');
return $qb;

View File

@@ -13,6 +13,7 @@ namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Entity\Address;
use Chill\MainBundle\Entity\Scope;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
use Chill\MainBundle\Export\Helper\DateTimeHelper;
@@ -132,6 +133,8 @@ final readonly class ListAccompanyingPeriod implements ListInterface, GroupedExp
$this->listAccompanyingPeriodHelper->addSelectClauses($qb, $this->rollingDateConverter->convert($data['calc_date']));
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
$qb
->addOrderBy('acp.openingDate')
->addOrderBy('acp.closingDate')

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
use Chill\MainBundle\Export\Helper\AggregateStringHelper;
@@ -207,6 +208,8 @@ class ListAccompanyingPeriodWork implements ListInterface, GroupedExportInterfac
->setParameter('authorized_centers', $centers)
->setParameter('calc_date', $this->rollingDateConverter->convert($data['calc_date']));
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
$this->addSelectClauses($qb, $this->rollingDateConverter->convert($data['calc_date']));
return $qb;

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
use Chill\MainBundle\Export\Helper\AggregateStringHelper;
@@ -199,6 +200,8 @@ class ListEvaluation implements ListInterface, GroupedExportInterface
->setParameter('authorized_centers', $centers)
->setParameter('calc_date', $this->rollingDateConverter->convert($data['calc_date']));
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
$this->addSelectClauses($qb, $this->rollingDateConverter->convert($data['calc_date']));
return $qb;

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\ExportElementValidatedInterface;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
@@ -176,6 +177,8 @@ class ListPersonHavingAccompanyingPeriod implements ExportElementValidatedInterf
$this->listPersonHelper->addSelect($qb, $fields, $data['address_date']);
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
$qb
->addOrderBy('person.lastName')
->addOrderBy('person.firstName')

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\ExportElementValidatedInterface;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
@@ -133,6 +134,8 @@ final readonly class ListPersonWithAccompanyingPeriodDetails implements ListInte
$this->listPersonHelper->addSelect($qb, ListPersonHelper::FIELDS, $this->rollingDateConverter->convert($data['address_date']));
$this->listAccompanyingPeriodHelper->addSelectClauses($qb, $this->rollingDateConverter->convert($data['address_date']));
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
$qb
->addOrderBy('person.lastName')
->addOrderBy('person.firstName')

View File

@@ -11,6 +11,7 @@ declare(strict_types=1);
namespace Chill\PersonBundle\Export\Export;
use Chill\MainBundle\Export\AccompanyingCourseExportHelper;
use Chill\MainBundle\Export\ExportInterface;
use Chill\MainBundle\Export\FormatterInterface;
use Chill\MainBundle\Export\GroupedExportInterface;
@@ -32,7 +33,7 @@ class StatAccompanyingCourseDuration implements ExportInterface, GroupedExportIn
private readonly EntityRepository $repository;
public function __construct(
EntityManagerInterface $em
EntityManagerInterface $em,
) {
$this->repository = $em->getRepository(AccompanyingPeriod::class);
}
@@ -133,6 +134,8 @@ class StatAccompanyingCourseDuration implements ExportInterface, GroupedExportIn
->setParameter('count_acp_step', AccompanyingPeriod::STEP_DRAFT)
->setParameter('authorized_centers', $centers);
AccompanyingCourseExportHelper::addClosingMotiveExclusionClause($qb);
return $qb;
}