Archived
- Site settings -> Licence shows the release notes for every newer version from the Hub; urgent (security/serious) updates are marked and can't be put off. - Withdraw an update request (the provider is told through the Hub). - "Not now" on the banner or Licence page hides update reminders until the next version. - Notices from the provider show as a dashboard banner for site admins and supervisors, in their time window, and on the Licence page. - New audit actions (migration), API docs, help, protocol doc, tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
19 lines
1.1 KiB
JavaScript
19 lines
1.1 KiB
JavaScript
const express = require('express');
|
|
const router = express.Router();
|
|
const { getStatus, connect, heartbeatNow, requestUpdate, cancelUpdateRequest, snoozeUpdate, getNotices } = require('../controllers/hubController');
|
|
const { protect, admin, supervisor } = require('../middleware/authMiddleware');
|
|
const { campusIndependent } = require('../utils/campusScope');
|
|
|
|
// Licence and the Cross Events Hub (docs/hub-protocol.md). Admins only; the setup wizard's
|
|
// admin token counts, so the licence step can run during /setup.
|
|
router.get('/status', protect, admin, getStatus);
|
|
router.post('/connect', protect, admin, connect);
|
|
router.post('/heartbeat', protect, admin, heartbeatNow);
|
|
router.post('/update-request', protect, admin, requestUpdate);
|
|
router.post('/update-request/cancel', protect, admin, cancelUpdateRequest);
|
|
router.post('/update-snooze', protect, admin, snoozeUpdate);
|
|
// The provider's notices: site admins and supervisors see them as a banner.
|
|
router.get('/notices', protect, supervisor, campusIndependent('notices from the provider are for the whole site'), getNotices);
|
|
|
|
module.exports = router;
|