This commit is contained in:
James Cole 2018-04-22 09:40:03 +02:00
parent 01c10e320c
commit 07768a43c8
No known key found for this signature in database
GPG Key ID: C16961E655E74B5E
3 changed files with 30 additions and 3 deletions

View File

@ -52,6 +52,8 @@ $(document).ready(function () {
// convert source currency to destination currency (slightly different routine for transfers)
$('#ffInput_source_amount').on('change', convertSourceToDestination);
//
});

View File

@ -95,6 +95,7 @@ return [
'amount' => 'Amount',
'foreign_amount' => 'Foreign amount',
'existing_attachments' => 'Existing attachments',
'date' => 'Date',
'interest_date' => 'Interest date',
'book_date' => 'Book date',

View File

@ -177,15 +177,39 @@
</div>
{% endif %}
{% if optionalFields.attachments %}
{% if optionalFields.attachments or journal.attachments|length > 0 %}
<div class="box">
<div class="box-header with-border">
<h3 class="box-title">{{ 'optional_field_attachments'|_ }}</h3>
</div>
<div class="box-body">
{% if optionalFields.attachments %}
{{ ExpandedForm.file('attachments[]', {'multiple': 'multiple','helpText': trans('firefly.upload_max_file_size', {'size': uploadSize|filesize}) }) }}
{% if journal.attachments|length > 0 %}
<div id="att_holder_attachments" class="form-group">
<label class="col-sm-4 control-label">
{{ trans('form.existing_attachments') }}
</label>
<div class="col-sm-8">
{% for att in journal.attachments %}
<div class="row att_row" data-id="{{ att.id }}">
<div class="col-lg-1"><a href="{{ route('attachments.delete', att.id) }}" data-id="{{ att.id }}" class="del_att btn btn-danger btn-xs"><i class="fa fa-trash"></i></a></div>
<div class="col-lg-11">
<a href="{{ route('attachments.view', att.id) }}" title="{{ att.filename }}">
{% if att.title %}
{{ att.title }} ({{ att.filename }})
{% else %}
{{ att.filename }}
{% endif %}
</a>
({{ att.size|filesize }})
</div>
</div>
{% endfor %}
</div>
</div>
{% endif %}
{{ ExpandedForm.file('attachments[]', {'multiple': 'multiple','helpText': trans('firefly.upload_max_file_size', {'size': uploadSize|filesize}) }) }}
</div>
</div>
{% endif %}