!!!|Show all coming + running dates by default

Only coming dates were shown by default.

Relates: #9505
This commit is contained in:
Daniel Siepmann 2021-12-06 12:15:47 +01:00
parent bc6aa4d359
commit 30f030aab6

View file

@ -81,7 +81,10 @@ class DateRepository extends Repository
if ($demand->getStart() === null && $demand->getEnd() === null) {
$now = new \DateTime('now', new \DateTimeZone('Europe/Berlin'));
$constraints['untilnow'] = $query->greaterThanOrEqual('start', $now);
$constraints['nowAndFuture'] = $query->logicalOr([
$query->greaterThanOrEqual('start', $now),
$query->greaterThanOrEqual('end', $now)
]);
}
if ($demand->getLimit() !== '') {