feat: allow marking no show after booking has started (#17625)
* feat: allow marking no show after booking has started * fix --------- Co-authored-by: Udit Takkar <[email protected]>
This commit is contained in:
1 parent
65484e7d01
commit
ff2754f663
2 files changed
+12
-1
No files matched your search
@@ -132,6 +132,7 @@ function BookingListItem(booking: BookingItemProps) {
|
||||
});
|
||||
|
||||
const isUpcoming = new Date(booking.endTime) >= new Date();
|
||||
const isOngoing = isUpcoming && new Date() >= new Date(booking.startTime);
|
||||
const isBookingInPast = new Date(booking.endTime) < new Date();
|
||||
const isCancelled = booking.status === BookingStatus.CANCELLED;
|
||||
const isConfirmed = booking.status === BookingStatus.ACCEPTED;
|
||||
@@ -269,7 +270,7 @@ function BookingListItem(booking: BookingItemProps) {
|
||||
});
|
||||
}
|
||||
|
||||
if (isBookingInPast) {
|
||||
if (isBookingInPast || isOngoing) {
|
||||
editBookingActions.push({
|
||||
id: "no_show",
|
||||
label: t("mark_as_no_show"),
|
||||
|
||||
Reference in new issue
Block a user