diff --git a/routers/web/repo/release.go b/routers/web/repo/release.go index 0950e68567eea..0b927a3a2fa03 100644 --- a/routers/web/repo/release.go +++ b/routers/web/repo/release.go @@ -203,6 +203,7 @@ func releasesOrTags(ctx *context.Context, isTagList bool) { ctx.Data["Page"] = pager if isTagList { + ctx.Data["PageIsViewCode"] = !ctx.Repo.Repository.UnitEnabled(ctx, unit.TypeReleases) ctx.HTML(http.StatusOK, tplTagsList) } else { ctx.HTML(http.StatusOK, tplReleasesList) diff --git a/templates/repo/header.tmpl b/templates/repo/header.tmpl index 33791fd512aae..b55e83a9d32d1 100644 --- a/templates/repo/header.tmpl +++ b/templates/repo/header.tmpl @@ -207,7 +207,7 @@ {{end}} {{if and (.Permission.CanRead $.UnitTypeReleases) (not .IsEmptyRepo)}} - + {{svg "octicon-tag"}} {{.locale.Tr "repo.releases"}} {{if .NumReleases}} {{CountFmt .NumReleases}} diff --git a/templates/repo/release_tag_header.tmpl b/templates/repo/release_tag_header.tmpl index 0af9ba86356a1..7129e4235f5bc 100644 --- a/templates/repo/release_tag_header.tmpl +++ b/templates/repo/release_tag_header.tmpl @@ -5,9 +5,9 @@
{{if .EnableFeed}} diff --git a/templates/repo/sub_menu.tmpl b/templates/repo/sub_menu.tmpl index bfe5a20b164df..6c09d8f4368d8 100644 --- a/templates/repo/sub_menu.tmpl +++ b/templates/repo/sub_menu.tmpl @@ -7,11 +7,11 @@ {{svg "octicon-history"}} {{.locale.PrettyNumber .CommitsCount}} {{.locale.TrN .CommitsCount "repo.commit" "repo.commits"}}
- {{svg "octicon-git-branch"}} {{.BranchesCount}} {{.locale.TrN .BranchesCount "repo.branch" "repo.branches"}} + {{svg "octicon-git-branch"}} {{.locale.PrettyNumber .BranchesCount}} {{.locale.TrN .BranchesCount "repo.branch" "repo.branches"}}
{{if $.Permission.CanRead $.UnitTypeCode}}
- {{svg "octicon-tag"}} {{.NumTags}} {{.locale.TrN .NumTags "repo.tag" "repo.tags"}} + {{svg "octicon-tag"}} {{.locale.PrettyNumber .NumTags}} {{.locale.TrN .NumTags "repo.tag" "repo.tags"}}
{{end}}