라벨작업관리 목록 API 날짜 수정, 에러로그 날짜 변환 수정
This commit is contained in:
@@ -114,21 +114,13 @@ public class LabelWorkRepositoryImpl extends QuerydslRepositorySupport
|
||||
whereSubBuilder.and(
|
||||
mapSheetAnalDataInferenceGeomEntity.dataUid.eq(mapSheetAnalDataInferenceEntity.id));
|
||||
|
||||
if (searchReq.getStrtDttm() != null
|
||||
&& !searchReq.getStrtDttm().isEmpty()
|
||||
&& searchReq.getEndDttm() != null
|
||||
&& !searchReq.getEndDttm().isEmpty()) {
|
||||
if (searchReq.getStrtDttm() != null && searchReq.getEndDttm() != null) {
|
||||
|
||||
ZoneId zoneId = ZoneId.of("Asia/Seoul");
|
||||
|
||||
ZonedDateTime start =
|
||||
LocalDate.parse(searchReq.getStrtDttm(), DateTimeFormatter.BASIC_ISO_DATE)
|
||||
.atStartOfDay(zoneId);
|
||||
ZonedDateTime start = searchReq.getStrtDttm().atStartOfDay(zoneId);
|
||||
|
||||
ZonedDateTime end =
|
||||
LocalDate.parse(searchReq.getEndDttm(), DateTimeFormatter.BASIC_ISO_DATE)
|
||||
.plusDays(1)
|
||||
.atStartOfDay(zoneId);
|
||||
ZonedDateTime end = searchReq.getEndDttm().plusDays(1).atStartOfDay(zoneId);
|
||||
|
||||
whereSubBuilder.and(
|
||||
mapSheetAnalDataInferenceGeomEntity
|
||||
@@ -402,12 +394,7 @@ public class LabelWorkRepositoryImpl extends QuerydslRepositorySupport
|
||||
}
|
||||
|
||||
public NumberExpression<Long> caseSumExpression(BooleanExpression condition) {
|
||||
NumberExpression<Long> sumExp =
|
||||
new CaseBuilder()
|
||||
.when(condition)
|
||||
.then(1L)
|
||||
.otherwise(0L)
|
||||
.sum();
|
||||
NumberExpression<Long> sumExp = new CaseBuilder().when(condition).then(1L).otherwise(0L).sum();
|
||||
|
||||
return sumExp;
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@ import com.querydsl.core.types.dsl.Expressions;
|
||||
import com.querydsl.core.types.dsl.StringExpression;
|
||||
import com.querydsl.jpa.impl.JPAQueryFactory;
|
||||
import java.time.LocalDate;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.ZoneId;
|
||||
import java.time.ZonedDateTime;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
@@ -98,12 +98,14 @@ public class ErrorLogRepositoryImpl extends QuerydslRepositorySupport
|
||||
if (Objects.isNull(startDate) || Objects.isNull(endDate)) {
|
||||
return null;
|
||||
}
|
||||
LocalDateTime startDateTime = startDate.atStartOfDay();
|
||||
LocalDateTime endDateTime = endDate.plusDays(1).atStartOfDay();
|
||||
|
||||
ZoneId zoneId = ZoneId.of("Asia/Seoul");
|
||||
ZonedDateTime startDateTime = startDate.atStartOfDay(zoneId);
|
||||
ZonedDateTime endDateTime = endDate.plusDays(1).atStartOfDay(zoneId);
|
||||
return auditLogEntity
|
||||
.createdDate
|
||||
.goe(ZonedDateTime.from(startDateTime))
|
||||
.and(auditLogEntity.createdDate.lt(ZonedDateTime.from(endDateTime)));
|
||||
.goe(startDateTime)
|
||||
.and(auditLogEntity.createdDate.lt(endDateTime));
|
||||
}
|
||||
|
||||
private BooleanExpression eventStatusEqFailed() {
|
||||
|
||||
Reference in New Issue
Block a user