Skip to content

Commit 7d81678

Browse files
author
Richard Jones
committed
add "remove" button to file attachments
1 parent 02b5da8 commit 7d81678

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

templates/classic/html/issue.item.html

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,9 @@
100100
</p>
101101

102102
<table class="files" tal:condition="context/files">
103-
<tr><th colspan="4" class="header">Files</th></tr>
104-
<tr><th>File name</th><th>Uploaded</th><th>Type</th><th>Edit</th></tr>
103+
<tr><th colspan="5" class="header">Files</th></tr>
104+
<tr><th>File name</th><th>Uploaded</th><th>Type</th><th>Edit</th>
105+
<th>Remove</th></tr>
105106
<tr tal:repeat="file context/files">
106107
<td>
107108
<a tal:attributes="href file/download_url"
@@ -115,6 +116,14 @@
115116
<td><a tal:condition="file/is_edit_ok"
116117
tal:attributes="href string:file${file/id}">edit</a>
117118
</td>
119+
<td>
120+
<form style="padding:0" tal:condition="context/is_edit_ok"
121+
tal:attributes="action string:issue${context/id}">
122+
<input type="hidden" name="@remove@files" tal:attributes="value file/id">
123+
<input type="hidden" name="@action" value="edit">
124+
<input type="submit" value="remove">
125+
</form>
126+
</td>
118127
</tr>
119128
</table>
120129

0 commit comments

Comments
 (0)