d1ab91adfa
Add customer confirmation/cancellation flow for appointments: - DB migration (0013): add confirmation_status, confirmed_at, cancelled_at, confirmation_token to appointments table with index on token column - schema.ts + factories.ts + types: expose new columns and ConfirmationStatus type - GET /api/book/confirm/:token — tokenized confirm via email link (redirects) - GET /api/book/cancel/:token — tokenized cancel via email link, single-use token - POST /api/appointments/:id/confirm — portal/staff confirm endpoint - POST /api/appointments/:id/cancel — portal/staff cancel endpoint - Reminder emails now include Confirm/Cancel CTA buttons with tokenized links - Reminder service generates confirmation token if missing before sending - Staff calendar shows confirmation status indicator on appointment cards and in the detail modal (confirmed ✓ / customer cancelled ✗) - /booking/confirmed, /booking/cancelled, /booking/error redirect pages - 23 new unit tests covering all new endpoints and edge cases Co-Authored-By: Paperclip <noreply@paperclip.ing>
50 lines
1.3 KiB
TypeScript
50 lines
1.3 KiB
TypeScript
export function BookingCancelledPage() {
|
|
return (
|
|
<div
|
|
style={{
|
|
minHeight: "100vh",
|
|
display: "flex",
|
|
alignItems: "center",
|
|
justifyContent: "center",
|
|
fontFamily: "system-ui, sans-serif",
|
|
background: "#fff7ed",
|
|
}}
|
|
>
|
|
<div
|
|
style={{
|
|
background: "#fff",
|
|
borderRadius: 12,
|
|
padding: "2.5rem 3rem",
|
|
boxShadow: "0 4px 24px rgba(0,0,0,0.08)",
|
|
textAlign: "center",
|
|
maxWidth: 420,
|
|
}}
|
|
>
|
|
<div style={{ fontSize: 56, marginBottom: "0.5rem" }}>✗</div>
|
|
<h1 style={{ color: "#c2410c", fontSize: 24, margin: "0 0 0.5rem" }}>
|
|
Appointment Cancelled
|
|
</h1>
|
|
<p style={{ color: "#4b5563", margin: "0 0 1.5rem" }}>
|
|
Your appointment has been cancelled. If this was a mistake or you'd
|
|
like to rebook, please contact us.
|
|
</p>
|
|
<a
|
|
href="/"
|
|
style={{
|
|
display: "inline-block",
|
|
padding: "0.6rem 1.5rem",
|
|
background: "#ea580c",
|
|
color: "#fff",
|
|
borderRadius: 6,
|
|
textDecoration: "none",
|
|
fontWeight: 600,
|
|
fontSize: 14,
|
|
}}
|
|
>
|
|
Back to Portal
|
|
</a>
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|