2022-08-31 21:28:54 +05:30
|
|
|
{{if .comment.Time}} {{/* compatibility with time comments made before v1.14 */}}
|
|
|
|
{{if (not .comment.Time.Deleted)}}
|
2023-03-02 23:14:06 +05:30
|
|
|
{{if (or .ctxData.IsAdmin (and .ctxData.IsSigned (eq .ctxData.SignedUserID .comment.PosterID)))}}
|
2021-02-19 16:22:11 +05:30
|
|
|
<span class="ui float right">
|
|
|
|
<div class="ui mini modal issue-delete-time-modal" data-id="{{.comment.Time.ID}}">
|
2023-03-02 23:14:06 +05:30
|
|
|
<form method="POST" class="delete-time-form" action="{{.ctxData.RepoLink}}/issues/{{.ctxData.Issue.Index}}/times/{{.comment.TimeID}}/delete">
|
|
|
|
{{.ctxData.CsrfTokenHtml}}
|
2021-02-19 16:22:11 +05:30
|
|
|
</form>
|
2023-03-02 23:14:06 +05:30
|
|
|
<div class="header">{{.ctxData.locale.Tr "repo.issues.del_time"}}</div>
|
2021-02-19 16:22:11 +05:30
|
|
|
<div class="actions">
|
2023-03-02 23:14:06 +05:30
|
|
|
<div class="ui red approve button">{{.ctxData.locale.Tr "repo.issues.context.delete"}}</div>
|
|
|
|
<div class="ui cancel button">{{.ctxData.locale.Tr "repo.issues.add_time_cancel"}}</div>
|
2021-02-19 16:22:11 +05:30
|
|
|
</div>
|
|
|
|
</div>
|
2023-03-02 23:14:06 +05:30
|
|
|
<button class="ui icon button compact mini issue-delete-time tooltip" data-id="{{.comment.Time.ID}}" data-content="{{.ctxData.locale.Tr "repo.issues.del_time"}}" data-position="top right">
|
2021-03-22 09:34:19 +05:30
|
|
|
{{svg "octicon-trash"}}
|
2021-02-19 16:22:11 +05:30
|
|
|
</button>
|
|
|
|
</span>
|
|
|
|
{{end}}
|
|
|
|
{{end}}
|
|
|
|
{{end}}
|