mirror of
https://github.com/kjanat/livedash-node.git
synced 2026-01-16 13:12:10 +01:00
feat: Enhance session processing and metrics
- Updated session processing commands in documentation for clarity. - Removed transcript content fetching from session processing, allowing on-demand retrieval. - Improved session metrics calculations and added new metrics for dashboard. - Refactored processing scheduler to handle sessions in parallel with concurrency limits. - Added manual trigger API for processing unprocessed sessions with admin checks. - Implemented scripts for fetching and parsing transcripts, checking transcript content, and testing processing status. - Updated Prisma schema to enforce default values for processed sessions. - Added error handling and logging improvements throughout the processing workflow.
This commit is contained in:
@ -35,10 +35,13 @@ export default async function handler(
|
||||
|
||||
// Get date range from query parameters
|
||||
const { startDate, endDate } = req.query;
|
||||
|
||||
// Build where clause with optional date filtering
|
||||
const whereClause: any = { companyId: user.companyId };
|
||||
|
||||
|
||||
// Build where clause with optional date filtering and only processed sessions
|
||||
const whereClause: any = {
|
||||
companyId: user.companyId,
|
||||
processed: true, // Only show processed sessions in dashboard
|
||||
};
|
||||
|
||||
if (startDate && endDate) {
|
||||
whereClause.startTime = {
|
||||
gte: new Date(startDate as string),
|
||||
|
||||
Reference in New Issue
Block a user