Allow to edit an attachment.

This commit is contained in:
James Cole
2015-07-19 09:37:28 +02:00
parent b5e2e8aa1d
commit 0dbe4e94fa
9 changed files with 290 additions and 23 deletions

View File

@@ -31,9 +31,9 @@
<h3 class="box-title">{{ 'optionalFields'|_ }}</h3>
</div>
<div class="box-body">
{{ ExpandedForm.text('title') }}
{{ ExpandedForm.textarea('description') }}
{{ ExpandedForm.textarea('notes') }}
{{ ExpandedForm.text('title', attachment.title) }}
{{ ExpandedForm.textarea('description', attachment.description) }}
{{ ExpandedForm.textarea('notes', attachment.notes) }}
</div>
</div>

View File

@@ -93,8 +93,18 @@
</td>
<td>
<i class="fa fa-file-pdf-o"></i>
<a href="{{ route('attachment.download', att.id) }}">{{ att.filename }}</a>
<a href="{{ route('attachment.download', att.id) }}" title="{{ att.filename }}">
{% if att.title %}
{{ att.title }}
{% else %}
{{ att.filename }}
{% endif %}
</a>
({{ att.size|filesize }})
{% if att.description %}
<br/>
<em>{{ att.description }}</em>
{% endif %}
</td>
</tr>
{% endfor %}