File tree Expand file tree Collapse file tree 2 files changed +14
-0
lines changed
src/Bridge/Doctrine/Orm/Filter Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -36,6 +36,10 @@ class DateFilter extends AbstractFilter
36
36
'datetime ' => true ,
37
37
'datetimetz ' => true ,
38
38
'time ' => true ,
39
+ 'date_immutable ' => true ,
40
+ 'datetime_immutable ' => true ,
41
+ 'datetimetz_immutable ' => true ,
42
+ 'time_immutable ' => true ,
39
43
];
40
44
41
45
/**
Original file line number Diff line number Diff line change @@ -157,6 +157,16 @@ private function getType(string $doctrineType): string
157
157
return 'float ' ;
158
158
}
159
159
160
+ if (defined (Type::class.'::DATE_IMMUTABLE ' )) {
161
+ switch ($ doctrineType ) {
162
+ case Type::DATE_IMMUTABLE :
163
+ case Type::TIME_IMMUTABLE :
164
+ case Type::DATETIME_IMMUTABLE :
165
+ case Type::DATETIMETZ_IMMUTABLE :
166
+ return \DateTimeInterface::class;
167
+ }
168
+ }
169
+
160
170
return 'string ' ;
161
171
}
162
172
You can’t perform that action at this time.
0 commit comments