Skip to content

Deploy email support#97

Merged
amcewen merged 14 commits into
masterfrom
develop
Jun 2, 2026
Merged

Deploy email support#97
amcewen merged 14 commits into
masterfrom
develop

Conversation

@amcewen

@amcewen amcewen commented Mar 3, 2026

Copy link
Copy Markdown
Member

Send emails when bookings are made, allow bookings to be cancelled. Most of #7 and #6

Adrian McEwen and others added 14 commits January 6, 2026 21:00
- Switch knex client from sqlite3 to better-sqlite3 in knexfile.js
- Update modelItemsBase.js to support better-sqlite3 client
- Remove @vscode/sqlite3 dependency (requires native compilation)
- Fix db.js configuration syntax
- Prevent selection of unavailable/booked calendar slots
- Replace incomplete overlap check with proper range overlap logic
- Full-day slots now correctly marked unavailable when half-day is booked
- Add overlap detection logic to check existing bookings before creating new ones
- Validate resource capacity is not exceeded
- Return 409 error when time slot is fully booked
- Add token and cancelled columns to bookings table via migration
- Implement email service
- Auto-generate unique tokens for bookings on creation
- Add POST /api/bookings/cancel/:token endpoint for cancellations
- Add GET /cancel-booking/:token website route with confirmation page
- Update booking queries to filter out cancelled bookings from availability
- Update validation to allow optional token/cancelled fields in POST requests
- Display booking details (resource, time slot, notes) on confirmation
- Show confirmation email notification message
- Add Bootstrap modal for cancellation confirmation with booking details
- Clean up page headings and improve UI layout
- Add token and cancelled columns to bookings table via migration
Add a date stamp to the token to avoid duplication
Add sending emails for bookings and ability to cancel bookings
…nt to get suitable email settings. Two tests still failing though.
Fix test to check the response, if it is array, use the first item, otherwise consider as object
@amcewen amcewen merged commit 0c2abee into master Jun 2, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants