refactor(ops): 优化运维监控数据仓库层查询逻辑

This commit is contained in:
IanShaw027
2026-01-11 20:55:52 +08:00
parent a2f83ff032
commit f5e45c1a8a
3 changed files with 7 additions and 8 deletions

View File

@@ -75,7 +75,7 @@ error_base AS (
group_id AS group_id,
is_business_limited AS is_business_limited,
error_owner AS error_owner,
status_code AS status_code
COALESCE(upstream_status_code, status_code) AS status_code
FROM ops_error_logs
WHERE created_at >= $1 AND created_at < $2
),
@@ -356,4 +356,3 @@ func (r *opsRepository) GetLatestDailyBucketDate(ctx context.Context) (time.Time
t := value.Time.UTC()
return time.Date(t.Year(), t.Month(), t.Day(), 0, 0, 0, 0, time.UTC), true, nil
}