1
0
mirror of https://github.com/go-gitea/gitea.git synced 2024-12-04 14:46:57 -05:00

don't show project cog in issue sidebar if no permission (#14953)

This commit is contained in:
Norwin 2021-03-12 15:14:02 +00:00 committed by GitHub
parent 91ee3be588
commit 855a4f476e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -195,7 +195,9 @@
<div class="ui {{if or (not .HasIssuesOrPullsWritePermission) .Repository.IsArchived}}disabled{{end}} floating jump select-project dropdown"> <div class="ui {{if or (not .HasIssuesOrPullsWritePermission) .Repository.IsArchived}}disabled{{end}} floating jump select-project dropdown">
<span class="text"> <span class="text">
<strong>{{.i18n.Tr "repo.issues.new.projects"}}</strong> <strong>{{.i18n.Tr "repo.issues.new.projects"}}</strong>
{{if and .HasIssuesOrPullsWritePermission (not .Repository.IsArchived)}}
{{svg "octicon-gear"}} {{svg "octicon-gear"}}
{{end}}
</span> </span>
<div class="menu" data-action="update" data-issue-id="{{$.Issue.ID}}" data-update-url="{{$.RepoLink}}/issues/projects"> <div class="menu" data-action="update" data-issue-id="{{$.Issue.ID}}" data-update-url="{{$.RepoLink}}/issues/projects">
<div class="no-select item">{{.i18n.Tr "repo.issues.new.clear_projects"}}</div> <div class="no-select item">{{.i18n.Tr "repo.issues.new.clear_projects"}}</div>