feat: Add daily event notification emails via cron job
- Add node-cron for scheduled tasks - Create cron/calendar structure with: - email-template.js: HTML email template for event notifications - event-notifier.js: Logic to query tomorrow's events and send emails - index.js: Cron scheduler (runs daily at configurable time) - Send notifications via JMAP using sender email from database - Add admin endpoint POST /api/admin/trigger-notifications for testing - Add env variables: NOTIFICATION_TIME, NOTIFICATION_SENDER_EMAIL 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
10
package-lock.json
generated
10
package-lock.json
generated
@@ -22,6 +22,7 @@
|
||||
"jsonwebtoken": "^9.0.2",
|
||||
"morgan": "^1.10.0",
|
||||
"multer": "^2.0.2",
|
||||
"node-cron": "^4.2.1",
|
||||
"pg": "^8.16.3",
|
||||
"uuid": "^13.0.0",
|
||||
"xss-clean": "^0.1.4",
|
||||
@@ -6431,6 +6432,15 @@
|
||||
"node": ">= 0.6"
|
||||
}
|
||||
},
|
||||
"node_modules/node-cron": {
|
||||
"version": "4.2.1",
|
||||
"resolved": "https://registry.npmjs.org/node-cron/-/node-cron-4.2.1.tgz",
|
||||
"integrity": "sha512-lgimEHPE/QDgFlywTd8yTR61ptugX3Qer29efeyWw2rv259HtGBNn1vZVmp8lB9uo9wC0t/AT4iGqXxia+CJFg==",
|
||||
"license": "ISC",
|
||||
"engines": {
|
||||
"node": ">=6.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/node-int64": {
|
||||
"version": "0.4.0",
|
||||
"resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz",
|
||||
|
||||
Reference in New Issue
Block a user