feat: add monitoring marked articles and retention updates
Frontend CI / Frontend (push) Successful in 7m47s
Backend CI / Backend (push) Successful in 19m26s

This commit is contained in:
2026-06-17 12:48:41 +08:00
parent 9ed857e159
commit 31c4dd9358
40 changed files with 2373 additions and 488 deletions
@@ -72,6 +72,24 @@ func (s *DesktopTaskService) syncMonitoringArticleAlias(ctx context.Context, inp
nullableString(lastPathSegment),
confidence,
)
if err != nil {
return err
}
if confidence == "high" {
_, err = s.monitoringPool.Exec(ctx, `
UPDATE monitoring_citation_facts
SET content_source_type = 'published_article',
content_source_id = $3,
article_id = COALESCE(article_id, $3),
publish_record_id = COALESCE(publish_record_id, $4)
WHERE tenant_id = $1
AND normalized_url = $2
AND (
content_source_type IS DISTINCT FROM 'published_article'
OR content_source_id IS DISTINCT FROM $3
)
`, input.TenantID, normalizedURL, input.ArticleID, input.PublishRecordID)
}
return err
}