diff --git a/pothole-core/src/main/java/pothole_solution/core/domain/pothole/dto/response/RespPotSimInfoPotMngrCntrDto.java b/pothole-core/src/main/java/pothole_solution/core/domain/pothole/dto/response/RespPotSimInfoPotMngrCntrDto.java index 6bbcecf..6f2a885 100644 --- a/pothole-core/src/main/java/pothole_solution/core/domain/pothole/dto/response/RespPotSimInfoPotMngrCntrDto.java +++ b/pothole-core/src/main/java/pothole_solution/core/domain/pothole/dto/response/RespPotSimInfoPotMngrCntrDto.java @@ -10,9 +10,12 @@ @NoArgsConstructor public class RespPotSimInfoPotMngrCntrDto { private Long potholeId; - private String roadAddress; private double lat; private double lon; + private String roadAddress; + private String roadName; // 도로명 + private String roadNumber; // 도로 번호 + private String zipCode; // 우편 번호 private String thumbnail; private Integer importance; private Integer dangerous; @@ -21,9 +24,12 @@ public class RespPotSimInfoPotMngrCntrDto { @Builder public RespPotSimInfoPotMngrCntrDto(Pothole pothole) { this.potholeId = pothole.getPotholeId(); - this.roadAddress = pothole.getRoadAddress(); this.lat = pothole.getPoint().getY(); this.lon = pothole.getPoint().getX(); + this.roadName = pothole.getRoadName(); + this.roadNumber = pothole.getRoadNumber(); + this.zipCode = pothole.getZipCode(); + this.roadAddress = pothole.getRoadAddress(); this.thumbnail = pothole.getThumbnail(); this.importance = pothole.getImportance(); this.dangerous = pothole.getDangerous(); diff --git a/pothole-manager-api/src/main/java/pothole_solution/manager/controller/PotholeManagerController.java b/pothole-manager-api/src/main/java/pothole_solution/manager/controller/PotholeManagerController.java index 44ce3a1..60af248 100644 --- a/pothole-manager-api/src/main/java/pothole_solution/manager/controller/PotholeManagerController.java +++ b/pothole-manager-api/src/main/java/pothole_solution/manager/controller/PotholeManagerController.java @@ -26,14 +26,6 @@ public class PotholeManagerController { private final PotholeHistoryImageManagerService potholeHistoryImageManagerService; private final RoadAddressSearchService roadAddressSearchService; - @PostMapping("/test") - public BaseResponse registerPotholeTest(@Valid @RequestBody ReqPotRegPotMngrServDto reqPotRegPotMngrServDto){ - String point = reqPotRegPotMngrServDto.getLat() + "," + reqPotRegPotMngrServDto.getLon(); - RoadAddress roadAddress = roadAddressSearchService.getRoadAddress(point); - - return new BaseResponse<>(roadAddress); - } - //TODO: 엄밀히 따지면 core 쪽에 있어야 되는거 아닌가? @PostMapping public BaseResponse registerPothole(@Valid @RequestPart(value = "registerPothole") ReqPotRegPotMngrServDto reqPotRegPotMngrServDto,