Füge Archivierungs-Funktion für Kommentare hinzu und fixe initiales Laden

- Archivierungs-Funktionalität: Kuratoren können Kommentare archivieren
- archived-Flag in CuratorCommentRecipient hinzugefügt
- API-Route für Archivieren: /api/curator-comments/[id]/archive
- Kommentare werden beim initialen Laden automatisch abgerufen
- Archivierte Kommentare werden nicht mehr in der Liste angezeigt
- Archivieren-Button in der UI hinzugefügt
- Migration für archived-Feld
- Übersetzungen für Archivierung (DE/EN)
This commit is contained in:
Hördle Bot
2025-12-03 22:57:28 +01:00
parent 08fedf9881
commit 95bcf9ed1e
7 changed files with 123 additions and 14 deletions

View File

@@ -22,10 +22,11 @@ export async function GET(request: NextRequest) {
try {
const curatorId = context.curator.id;
// Get all comments for this curator, ordered by creation date (newest first)
// Get all non-archived comments for this curator, ordered by creation date (newest first)
const comments = await prisma.curatorCommentRecipient.findMany({
where: {
curatorId: curatorId
curatorId: curatorId,
archived: false
},
include: {
comment: {