mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
Merge branch '270_do_not_display_eval_from_closed_period_in_homepage' into 'master'
Do not display evaluation from closed accompanying period on homepage Closes #270 See merge request Chill-Projet/chill-bundles!676
This commit is contained in:
commit
59005e83c4
6
.changes/unreleased/Fixed-20240416-161817.yaml
Normal file
6
.changes/unreleased/Fixed-20240416-161817.yaml
Normal file
@ -0,0 +1,6 @@
|
||||
kind: Fixed
|
||||
body: Fix broken link in homepage when a evaluation from a closed acc period was present
|
||||
in the homepage widget
|
||||
time: 2024-04-16T16:18:17.888645172+02:00
|
||||
custom:
|
||||
Issue: "270"
|
@ -12,6 +12,7 @@ declare(strict_types=1);
|
||||
namespace Chill\PersonBundle\Repository\AccompanyingPeriod;
|
||||
|
||||
use Chill\MainBundle\Entity\User;
|
||||
use Chill\PersonBundle\Entity\AccompanyingPeriod;
|
||||
use Chill\PersonBundle\Entity\AccompanyingPeriod\AccompanyingPeriodWork;
|
||||
use Chill\PersonBundle\Entity\AccompanyingPeriod\AccompanyingPeriodWorkEvaluation;
|
||||
use Doctrine\ORM\EntityManagerInterface;
|
||||
@ -88,6 +89,7 @@ class AccompanyingPeriodWorkEvaluationRepository implements ObjectRepository
|
||||
->where(
|
||||
$qb->expr()->andX(
|
||||
$qb->expr()->isNull('e.endDate'),
|
||||
$qb->expr()->neq('period.step', ':closed'),
|
||||
$qb->expr()->gte(':now', $qb->expr()->diff('e.maxDate', 'e.warningInterval')),
|
||||
$qb->expr()->orX(
|
||||
$qb->expr()->eq('period.user', ':user'),
|
||||
@ -100,6 +102,7 @@ class AccompanyingPeriodWorkEvaluationRepository implements ObjectRepository
|
||||
->setParameters([
|
||||
'user' => $user,
|
||||
'now' => new \DateTimeImmutable('now'),
|
||||
'closed' => AccompanyingPeriod::STEP_CLOSED,
|
||||
]);
|
||||
|
||||
return $qb;
|
||||
|
Loading…
x
Reference in New Issue
Block a user