국유인 실태조사 bulk 확인
This commit is contained in:
@@ -322,4 +322,23 @@ public class GukYuinApiController {
|
||||
@PathVariable String chnDtctObjtId) {
|
||||
return ApiResponseDto.ok(gukYuinApiService.findRlbDtctObject(chnDtctObjtId));
|
||||
}
|
||||
|
||||
@Operation(summary = "실태조사 적합여부 업데이트", description = "실태조사 적합여부 업데이트")
|
||||
@ApiResponses(
|
||||
value = {
|
||||
@ApiResponse(
|
||||
responseCode = "201",
|
||||
description = "등록 성공",
|
||||
content =
|
||||
@Content(
|
||||
mediaType = "application/json",
|
||||
schema = @Schema(implementation = DetectMastReq.class))),
|
||||
@ApiResponse(responseCode = "404", description = "코드를 찾을 수 없음", content = @Content),
|
||||
@ApiResponse(responseCode = "500", description = "서버 오류", content = @Content)
|
||||
})
|
||||
@PostMapping("/rlb/objt/{chnDtctObjtId}/stblt/{stbltYn}")
|
||||
public ApiResponseDto<ChngDetectContDto.ResultLabelDto> updateStbltObjtYn(
|
||||
@PathVariable String chnDtctObjtId, @PathVariable String stbltYn) {
|
||||
return ApiResponseDto.ok(gukYuinApiService.updateStbltObjtYn(chnDtctObjtId, stbltYn, ""));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -591,4 +591,41 @@ public class GukYuinApiService {
|
||||
result.body() != null && result.body().getSuccess());
|
||||
return result.body();
|
||||
}
|
||||
|
||||
public ChngDetectContDto.ResultLabelDto updateStbltObjtYn(
|
||||
String chnDtctObjtId, String stbltYn, String batchYn) {
|
||||
String url = gukyuinCdiUrl + "/rlb/objt/" + chnDtctObjtId + "/stblt/" + stbltYn;
|
||||
|
||||
ReqInfo info = new ReqInfo();
|
||||
info.setReqIp(myip);
|
||||
info.setReqEpno("Y".equals(batchYn) ? "BATCH" : userUtil.getEmployeeNo());
|
||||
|
||||
ExternalCallResult<ChngDetectContDto.ResultLabelDto> result =
|
||||
externalHttpClient.call(
|
||||
url,
|
||||
HttpMethod.POST,
|
||||
info,
|
||||
netUtils.jsonHeaders(),
|
||||
ChngDetectContDto.ResultLabelDto.class);
|
||||
|
||||
this.insertGukyuinAuditLog(
|
||||
EventType.MODIFIED.getId(),
|
||||
netUtils.getLocalIP(),
|
||||
userUtil.getId(),
|
||||
url.replace(gukyuinUrl, ""),
|
||||
null,
|
||||
result.body().getSuccess());
|
||||
|
||||
return result.body();
|
||||
}
|
||||
|
||||
public void stbltBulkUpdate(List<String> objectIds) {
|
||||
for (String objectId : objectIds) {
|
||||
this.updateStbltObjtYn(objectId, "Y", "");
|
||||
}
|
||||
}
|
||||
|
||||
public List<String> findStbltObjectIds(String uid, String mapSheetNum) {
|
||||
return gukyuinCoreService.findStbltObjectIds(uid, mapSheetNum);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user