From 337dccaf34203036b3f6683316e6a398c2142892 Mon Sep 17 00:00:00 2001 From: sojungpp Date: Sun, 3 Dec 2023 17:13:19 +0900 Subject: [PATCH 1/2] =?UTF-8?q?[PDS-73]=20fix:=20=EC=98=88=EC=95=BD=20?= =?UTF-8?q?=EB=82=B4=EC=97=AD=20=EC=A0=84=EC=B2=B4=20=EC=A1=B0=ED=9A=8C=20?= =?UTF-8?q?=EC=8B=9C,=20=EC=98=88=EC=95=BD=20=EB=8C=80=EC=83=81=20targetId?= =?UTF-8?q?=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../booking/dto/response/AdminBookingRes.java | 5 ++++- .../pladialmserver/booking/dto/response/BookingRes.java | 7 ++++++- .../product/dto/response/AdminProductRes.java | 6 +++++- 3 files changed, 15 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/example/pladialmserver/booking/dto/response/AdminBookingRes.java b/src/main/java/com/example/pladialmserver/booking/dto/response/AdminBookingRes.java index 6cad25ea..de26599c 100644 --- a/src/main/java/com/example/pladialmserver/booking/dto/response/AdminBookingRes.java +++ b/src/main/java/com/example/pladialmserver/booking/dto/response/AdminBookingRes.java @@ -10,8 +10,10 @@ @Builder public class AdminBookingRes { - @Schema(type = "Long", description = "회의실 Id / 자원 Id", example = "1") + @Schema(type = "Long", description = "예약 Id", example = "1") private Long id; + @Schema(type = "Long", description = "회의실 Id / 자원 Id", example = "1") + private Long targetId; @Schema(type = "String", description = "회의실명 / 자원명", example = "'회의실1' / '카메라1'") private String name; @Schema(type = "String", description = "회의실 위치 / 카테고리", example = "'401호' / '촬영장비'") @@ -30,6 +32,7 @@ public class AdminBookingRes { public static AdminBookingRes toDto(OfficeBooking officeBooking){ return AdminBookingRes.builder() .id(officeBooking.getOfficeBookingId()) + .targetId(officeBooking.getOffice().getOfficeId()) .name(officeBooking.getOffice().getName()) .detailInfo(officeBooking.getOffice().getLocation()) .startDateTime(DateTimeUtil.dateAndTimeToString(officeBooking.getDate(),officeBooking.getStartTime())) diff --git a/src/main/java/com/example/pladialmserver/booking/dto/response/BookingRes.java b/src/main/java/com/example/pladialmserver/booking/dto/response/BookingRes.java index f7fcf297..5a8510d7 100644 --- a/src/main/java/com/example/pladialmserver/booking/dto/response/BookingRes.java +++ b/src/main/java/com/example/pladialmserver/booking/dto/response/BookingRes.java @@ -12,8 +12,10 @@ @Builder public class BookingRes { - @Schema(type = "Long", description = "Id", example = "1") + @Schema(type = "Long", description = "예약 Id", example = "1") private Long id; + @Schema(type = "Long", description = "예약 대상 Id", example = "1") + private Long targetId; @Schema(type = "String", description = "회의실명 / 장비명 / 차량명", example = "'회의실1' / '카메라1' / '벤틀리'") private String name; @Schema(type = "String", description = "회의실 위치 / 보관장소", example = "'401호' / '3층 A홀' / '주차장'") @@ -30,6 +32,7 @@ public class BookingRes { public static BookingRes toDto(OfficeBooking officeBooking) { return BookingRes.builder() .id(officeBooking.getOfficeBookingId()) + .targetId(officeBooking.getOffice().getOfficeId()) .name(officeBooking.getOffice().getName()) .detailInfo(officeBooking.getOffice().getLocation()) .startDateTime(DateTimeUtil.dateAndTimeToString(officeBooking.getDate(), officeBooking.getStartTime())) @@ -42,6 +45,7 @@ public static BookingRes toDto(OfficeBooking officeBooking) { public static BookingRes toDto(ResourceBooking resourceBooking) { return BookingRes.builder() .id(resourceBooking.getResourceBookingId()) + .targetId(resourceBooking.getResource().getResourceId()) .name(resourceBooking.getResource().getName()) .detailInfo(resourceBooking.getResource().getLocation()) .startDateTime(DateTimeUtil.dateTimeToString(resourceBooking.getStartDate())) @@ -54,6 +58,7 @@ public static BookingRes toDto(ResourceBooking resourceBooking) { public static BookingRes toDto(CarBooking carBooking) { return BookingRes.builder() .id(carBooking.getCarBookingId()) + .targetId(carBooking.getCar().getCarId()) .name(carBooking.getCar().getName()) .detailInfo(carBooking.getCar().getLocation()) .startDateTime(DateTimeUtil.dateTimeToString(carBooking.getStartDate())) diff --git a/src/main/java/com/example/pladialmserver/product/dto/response/AdminProductRes.java b/src/main/java/com/example/pladialmserver/product/dto/response/AdminProductRes.java index c31b142e..09ac0160 100644 --- a/src/main/java/com/example/pladialmserver/product/dto/response/AdminProductRes.java +++ b/src/main/java/com/example/pladialmserver/product/dto/response/AdminProductRes.java @@ -10,8 +10,10 @@ @Data @Builder public class AdminProductRes { - @Schema(type = "Long", description = "Id", example = "1") + @Schema(type = "Long", description = "예약 Id", example = "1") private Long id; + @Schema(type = "Long", description = "예약 대상 Id", example = "1") + private Long targetId; @Schema(type = "String", description = "장비 이름", example = "'벤츠'") private String name; @Schema(type = "String", description = "보관장소", example = "'4층 창고'") @@ -30,6 +32,7 @@ public class AdminProductRes { public static AdminProductRes toDto(ResourceBooking resourceBooking){ return AdminProductRes.builder() .id(resourceBooking.getResourceBookingId()) + .targetId(resourceBooking.getResource().getResourceId()) .name(resourceBooking.getResource().getName()) .location(resourceBooking.getResource().getLocation()) .startDateTime(DateTimeUtil.dateTimeToString(resourceBooking.getStartDate())) @@ -43,6 +46,7 @@ public static AdminProductRes toDto(ResourceBooking resourceBooking){ public static AdminProductRes toDto(CarBooking carBooking){ return AdminProductRes.builder() .id(carBooking.getCarBookingId()) + .targetId(carBooking.getCar().getCarId()) .name(carBooking.getCar().getName()) .location(carBooking.getCar().getLocation()) .startDateTime(DateTimeUtil.dateTimeToString(carBooking.getStartDate())) From 22e1feb290d3e63cc1ac40a6780bb641f0e4dca9 Mon Sep 17 00:00:00 2001 From: sojungpp Date: Sun, 3 Dec 2023 17:15:08 +0900 Subject: [PATCH 2/2] =?UTF-8?q?[PDS-73]=20fix:=20=EA=B4=80=EB=A6=AC?= =?UTF-8?q?=EC=9E=90=20=EC=98=88=EC=95=BD=20=EB=82=B4=EC=97=AD=20=EC=A0=84?= =?UTF-8?q?=EC=B2=B4=20=EC=A1=B0=ED=9A=8C=20=EC=8B=9C,=20=EC=9D=B4?= =?UTF-8?q?=EC=9A=A9=EB=AA=A9=EC=A0=81=20res=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pladialmserver/booking/dto/response/AdminBookingRes.java | 3 +++ .../pladialmserver/product/dto/response/AdminProductRes.java | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/src/main/java/com/example/pladialmserver/booking/dto/response/AdminBookingRes.java b/src/main/java/com/example/pladialmserver/booking/dto/response/AdminBookingRes.java index de26599c..de15d7ec 100644 --- a/src/main/java/com/example/pladialmserver/booking/dto/response/AdminBookingRes.java +++ b/src/main/java/com/example/pladialmserver/booking/dto/response/AdminBookingRes.java @@ -26,6 +26,8 @@ public class AdminBookingRes { private String reservatorName; @Schema(type = "String", description = "예약자 전화번호", example = "010-4158-8124") private String reservatorPhone; + @Schema(type = "String", description = "이용목적", example = "드라마 촬영") + private String memo; @Schema(type = "String", description = "상태", example = "'예약중' / '사용중'") private String status; @@ -39,6 +41,7 @@ public static AdminBookingRes toDto(OfficeBooking officeBooking){ .endDateTime(DateTimeUtil.dateAndTimeToString(officeBooking.getDate(),officeBooking.getEndTime())) .reservatorName(officeBooking.getUser().getName()) .reservatorPhone(officeBooking.getUser().getPhone()) + .memo(officeBooking.getMemo()) .status(officeBooking.getStatus().getValue()) .build(); } diff --git a/src/main/java/com/example/pladialmserver/product/dto/response/AdminProductRes.java b/src/main/java/com/example/pladialmserver/product/dto/response/AdminProductRes.java index 09ac0160..4f9fc6c8 100644 --- a/src/main/java/com/example/pladialmserver/product/dto/response/AdminProductRes.java +++ b/src/main/java/com/example/pladialmserver/product/dto/response/AdminProductRes.java @@ -26,6 +26,8 @@ public class AdminProductRes { private String reservatorName; @Schema(type = "String", description = "예약자 전화번호", example = "010-0000-0000") private String reservatorPhone; + @Schema(type = "String", description = "이용목적", example = "드라마 촬영") + private String memo; @Schema(type = "String", description = "상태", example = "'예약중' / '사용중'") private String status; @@ -39,6 +41,7 @@ public static AdminProductRes toDto(ResourceBooking resourceBooking){ .endDateTime(DateTimeUtil.dateTimeToString(resourceBooking.getEndDate())) .reservatorName(resourceBooking.getUser().getName()) .reservatorPhone(resourceBooking.getUser().getPhone()) + .memo(resourceBooking.getMemo()) .status(resourceBooking.getStatus().getValue()) .build(); } @@ -53,6 +56,7 @@ public static AdminProductRes toDto(CarBooking carBooking){ .endDateTime(DateTimeUtil.dateTimeToString(carBooking.getEndDate())) .reservatorName(carBooking.getUser().getName()) .reservatorPhone(carBooking.getUser().getPhone()) + .memo(carBooking.getMemo()) .status(carBooking.getStatus().getValue()) .build(); }