init
This commit is contained in:
@@ -72,6 +72,16 @@ export async function getDashboardAnalysis(userId: string): Promise<AiAnalysis |
|
||||
);
|
||||
}
|
||||
|
||||
export async function listAnalysesForCalendar(
|
||||
userId: string
|
||||
): Promise<AiAnalysis[]> {
|
||||
const collection = await getCollection();
|
||||
return collection
|
||||
.find({ userId, targetType: "dashboard", targetId: DASHBOARD_TARGET_ID })
|
||||
.sort({ createdAt: -1 })
|
||||
.toArray();
|
||||
}
|
||||
|
||||
export async function saveDashboardAnalysis(
|
||||
userId: string,
|
||||
summary: string,
|
||||
|
||||
Reference in New Issue
Block a user