立项配置页初步优化

This commit is contained in:
Cheng Zhou
2026-02-24 16:53:22 +08:00
parent 0693f09b1d
commit 8f3f717e48
124 changed files with 12519 additions and 2954 deletions
+21
View File
@@ -61,8 +61,26 @@ export interface Study {
id: string;
code: string;
name: string;
project_full_name?: string | null;
sponsor?: string | null;
protocol_no?: string | null;
lead_unit?: string | null;
principal_investigator?: string | null;
main_pm?: string | null;
research_analysis?: string | null;
research_product?: string | null;
control_product?: string | null;
indication?: string | null;
research_population?: string | null;
research_design?: string | null;
plan_start_date?: string | null;
plan_end_date?: string | null;
planned_site_count?: number | null;
planned_enrollment_count?: number | null;
enrollment_monthly_goal_note?: string | null;
enrollment_stage_breakdown?: string | null;
summary_note?: string | null;
objective_note?: string | null;
phase?: string | null;
status: string;
is_locked?: boolean;
@@ -92,6 +110,9 @@ export interface Site {
pi_name?: string | null;
contact?: string | null;
enrollment_target?: number | null;
enrollment_plan_start_date?: string | null;
enrollment_plan_end_date?: string | null;
enrollment_plan_note?: string | null;
is_active: boolean;
created_at?: string;
}
+116
View File
@@ -0,0 +1,116 @@
export interface ProjectMilestoneDraft {
id: string;
name: string;
planDate: string;
owner: string;
remark: string;
status: "未开始" | "进行中" | "已完成" | string;
}
export interface EnrollmentPlanDraft {
totalTarget: number;
startDate: string;
endDate: string;
monthlyGoalNote: string;
stageBreakdown: string;
}
export interface SiteMilestoneDraft {
id: string;
milestone: string;
planDate: string;
owner: string;
remark: string;
status: "未开始" | "进行中" | "已完成" | string;
}
export interface SiteEnrollmentPlanDraft {
id: string;
siteId: string;
siteName: string;
target: number;
startDate: string;
endDate: string;
note: string;
stageBreakdown: string;
}
export interface MonitoringStrategyDraft {
id: string;
strategyType: string;
detail: string;
frequency: string;
updatedAt: string;
enabled: boolean;
}
export interface CenterConfirmDraft {
id: string;
siteId: string;
siteName: string;
confirmer: string;
confirmStatus: "待确认" | "已确认" | "退回" | string;
confirmDate: string;
note: string;
}
export interface SetupConfigDraft {
projectMilestones: ProjectMilestoneDraft[];
enrollmentPlan: EnrollmentPlanDraft;
siteMilestones: SiteMilestoneDraft[];
siteEnrollmentPlans: SiteEnrollmentPlanDraft[];
monitoringStrategies: MonitoringStrategyDraft[];
centerConfirm: CenterConfirmDraft[];
}
export interface StudySetupConfigResponse {
id: string;
study_id: string;
version: number;
data: SetupConfigDraft;
publish_status: "DRAFT" | "PUBLISHED" | string;
published_data?: SetupConfigDraft | null;
published_by?: string | null;
published_by_name?: string | null;
published_at?: string | null;
saved_by?: string | null;
saved_by_name?: string | null;
projection_status?: "success" | "partial_success" | "failed" | string | null;
projection_summary?: {
study_updated?: boolean;
site_updated_count?: number;
site_skipped_count?: number;
warnings?: string[];
skipped_items?: Array<{ site_id: string; reason: string }>;
} | null;
created_at: string;
updated_at: string;
}
export interface StudySetupConfigUpsertPayload {
expected_version?: number | null;
data: SetupConfigDraft;
}
export interface StudySetupConfigPublishPayload {
expected_version?: number | null;
}
export interface StudySetupConfigRollbackPayload {
expected_version?: number | null;
target_version: number;
}
export interface StudySetupConfigVersionItem {
id: string;
study_id: string;
study_setup_config_id: string;
version: number;
display_version: number;
source_version?: number | null;
config: SetupConfigDraft;
published_by?: string | null;
published_by_name?: string | null;
published_at: string;
created_at: string;
}