feat: 数据治理 — 入库约束+元数据卡片+编码清洗+审计看板
This commit is contained in:
@@ -260,7 +260,7 @@ def run_all_alert_checks(db: Session = Depends(get_db)):
|
||||
|
||||
value = latest_value.actual_value
|
||||
period = latest_value.period
|
||||
params = rule.params or {}
|
||||
import json; params = json.loads(rule.params) if isinstance(rule.params, str) else (rule.params or {})
|
||||
|
||||
alert_level = None
|
||||
alert_message = None
|
||||
@@ -534,7 +534,7 @@ def _check_forecast_alerts(db: Session) -> int:
|
||||
continue
|
||||
|
||||
# 检查预测值是否超限
|
||||
params = rule.params or {}
|
||||
import json; params = json.loads(rule.params) if isinstance(rule.params, str) else (rule.params or {})
|
||||
params["kpi"] = kpi
|
||||
for forecast in latest_forecasts:
|
||||
value = forecast.predicted_cash
|
||||
|
||||
Reference in New Issue
Block a user