spotlessApply 적용
This commit is contained in:
@@ -1,13 +1,11 @@
|
||||
package com.kamco.cd.kamcoback.mapsheet.dto;
|
||||
|
||||
import com.kamco.cd.kamcoback.common.enums.RoleType;
|
||||
import com.kamco.cd.kamcoback.common.enums.SyncStateType;
|
||||
import com.kamco.cd.kamcoback.common.utils.Enums;
|
||||
import com.kamco.cd.kamcoback.common.utils.interfaces.JsonFormatDttm;
|
||||
import com.kamco.cd.kamcoback.config.enums.EnumType;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import java.time.ZonedDateTime;
|
||||
import java.util.List;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
import lombok.NoArgsConstructor;
|
||||
@@ -172,8 +170,7 @@ public class MapSheetMngDto {
|
||||
private String errorCheckTfwFileName;
|
||||
private String errorCheckTifFileName;
|
||||
|
||||
//private List<MngFIleDto> fileArray;
|
||||
|
||||
// private List<MngFIleDto> fileArray;
|
||||
|
||||
public ErrorDataDto(
|
||||
Long hstUid,
|
||||
@@ -205,7 +202,7 @@ public class MapSheetMngDto {
|
||||
}
|
||||
|
||||
private String getSyncStateName(String enumId) {
|
||||
if( enumId == null || enumId.isEmpty())enumId = "NOTYET";
|
||||
if (enumId == null || enumId.isEmpty()) enumId = "NOTYET";
|
||||
|
||||
SyncStateType type = Enums.fromId(SyncStateType.class, enumId);
|
||||
return type.getText();
|
||||
@@ -254,8 +251,6 @@ public class MapSheetMngDto {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public enum DataState implements EnumType {
|
||||
|
||||
@@ -103,5 +103,4 @@ public class MapSheetMngHstEntity extends CommonDateEntity {
|
||||
@Size(max = 100)
|
||||
@Column(name = "sync_check_tfw_file_name", length = 100)
|
||||
private String syncCheckTfwFileName;
|
||||
|
||||
}
|
||||
|
||||
@@ -9,7 +9,6 @@ import static com.kamco.cd.kamcoback.postgres.entity.QMapSheetMngHstEntity.mapSh
|
||||
import com.kamco.cd.kamcoback.mapsheet.dto.MapSheetMngDto;
|
||||
import com.kamco.cd.kamcoback.postgres.entity.MapSheetMngHstEntity;
|
||||
import com.querydsl.core.BooleanBuilder;
|
||||
import com.querydsl.core.Tuple;
|
||||
import com.querydsl.core.types.Projections;
|
||||
import com.querydsl.core.types.dsl.BooleanExpression;
|
||||
import com.querydsl.core.types.dsl.CaseBuilder;
|
||||
@@ -20,10 +19,7 @@ import com.querydsl.jpa.impl.JPAQueryFactory;
|
||||
import jakarta.persistence.EntityManager;
|
||||
import jakarta.persistence.PersistenceContext;
|
||||
import jakarta.validation.Valid;
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
import java.util.Optional;
|
||||
import org.hibernate.query.Query;
|
||||
@@ -49,12 +45,12 @@ public class MapSheetMngRepositoryImpl extends QuerydslRepositorySupport
|
||||
@Override
|
||||
public List<MapSheetMngDto.MngDto> findMapSheetMngList() {
|
||||
|
||||
//Pageable pageable = searchReq.toPageable();
|
||||
// Pageable pageable = searchReq.toPageable();
|
||||
BooleanBuilder whereBuilder = new BooleanBuilder();
|
||||
|
||||
//if (searchReq.getMngYyyy() != null) {
|
||||
//whereBuilder.and(mapSheetMngEntity.mngYyyy.eq(searchReq.getMngYyyy()));
|
||||
//}
|
||||
// if (searchReq.getMngYyyy() != null) {
|
||||
// whereBuilder.and(mapSheetMngEntity.mngYyyy.eq(searchReq.getMngYyyy()));
|
||||
// }
|
||||
|
||||
NumberExpression<Long> totalCount = mapSheetMngHstEntity.count().as("syncTotCnt");
|
||||
|
||||
@@ -155,8 +151,8 @@ public class MapSheetMngRepositoryImpl extends QuerydslRepositorySupport
|
||||
.leftJoin(mapSheetMngHstEntity)
|
||||
.on(mapSheetMngEntity.mngYyyy.eq(mapSheetMngHstEntity.mngYyyy))
|
||||
.where(whereBuilder)
|
||||
//.offset(pageable.getOffset())
|
||||
//.limit(pageable.getPageSize())
|
||||
// .offset(pageable.getOffset())
|
||||
// .limit(pageable.getPageSize())
|
||||
.orderBy(mapSheetMngEntity.mngYyyy.desc())
|
||||
.groupBy(mapSheetMngEntity.mngYyyy)
|
||||
.fetch();
|
||||
@@ -171,7 +167,7 @@ public class MapSheetMngRepositoryImpl extends QuerydslRepositorySupport
|
||||
return foundContent;
|
||||
}
|
||||
|
||||
public MapSheetMngDto.MngDto findMapSheetMng(int mngYyyy){
|
||||
public MapSheetMngDto.MngDto findMapSheetMng(int mngYyyy) {
|
||||
|
||||
BooleanBuilder whereBuilder = new BooleanBuilder();
|
||||
whereBuilder.and(mapSheetMngEntity.mngYyyy.eq(mngYyyy));
|
||||
@@ -330,13 +326,16 @@ public class MapSheetMngRepositoryImpl extends QuerydslRepositorySupport
|
||||
mapSheetMngHstEntity.hstUid,
|
||||
Expressions.stringTemplate(
|
||||
"concat({0},substring({1}, 0, 6))",
|
||||
mapInkx5kEntity.mapidNm, mapSheetMngHstEntity.mapSheetNum).as("map50kName"),
|
||||
mapInkx5kEntity.mapidNm, mapSheetMngHstEntity.mapSheetNum)
|
||||
.as("map50kName"),
|
||||
Expressions.stringTemplate(
|
||||
"concat({0},substring({1}, 6, 8))",
|
||||
mapInkx5kEntity.mapidNm, mapSheetMngHstEntity.mapSheetNum).as("map5kName"),
|
||||
mapInkx5kEntity.mapidNm, mapSheetMngHstEntity.mapSheetNum)
|
||||
.as("map5kName"),
|
||||
Expressions.stringTemplate(
|
||||
"concat({0},substring({1}, 6, 8))",
|
||||
mapInkx5kEntity.mapidNm, mapSheetMngHstEntity.mapSheetNum).as("mapSrcName"),
|
||||
mapInkx5kEntity.mapidNm, mapSheetMngHstEntity.mapSheetNum)
|
||||
.as("mapSrcName"),
|
||||
mapInkx5kEntity.fid,
|
||||
mapSheetMngHstEntity.createdDate,
|
||||
mapSheetMngHstEntity.syncState,
|
||||
@@ -344,19 +343,16 @@ public class MapSheetMngRepositoryImpl extends QuerydslRepositorySupport
|
||||
mapSheetMngHstEntity.syncTifFileName,
|
||||
mapSheetMngHstEntity.syncCheckState,
|
||||
mapSheetMngHstEntity.syncCheckTfwFileName,
|
||||
mapSheetMngHstEntity.syncCheckTifFileName
|
||||
)
|
||||
)
|
||||
mapSheetMngHstEntity.syncCheckTifFileName))
|
||||
.from(mapSheetMngHstEntity)
|
||||
.innerJoin(mapInkx5kEntity).on(mapSheetMngHstEntity.mapSheetNum.eq(mapInkx5kEntity.mapidcdNo))
|
||||
.innerJoin(mapInkx5kEntity)
|
||||
.on(mapSheetMngHstEntity.mapSheetNum.eq(mapInkx5kEntity.mapidcdNo))
|
||||
.where(whereBuilder)
|
||||
.orderBy(mapSheetMngHstEntity.createdDate.desc())
|
||||
.offset(pageable.getOffset())
|
||||
.limit(pageable.getPageSize())
|
||||
.fetch();
|
||||
|
||||
|
||||
|
||||
Long countQuery =
|
||||
queryFactory
|
||||
.select(mapSheetMngHstEntity.hstUid.count())
|
||||
|
||||
Reference in New Issue
Block a user