Added announcement pages and api changes and types to fix announcements

This commit is contained in:
2025-01-21 19:20:43 -05:00
parent c32020aa47
commit 879dc44284
3 changed files with 9 additions and 5 deletions

View File

@@ -124,6 +124,6 @@ export async function fetchReleases(): Promise<{current_chapters:Chapter[],futur
}
export async function fetchAnnouncementById(announcementId: string): Promise<Announcement> {
const data = await fetchFromAPI<Announcement>(`/api/announcements/${announcementId}`);
const data = await fetchFromAPI<Announcement>(`/api/announcements/${announcementId}?`);
return data[0];
}

View File

@@ -65,6 +65,7 @@ export interface Book {
export interface Announcement {
id: number;
documentId: string;
title: string;
content: string;
datetime: string;