Merge pull request 'feat/dev_251201' (#117) from feat/dev_251201 into develop

Reviewed-on: https://kamco.gitea.gs.dabeeo.com/dabeeo/kamco-dabeeo-backoffice/pulls/117
This commit is contained in:
2025-12-29 11:11:15 +09:00
4 changed files with 20 additions and 16 deletions

View File

@@ -2,7 +2,6 @@ package com.kamco.cd.kamcoback.postgres.core;
import com.kamco.cd.kamcoback.config.api.ApiResponseDto.ApiResponseCode;
import com.kamco.cd.kamcoback.config.api.ApiResponseDto.ResponseObj;
import com.kamco.cd.kamcoback.postgres.entity.MapInkx50kEntity;
import com.kamco.cd.kamcoback.postgres.entity.MapInkx5kEntity;
import com.kamco.cd.kamcoback.postgres.repository.scene.MapInkx50kRepository;
import com.kamco.cd.kamcoback.postgres.repository.scene.MapInkx5kRepository;
@@ -39,21 +38,13 @@ public class MapInkxMngCoreService {
}
Integer fid50k = mapInkx50kRepository.findByMapidCdParentNo(req.getMapidcdNo());
if (fid50k == null || fid50k <= 0) {
// parent도 등록
MapInkx50kEntity parent =
new MapInkx50kEntity(req.getMapidcdNo().substring(0, 5), req.getMapidNm(), "", null);
MapInkx50kEntity result = mapInkx50kRepository.save(parent);
fid50k = result.getFid();
if (fid50k == null) {
return new ResponseObj(ApiResponseCode.NOT_FOUND_DATA, "1:50,000 도엽의 정보가 없습니다. 관리자에게 문의하세요.");
}
MapInkx5kEntity entity =
new MapInkx5kEntity(
req.getMapidcdNo(),
req.getMapidNm(),
map_polygon,
fid50k == null ? null : fid50k.longValue(),
"USE" // 기본은 USE로
req.getMapidcdNo(), req.getMapidNm(), map_polygon, fid50k.longValue(), "USE" // 기본은 USE로
);
mapInkx5kRepository.save(entity);