- 新增 model_deploy 与 model_operations 双库查询,支持模型列表、模型详情、单月监控结果和运维工作台真实接口。 - 关闭运维模块生产 Mock 数据,补充缺表/空数据降级、工作台空状态和首条纵向链路测试。 - 按业务团队、模型团队、管理员权限矩阵接入菜单、页面、操作按钮和后端接口权限校验,支持 business_team 角色。 - 更新工作台布局、深色欢迎卡片、全宽页面适配、顶部回退,以及权限分组展示。 - 新增架构实现基线、周目标完成情况和角色权限矩阵初始化 SQL 文档。
31 lines
987 B
TypeScript
31 lines
987 B
TypeScript
export type ReportStatus = "待模型团队阅读" | "编辑中" | "已发送业务团队";
|
|
export type ReportType = "监控报告" | "诊断报告";
|
|
|
|
export type MonitoringReport = {
|
|
reportId: string;
|
|
bank: string;
|
|
modelName: string;
|
|
modelId: string;
|
|
version: string;
|
|
monitorMonth: string;
|
|
type: ReportType;
|
|
status: ReportStatus;
|
|
generatedAt: string;
|
|
outputDate: string;
|
|
unreadDays: number;
|
|
synced: boolean;
|
|
};
|
|
|
|
// 报告数据由后端报告接口提供。接口接入前保持为空,不使用本地样例。
|
|
export const REPORTS: MonitoringReport[] = [];
|
|
|
|
export function latestReports(source: MonitoringReport[] = REPORTS): MonitoringReport[] {
|
|
const latestMonth = source.reduce((latest, report) => report.monitorMonth > latest ? report.monitorMonth : latest, "");
|
|
return source.filter((report) => report.monitorMonth === latestMonth);
|
|
}
|
|
|
|
export function createReportForModel(modelId: string): MonitoringReport | null {
|
|
void modelId;
|
|
return null;
|
|
}
|