mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-03 21:34:59 +00:00
Add dates in the filter "filter course by activity type"
This commit is contained in:
@@ -13,6 +13,7 @@ namespace Chill\ActivityBundle\Tests\Export\Filter\ACPFilters;
|
||||
|
||||
use Chill\ActivityBundle\Entity\Activity;
|
||||
use Chill\ActivityBundle\Entity\ActivityType;
|
||||
use Chill\MainBundle\Service\RollingDate\RollingDate;
|
||||
use Chill\MainBundle\Test\Export\AbstractFilterTest;
|
||||
use Chill\PersonBundle\Entity\AccompanyingPeriod;
|
||||
use Doctrine\Common\Collections\ArrayCollection;
|
||||
@@ -55,8 +56,30 @@ final class ActivityTypeFilterTest extends AbstractFilterTest
|
||||
$data = [];
|
||||
|
||||
foreach ($array as $a) {
|
||||
$data[] = [
|
||||
'accepted_activitytypes' => [],
|
||||
'date_after' => new RollingDate(RollingDate::T_YEAR_PREVIOUS_START),
|
||||
'date_before' => new RollingDate(RollingDate::T_TODAY),
|
||||
];
|
||||
$data[] = [
|
||||
'accepted_activitytypes' => new ArrayCollection([$a]),
|
||||
'date_after' => null,
|
||||
'date_before' => null,
|
||||
];
|
||||
$data[] = [
|
||||
'accepted_activitytypes' => [$a],
|
||||
'date_after' => null,
|
||||
'date_before' => null,
|
||||
];
|
||||
$data[] = [
|
||||
'accepted_activitytypes' => [$a],
|
||||
'date_after' => new RollingDate(RollingDate::T_YEAR_PREVIOUS_START),
|
||||
'date_before' => new RollingDate(RollingDate::T_TODAY),
|
||||
];
|
||||
$data[] = [
|
||||
'accepted_activitytypes' => [],
|
||||
'date_after' => null,
|
||||
'date_before' => null,
|
||||
];
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user