diff --git a/tesler-core/src/main/java/io/tesler/core/util/filter/provider/impl/DateValueProvider.java b/tesler-core/src/main/java/io/tesler/core/util/filter/provider/impl/DateValueProvider.java index aa7a1d902e..9c710824b7 100644 --- a/tesler-core/src/main/java/io/tesler/core/util/filter/provider/impl/DateValueProvider.java +++ b/tesler-core/src/main/java/io/tesler/core/util/filter/provider/impl/DateValueProvider.java @@ -34,7 +34,6 @@ import java.lang.reflect.Field; import java.time.LocalDateTime; import java.util.ArrayList; -import java.util.Collections; import java.util.List; import static io.tesler.core.controller.param.SearchOperation.CONTAINS_ONE_OF; @@ -63,7 +62,7 @@ protected List getProviderParameterValues(Field dtoField, } else { setClassifyDateParameterDateValue(dataParameter, filterParam, FieldDTO.isTzAware(dtoField), searchParam, result); } - result = Collections.singletonList(dataParameter); + result.add(dataParameter); return result; } diff --git a/tesler-core/src/test/java/io/tesler/core/dao/SearchSpecificationTest.java b/tesler-core/src/test/java/io/tesler/core/dao/SearchSpecificationTest.java index a6f6000c20..4ba75a47b8 100644 --- a/tesler-core/src/test/java/io/tesler/core/dao/SearchSpecificationTest.java +++ b/tesler-core/src/test/java/io/tesler/core/dao/SearchSpecificationTest.java @@ -91,7 +91,7 @@ void setUp() { @Test void searchSpecTest() { FilterParameters fp = FilterParameters.fromMap(successMap); - Assertions.assertEquals(MetadataUtils.mapSearchParamsToPOJO(TestResponseDto.class, fp, providers).size(), 30); + Assertions.assertEquals(MetadataUtils.mapSearchParamsToPOJO(TestResponseDto.class, fp, providers).size(), 31); } @Test