feat: extend notification system with batch sender, bulk dialog, and logging
Add NotificationLog schema extensions (nullable userId, email, roundId, projectId, batchId fields), batch notification sender service, and bulk notification dialog UI. Include utility scripts for debugging and seeding. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
20
scripts/check-rounds.cjs
Normal file
20
scripts/check-rounds.cjs
Normal file
@@ -0,0 +1,20 @@
|
||||
const { PrismaClient } = require('@prisma/client');
|
||||
const p = new PrismaClient({ datasourceUrl: 'postgresql://mopc:devpassword@localhost:5433/mopc' });
|
||||
|
||||
(async () => {
|
||||
const rounds = await p.round.findMany({
|
||||
orderBy: { sortOrder: 'asc' },
|
||||
select: { id: true, name: true, roundType: true, status: true, sortOrder: true, competitionId: true },
|
||||
});
|
||||
for (const r of rounds) console.log(r.sortOrder, '|', r.name, '|', r.roundType, '|', r.status, '|', r.id);
|
||||
|
||||
console.log('\n--- File Requirements:');
|
||||
const reqs = await p.fileRequirement.findMany({ include: { round: { select: { name: true } } } });
|
||||
for (const r of reqs) console.log(r.round.name, '|', r.name, '|', r.isRequired, '|', r.id);
|
||||
|
||||
console.log('\n--- Submission Windows:');
|
||||
const wins = await p.submissionWindow.findMany({ select: { id: true, name: true, roundNumber: true, windowOpenAt: true, windowCloseAt: true, competitionId: true } });
|
||||
for (const w of wins) console.log(w.name, '| round#', w.roundNumber, '| open:', w.windowOpenAt?.toISOString().slice(0,16), '| close:', w.windowCloseAt?.toISOString().slice(0,16));
|
||||
|
||||
await p.$disconnect();
|
||||
})();
|
||||
Reference in New Issue
Block a user