aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo/projects
diff options
context:
space:
mode:
authoryp05327 <576951401@qq.com>2023-03-12 22:36:47 +0900
committerGitHub <noreply@github.com>2023-03-12 14:36:47 +0100
commita04eeb2a548d4fd2b63873fc2acff49c52e19723 (patch)
treee4536fc0c417db5e56e3d60f0dce384e1b299fb1 /templates/repo/projects
parente72290fd9aeb77a47311483d1d565e428ce40cd9 (diff)
downloadgitea-a04eeb2a548d4fd2b63873fc2acff49c52e19723.tar.gz
gitea-a04eeb2a548d4fd2b63873fc2acff49c52e19723.zip
Show edit/close/delete button on organization wide repositories (#23388)
A part of https://github.com/go-gitea/gitea/pull/22865
Diffstat (limited to 'templates/repo/projects')
-rw-r--r--templates/repo/projects/list.tmpl12
1 files changed, 6 insertions, 6 deletions
diff --git a/templates/repo/projects/list.tmpl b/templates/repo/projects/list.tmpl
index 929a1b4c6f..f066f84ea2 100644
--- a/templates/repo/projects/list.tmpl
+++ b/templates/repo/projects/list.tmpl
@@ -53,15 +53,15 @@
{{JsPrettyNumber .NumClosedIssues}}&nbsp;{{$.locale.Tr "repo.issues.closed_title"}}
</span>
</div>
- {{if and (or $.CanWriteIssues $.CanWritePulls) (not $.Repository.IsArchived)}}
+ {{if and $.CanWriteProjects (not $.Repository.IsArchived)}}
<div class="ui right operate">
- <a href="{{$.Link}}/{{.ID}}/edit" data-id={{.ID}} data-title={{.Title}}>{{svg "octicon-pencil"}} {{$.locale.Tr "repo.issues.label_edit"}}</a>
+ <a href="{{.Link}}/edit" data-id={{.ID}} data-title={{.Title}}>{{svg "octicon-pencil"}} {{$.locale.Tr "repo.issues.label_edit"}}</a>
{{if .IsClosed}}
- <a class="link-action" href data-url="{{$.Link}}/{{.ID}}/open">{{svg "octicon-check"}} {{$.locale.Tr "repo.projects.open"}}</a>
+ <a class="link-action" href data-url="{{.Link}}/open">{{svg "octicon-check"}} {{$.locale.Tr "repo.projects.open"}}</a>
{{else}}
- <a class="link-action" href data-url="{{$.Link}}/{{.ID}}/close">{{svg "octicon-skip"}} {{$.locale.Tr "repo.projects.close"}}</a>
+ <a class="link-action" href data-url="{{.Link}}/close">{{svg "octicon-skip"}} {{$.locale.Tr "repo.projects.close"}}</a>
{{end}}
- <a class="delete-button" href="#" data-url="{{$.RepoLink}}/projects/{{.ID}}/delete" data-id="{{.ID}}">{{svg "octicon-trash"}} {{$.locale.Tr "repo.issues.label_delete"}}</a>
+ <a class="delete-button" href="#" data-url="{{.Link}}/delete" data-id="{{.ID}}">{{svg "octicon-trash"}} {{$.locale.Tr "repo.issues.label_delete"}}</a>
</div>
{{end}}
{{if .Description}}
@@ -77,7 +77,7 @@
</div>
</div>
-{{if or .CanWriteIssues .CanWritePulls}}
+{{if .CanWriteProjects}}
<div class="ui small basic delete modal">
<div class="ui icon header">
{{svg "octicon-trash"}}