From 6cd3a015c2187d7b41240616c82227ed8b12caa5 Mon Sep 17 00:00:00 2001 From: bluehorn07 Date: Tue, 26 Dec 2023 22:18:51 +0900 Subject: [PATCH] add accept all processing method description --- .../place/place.reservation.wait.table.jsx | 162 ++++++++++-------- 1 file changed, 89 insertions(+), 73 deletions(-) diff --git a/components/place/place.reservation.wait.table.jsx b/components/place/place.reservation.wait.table.jsx index cbc101a..b7a4377 100644 --- a/components/place/place.reservation.wait.table.jsx +++ b/components/place/place.reservation.wait.table.jsx @@ -11,7 +11,7 @@ const PlaceReservationWaitTable = ({reservations}) => { function acceptAllInProgressPlaceReservations() { PoPoAxios.patch('/reservation-place/all/status/accept', {uuid_list: selectedUuidList}, {withCredentials: true}).then(() => { - alert('선택한 장소 예약을 승인했습니다.') + alert(`${selectedUuidList.length}개 장소 예약을 일괄 승인했습니다.`) window.location.reload(); }).catch(err => { const errMsg = err.response.data.message; @@ -31,13 +31,19 @@ const PlaceReservationWaitTable = ({reservations}) => { } return ( - <> - - - - +
+ + + +
+

+ 일괄 예약 승인은 예약 생성 순으로 처리 됩니다.
+ 일괄 처리 도중 예약 Overlap이 발생하면, 처리가 중단 됩니다.
+ 일괄 예약 승인 때는 승인 메일을 보내지 않습니다.
+

+
- - - - idx. - 장소명 - 사용자 - 예약 제목 - 예약 기간 - - - - - { - reservations.map((reservation, idx) => { - const reservation_end_datetime = moment( - `${reservation.date} ${reservation.end_time}`, 'YYYYMMDD HHmm') - const isOutdated = moment() > reservation_end_datetime +
+
+
+
+ + idx. + 장소명 + 사용자 + 예약 제목 + 예약 기간 + + +
+ + { + reservations.map((reservation, idx) => { + const reservation_end_datetime = moment( + `${reservation.date} ${reservation.end_time}`, 'YYYYMMDD HHmm') + const isOutdated = moment() > reservation_end_datetime - return ( - - {idx + 1} - {reservation.place.name} - {reservation.booker.name} - {reservation.title} - } - /> - - - {moment(reservation.date, 'YYYYMMDD'). - format('YYYY년 MM월 DD일')} -
- {moment(reservation.start_time, 'HHmm'). - format('HH:mm')} -  ~  - {moment(reservation.end_time, 'HHmm'). - format('HH:mm')} -
-
- - handleCheck(reservation.uuid)}/> - -
- ) - } + return ( + + {idx + 1} + {reservation.place.name} + {reservation.booker.name} + {reservation.title} + } + /> + + + {moment(reservation.date, 'YYYYMMDD'). + format('YYYY년 MM월 DD일')} +
+ {moment(reservation.start_time, 'HHmm'). + format('HH:mm')} +  ~  + {moment(reservation.end_time, 'HHmm'). + format('HH:mm')} +
+
+ + handleCheck(reservation.uuid)}/> + +
) - } -
+ } + ) + } + - - - - - - - -
- + + + +
+

+ 일괄 예약 승인은 예약 생성 순으로 처리 됩니다.
+ 일괄 처리 도중 예약 Overlap이 발생하면, 처리가 중단 됩니다.
+ 일괄 예약 승인 때는 승인 메일을 보내지 않습니다.
+

+
+ +
+
+
+
+
+ ) }