Per-backend log labels: show Gitea Actions text on waiting/failure pages and footer

This commit is contained in:
naeeo
2026-09-29 20:54:38 +08:00
parent a3686a49d4
commit e8126bdc4a
6 changed files with 13 additions and 6 deletions
+5
View File
@@ -93,6 +93,11 @@ class GithubRun(models.Model):
return get_backend(self.backend or 'github').log_url(self.github_run_id)
return ""
@property
def backend_label(self):
"""任务所属构建平台的展示名(用于日志链接等文案)。"""
return "Gitea Actions" if (self.backend or "github") == "gitea" else "GitHub Actions"
def short_uuid(self):
return self.uuid[:8] if len(self.uuid) >= 8 else self.uuid