feat(ia): polish project operation workspaces

This commit is contained in:
Cheng Zhou
2026-06-08 11:06:07 +08:00
parent 834b4f1d48
commit 8cd8c38900
25 changed files with 2744 additions and 1516 deletions
+3 -3
View File
@@ -1,6 +1,6 @@
"""概览数据聚合CRUD操作"""
import uuid
from datetime import datetime
from datetime import datetime, timezone
from typing import Dict, List, Tuple
from sqlalchemy import Date, cast, func, select, and_, or_
@@ -34,7 +34,7 @@ async def get_project_overview(db: AsyncSession, study_id: uuid.UUID) -> Dict:
if not sites:
return {
"study_id": str(study_id),
"updated_at": datetime.now().isoformat(),
"updated_at": datetime.now(timezone.utc).isoformat(),
"centers": [],
"enrollment_by_month": []
}
@@ -138,7 +138,7 @@ async def get_project_overview(db: AsyncSession, study_id: uuid.UUID) -> Dict:
return {
"study_id": str(study_id),
"updated_at": datetime.now().isoformat(),
"updated_at": datetime.now(timezone.utc).isoformat(),
"centers": centers,
"enrollment_by_month": monthly_enrollment
}