2
0

Fix HelpURL config and org menu visibility
Some checks are pending
Build and Release / Lint (push) Waiting to run
Build and Release / Unit Tests (push) Waiting to run
Build and Release / Integration Tests (PostgreSQL) (push) Waiting to run
Build and Release / Create Release (push) Waiting to run
Build and Release / Build Binaries (amd64, darwin) (push) Blocked by required conditions
Build and Release / Build Binaries (amd64, linux) (push) Blocked by required conditions
Build and Release / Build Binaries (amd64, windows) (push) Blocked by required conditions
Build and Release / Build Binaries (arm64, darwin) (push) Blocked by required conditions
Build and Release / Build Binaries (arm64, linux) (push) Blocked by required conditions

- Add HelpURL to config handler so it can be saved from admin UI
- Hide Projects tab for non-members when no projects exist
- Hide Packages tab for non-members

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
GitCaddy
2026-01-13 08:55:19 +00:00
parent 7e7a413b78
commit 82a5264562
2 changed files with 3 additions and 2 deletions

View File

@@ -241,6 +241,7 @@ func ChangeConfig(ctx *context.Context) {
cfg.Theme.DisableRegistration.DynKey(): marshalBool,
cfg.Theme.CustomHomeHTML.DynKey(): marshalString(""),
cfg.Theme.APIHeaderURL.DynKey(): marshalString(""),
cfg.Theme.HelpURL.DynKey(): marshalString(""),
cfg.Theme.CustomHomeTitle.DynKey(): marshalString(""),
cfg.Theme.CustomHomeTagline.DynKey(): marshalString(""),
cfg.Theme.PinnedOrgDisplayFormat.DynKey(): marshalString("condensed"),

View File

@@ -10,7 +10,7 @@
<div class="ui small label">{{.RepoCount}}</div>
{{end}}
</a>
{{if .CanReadProjects}}
{{if and .CanReadProjects (or .IsOrganizationMember .ProjectCount)}}
<a class="{{if .PageIsViewProjects}}active {{end}}item" href="{{$.Org.HomeLink}}/-/projects">
{{svg "octicon-project-symlink"}} {{ctx.Locale.Tr "user.projects"}}
{{if .ProjectCount}}
@@ -18,7 +18,7 @@
{{end}}
</a>
{{end}}
{{if and .IsPackageEnabled .CanReadPackages}}
{{if and .IsPackageEnabled .CanReadPackages .IsOrganizationMember}}
<a class="{{if .IsPackagesPage}}active {{end}}item" href="{{$.Org.HomeLink}}/-/packages">
{{svg "octicon-package"}} {{ctx.Locale.Tr "packages.title"}}
</a>