Fix TypeScript errors for Docker build
- Fix optional chaining for booking properties - Fix useMutation isLoading to isPending - Fix email parameter types - Fix expiredDetails array typing
This commit is contained in:
@@ -343,7 +343,17 @@ export const router = {
|
||||
}
|
||||
|
||||
// Get booking details for each expired proposal
|
||||
const expiredDetails = [];
|
||||
const expiredDetails: Array<{
|
||||
customerName: string;
|
||||
originalDate: string;
|
||||
originalTime: string;
|
||||
proposedDate: string;
|
||||
proposedTime: string;
|
||||
treatmentName: string;
|
||||
customerEmail?: string;
|
||||
customerPhone?: string;
|
||||
expiredAt: string;
|
||||
}> = [];
|
||||
for (const proposal of expiredProposals) {
|
||||
const booking = await bookingsKV.getItem(proposal.bookingId);
|
||||
if (booking) {
|
||||
@@ -353,8 +363,8 @@ export const router = {
|
||||
customerName: booking.customerName,
|
||||
originalDate: proposal.originalDate || booking.appointmentDate,
|
||||
originalTime: proposal.originalTime || booking.appointmentTime,
|
||||
proposedDate: proposal.proposedDate,
|
||||
proposedTime: proposal.proposedTime,
|
||||
proposedDate: proposal.proposedDate!,
|
||||
proposedTime: proposal.proposedTime!,
|
||||
treatmentName: treatment?.name || "Unbekannte Behandlung",
|
||||
customerEmail: booking.customerEmail,
|
||||
customerPhone: booking.customerPhone,
|
||||
|
Reference in New Issue
Block a user