From fd3ccd62e2f16c5d303455409edfa5c31cc5dfd3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julien=20Fastr=C3=A9?= Date: Thu, 3 May 2018 22:45:09 +0200 Subject: [PATCH] fix bug: closing motive are present at today date in timeline --- Timeline/TimelineAccompanyingPeriodClosing.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Timeline/TimelineAccompanyingPeriodClosing.php b/Timeline/TimelineAccompanyingPeriodClosing.php index f50bf97fd..05aebbfd4 100644 --- a/Timeline/TimelineAccompanyingPeriodClosing.php +++ b/Timeline/TimelineAccompanyingPeriodClosing.php @@ -52,6 +52,12 @@ class TimelineAccompanyingPeriodClosing extends AbstractTimelineAccompanyingPeri $data['type'] = 'accompanying_period_closing'; $data['date'] = $metadata->getColumnName('closingDate'); + $data['WHERE'] = sprintf('%s = %d AND %s IS NOT NULL', + $metadata + ->getAssociationMapping('person')['joinColumns'][0]['name'], + $args['person']->getId(), + $metadata->getColumnName('closingDate')) + ; return $data; }