2024-02-20 09:39:44 +08:00
|
|
|
{{if and .comment.Time (.ctxData.Repository.IsTimetrackerEnabled ctx)}} {{/* compatibility with time comments made before v1.14 */}}
|
2022-08-31 23:58:54 +08:00
|
|
|
{{if (not .comment.Time.Deleted)}}
|
2023-03-03 01:44:06 +08:00
|
|
|
{{if (or .ctxData.IsAdmin (and .ctxData.IsSigned (eq .ctxData.SignedUserID .comment.PosterID)))}}
|
2024-03-04 11:33:20 +08:00
|
|
|
<span class="tw-float-right">
|
2021-02-19 18:52:11 +08:00
|
|
|
<div class="ui mini modal issue-delete-time-modal" data-id="{{.comment.Time.ID}}">
|
2023-06-15 02:17:58 +08:00
|
|
|
<form method="post" class="delete-time-form" action="{{.ctxData.RepoLink}}/issues/{{.ctxData.Issue.Index}}/times/{{.comment.TimeID}}/delete">
|
2023-03-03 01:44:06 +08:00
|
|
|
{{.ctxData.CsrfTokenHtml}}
|
2021-02-19 18:52:11 +08:00
|
|
|
</form>
|
2023-09-25 16:56:50 +08:00
|
|
|
<div class="header">{{ctx.Locale.Tr "repo.issues.del_time"}}</div>
|
2023-09-25 04:31:58 +08:00
|
|
|
{{template "base/modal_actions_confirm"}}
|
2021-02-19 18:52:11 +08:00
|
|
|
</div>
|
2023-09-25 16:56:50 +08:00
|
|
|
<button class="ui icon button compact mini issue-delete-time" data-id="{{.comment.Time.ID}}" data-tooltip-content="{{ctx.Locale.Tr "repo.issues.del_time"}}">
|
2021-03-22 12:04:19 +08:00
|
|
|
{{svg "octicon-trash"}}
|
2021-02-19 18:52:11 +08:00
|
|
|
</button>
|
|
|
|
</span>
|
|
|
|
{{end}}
|
|
|
|
{{end}}
|
|
|
|
{{end}}
|