Skip to content

Commit fcd6948

Browse files
author
zsbahtiar
committed
feat(runs_list): add button delete workflow run
1 parent 0d7d2ed commit fcd6948

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

templates/repo/actions/runs_list.tmpl

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,32 @@
3535
<div class="run-list-item-right">
3636
<div class="run-list-meta">{{svg "octicon-calendar" 16}}{{DateUtils.TimeSince .Updated}}</div>
3737
<div class="run-list-meta">{{svg "octicon-stopwatch" 16}}{{.Duration}}</div>
38+
{{ if and (ne .Status 6) (ne .Status 5) }}
39+
<div class="run-list-meta">
40+
<button
41+
class="ui red tiny button delete-button name"
42+
data-modal-id="modal-delete-workflow"
43+
data-url="actions/run/{{.ID}}"
44+
data-datarepo_id="{{.RepoID}}"
45+
data-name="Delete workflow run {{.ID}}"
46+
name="Delete Workflow {{.ID}}">Delete Workflow
47+
</button>
48+
</div>
49+
{{ end }}
3850
</div>
3951
</div>
4052
</div>
4153
{{end}}
4254
</div>
55+
56+
<div class="ui g-modal-confirm delete modal" id="modal-delete-workflow">
57+
<div class="header">
58+
<i class="trash icon"></i>
59+
<span class="name"></span>
60+
</div>
61+
<div class="content">
62+
<p>Are you sure you want to permanently delete this workflow run? This action cannot be undone.</p>
63+
</div>
64+
{{template "base/modal_actions_confirm" .}}
65+
</div>
4366
{{template "base/paginate" .}}

0 commit comments

Comments
 (0)