Added invoice date

Signed-off-by: James Cole <thegrumpydictator@gmail.com>
This commit is contained in:
James Cole
2016-09-10 18:36:52 +02:00
parent 29a930dae5
commit 629baf9de5
12 changed files with 44 additions and 2 deletions

View File

@@ -285,6 +285,7 @@ return [
'pref_optional_tj_process_date' => 'Processing date',
'pref_optional_tj_due_date' => 'Due date',
'pref_optional_tj_payment_date' => 'Payment date',
'pref_optional_tj_invoice_date' => 'Invoice date',
'pref_optional_tj_internal_reference' => 'Internal reference',
'pref_optional_tj_notes' => 'Notes',
'pref_optional_tj_attachments' => 'Attachments',

View File

@@ -149,5 +149,6 @@ return [
'due_date' => 'Due date',
'payment_date' => 'Payment date',
'invoice_date' => 'Invoice date',
'internal_reference' => 'Internal reference',
];

View File

@@ -41,6 +41,8 @@ return [
'process_date' => 'Processing date',
'due_date' => 'Due date',
'payment_date' => 'Payment date',
'invoice_date' => 'Invoice date',
'interal_reference' => 'Internal reference',
'notes' => 'Notes',
'from' => 'From',
'piggy_bank' => 'Piggy bank',

View File

@@ -63,6 +63,7 @@
{{ ExpandedForm.checkbox('tj[process_date]','1', tjOptionalFields.process_date,{ 'label' : 'pref_optional_tj_process_date'|_ }) }}
{{ ExpandedForm.checkbox('tj[due_date]','1', tjOptionalFields.due_date,{ 'label' : 'pref_optional_tj_due_date'|_ }) }}
{{ ExpandedForm.checkbox('tj[payment_date]','1', tjOptionalFields.payment_date,{ 'label' : 'pref_optional_tj_payment_date'|_ }) }}
{{ ExpandedForm.checkbox('tj[invoice_date]','1', tjOptionalFields.invoice_date,{ 'label' : 'pref_optional_tj_invoice_date'|_ }) }}
<h4>{{ 'optional_tj_business_fields'|_ }}</h4>
{{ ExpandedForm.checkbox('tj[internal_reference]','1', tjOptionalFields.internal_reference,{ 'label' : 'pref_optional_tj_internal_reference'|_ }) }}

View File

@@ -90,6 +90,7 @@
not optionalFields.process_date or
not optionalFields.due_date or
not optionalFields.payment_date or
not optionalFields.invoice_date or
not optionalFields.internal_reference or
not optionalFields.notes or
not optionalFields.attachments
@@ -97,7 +98,11 @@
<p class="text-center text-success"><i class="fa fa-info-circle" aria-hidden="true"></i> <em>{{ trans('firefly.hidden_fields_preferences', {link: route('preferences')})|raw }}</em></p>
{% endif %}
<!-- box for dates -->
{% if optionalFields.interest_date or optionalFields.book_date or optionalFields.process_date or optionalFields.due_date or optionalFields.payment_date %}
{% if
optionalFields.interest_date or optionalFields.book_date or optionalFields.process_date
or optionalFields.due_date or optionalFields.payment_date
or optionalFields.invoice_date
%}
<div class="box">
<div class="box-header with-border">
<h3 class="box-title">{{ 'optional_field_meta_dates'|_ }}</h3>
@@ -129,6 +134,11 @@
{{ ExpandedForm.date('payment_date') }}
{% endif %}
{% if optionalFields.invoice_date %}
<!-- INVOICE DATE -->
{{ ExpandedForm.date('invoice_date') }}
{% endif %}
</div>
</div>
{% endif %}

View File

@@ -103,6 +103,7 @@
not optionalFields.due_date or
not optionalFields.payment_date or
not optionalFields.internal_reference or
not optionalFields.invoice_date or
not optionalFields.notes or
not optionalFields.attachments %}
<p class="text-center text-success"><i class="fa fa-info-circle" aria-hidden="true"></i>
@@ -117,6 +118,7 @@
optionalFields.process_date or
optionalFields.due_date or
optionalFields.payment_date or
optionalFields.invoice_date or
data.interest_date or
data.book_date or
data.process_date or
@@ -154,6 +156,11 @@
{{ ExpandedForm.date('payment_date',data['payment_date']) }}
{% endif %}
{% if optionalFields.invoice_date or data['invoice_date'] %}
<!-- INVOICE DATE -->
{{ ExpandedForm.date('invoice_date',data['invoice_date']) }}
{% endif %}
</div>
</div>
{% endif %}

View File

@@ -56,6 +56,13 @@
</tr>
{% endif %}
{% if journal.getMeta('invoice_date') %}
<tr>
<td>{{ trans('list.invoice_date') }}</td>
<td>{{ journal.getMeta('invoice_date').formatLocalized(monthAndDayFormat) }}</td>
</tr>
{% endif %}
<tr>
<td>{{ trans('list.type') }}</td>
<td>{{ journal.transactiontype.type|_ }}</td>