2025-05-03 08:51:33 +01:00
|
|
|
<div class="block">
|
|
|
|
|
<h4 class="title is-4">Attachments</h4>
|
|
|
|
|
<div class="block">
|
|
|
|
|
<check if="isset( {{@attachments }})">
|
|
|
|
|
<check if="count({{@attachments}}) > 0">
|
2025-03-23 10:30:36 +00:00
|
|
|
<table class="table is-fullwidth is-narrow is-striped is-hoverable">
|
|
|
|
|
<thead>
|
2025-02-16 22:11:20 +00:00
|
|
|
<tr>
|
2025-03-23 10:30:36 +00:00
|
|
|
<th class="th-icon"></th>
|
|
|
|
|
<th>File Name</th>
|
|
|
|
|
<th>Uploaded By</th>
|
|
|
|
|
<th>Created At</th>
|
|
|
|
|
<th>Version</th>
|
2025-02-16 22:11:20 +00:00
|
|
|
</tr>
|
2025-03-23 10:30:36 +00:00
|
|
|
</thead>
|
|
|
|
|
<tbody>
|
|
|
|
|
<repeat group="{{ @attachments }}" value="{{ @attach }}">
|
|
|
|
|
<tr>
|
|
|
|
|
<td>
|
|
|
|
|
<span class="icon"><i class="fas fa-file"></i></span>
|
|
|
|
|
</td>
|
|
|
|
|
<td><a href="/attachment/{{@attach.id}}/download">{{ @attach.file_name }}</a></td>
|
|
|
|
|
<td>{{ @attach.username }}</td>
|
|
|
|
|
<td>{{ @attach.created_at }}</td>
|
|
|
|
|
<td>{{ @attach.version_number }}</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</repeat>
|
|
|
|
|
</tbody>
|
|
|
|
|
</table>
|
2025-03-24 11:14:13 +00:00
|
|
|
<hr>
|
|
|
|
|
<div>
|
|
|
|
|
<repeat group="{{ @attachments }}" value="{{ @attach }}">
|
|
|
|
|
<img src="/attachment/{{@attach.id}}/view">
|
|
|
|
|
</repeat>
|
|
|
|
|
</div>
|
2025-03-23 10:30:36 +00:00
|
|
|
</check>
|
2025-05-03 08:51:33 +01:00
|
|
|
</check>
|
|
|
|
|
<div class="block">
|
|
|
|
|
<form action="/ticket/{{@PARAMS.id}}/attachments/upload" method="POST" enctype="multipart/form-data">
|
|
|
|
|
<div class="field has-addons">
|
|
|
|
|
<div class="control has-icons-left"><!-- is-expanded -->
|
|
|
|
|
<input class="input" type="file" name="attachment" required>
|
|
|
|
|
<span class="icon is-small is-left">
|
|
|
|
|
<i class="fas fa-file"></i>
|
|
|
|
|
</span>
|
2025-02-16 22:11:20 +00:00
|
|
|
</div>
|
2025-05-03 08:51:33 +01:00
|
|
|
<div class="control">
|
|
|
|
|
<button class="button" type="submit">Upload</button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</form>
|
2025-02-16 22:11:20 +00:00
|
|
|
</div>
|
|
|
|
|
</div>
|
2025-03-23 10:30:36 +00:00
|
|
|
</div>
|