{% extends "./layout/default" %} {% block breadcrumbs %} {{ Breadcrumbs.renderIfExists(Route.getCurrentRoute.getName, journal) }} {% endblock %} {% block content %}
{% if errors.all()|length > 0 %}

{{ 'errors'|_ }}

    {% for key, err in errors.all() %}
  • {{ err }}
  • {% endfor %}
{% endif %}

{{ 'transaction_data'|_ }}

{# DESCRIPTION IS ALWAYS AVAILABLE #} {{ ExpandedForm.text('journal_description', journal.description) }} {# CURRENCY IS NEW FOR SPLIT JOURNALS #} {{ ExpandedForm.select('currency_id', currencies, preFilled.currency_id) }} {# show source if withdrawal or transfer #} {% if preFilled.what == 'withdrawal' or preFilled.what == 'transfer' %} {{ ExpandedForm.select('journal_source_account_id', assetAccounts, preFilled.journal_source_account_id) }} {% endif %} {# show destination account id, if deposit (is asset): #} {% if preFilled.what == 'deposit' %} {{ ExpandedForm.select('journal_destination_account_id', assetAccounts, preFilled.journal_destination_account_id) }} {% endif %} {# show static destination if transfer #} {% if preFilled.what == 'transfer' %} {{ ExpandedForm.select('journal_destination_account_id', assetAccounts, preFilled.journal_destination_account_id) }} {% endif %} {# TOTAL AMOUNT IS STATIC TEXT #} {{ ExpandedForm.staticText('journal_amount', preFilled.journal_amount|formatAmount ) }} {# DATE #} {{ ExpandedForm.date('date', journal.date) }}

{{ 'optional_field_meta_data'|_ }}

{# NO BUDGET #} {# NO CATEGORY #} {# ALWAYS TAGS #} {{ ExpandedForm.text('tags', preFilled.tags) }} {# NO PIGGY BANK #}
{# EXPLANATION IF NECESSARY: #} {% if not optionalFields.interest_date or not optionalFields.book_date or 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 %}

{{ trans('firefly.hidden_fields_preferences', {link: route('preferences.index')})|raw }}

{% endif %} {# BOX FOR DATES #} {% if optionalFields.interest_date or optionalFields.book_date or optionalFields.process_date or optionalFields.due_date or optionalFields.payment_date or optionalFields.invoice_date %}

{{ 'optional_field_meta_dates'|_ }}

{# INTEREST DATE #} {% if optionalFields.interest_date or journal.interest_date %} {{ ExpandedForm.date('interest_date', journal.interest_date) }} {% endif %} {# BOOK DATE #} {% if optionalFields.book_date or journal.book_date %} {{ ExpandedForm.date('book_date', journal.book_date) }} {% endif %} {# PROCESSING DATE #} {% if optionalFields.process_date or journal.process_date %} {{ ExpandedForm.date('process_date', journal.process_date) }} {% endif %} {# DUE DATE #} {% if optionalFields.due_date or journal.due_date %} {{ ExpandedForm.date('due_date', journal.due_date) }} {% endif %} {# PAYMENT DATE #} {% if optionalFields.payment_date or journal.payment_date %} {{ ExpandedForm.date('payment_date', journal.payment_date) }} {% endif %} {# INVOICE DATE #} {% if optionalFields.invoice_date or journal.invoice_date %} {{ ExpandedForm.date('invoice_date', journal.invoice_date) }} {% endif %}
{% endif %} {# BOX FOR BUSINESS FIELDS #} {% if optionalFields.internal_reference or optionalFields.notes %}

{{ 'optional_field_meta_business'|_ }}

{# INTERNAL REFERENCE #} {% if optionalFields.internal_reference or journal.internal_reference %} {{ ExpandedForm.text('internal_reference', journal.internal_reference) }} {% endif %} {# NOTES #} {% if optionalFields.notes or journal.notes %} {{ ExpandedForm.textarea('notes', journal.notes) }} {% endif %}
{% endif %} {# BOX FOR ATTACHMENTS #} {% if optionalFields.attachments %}

{{ 'optional_field_attachments'|_ }}

{# ATTACHMENTS #} {% if optionalFields.attachments %} {{ ExpandedForm.file('attachments[]', {'multiple': 'multiple','helpText': trans('firefly.upload_max_file_size', {'size': uploadSize|filesize}) }) }} {% endif %}
{% endif %}

{{ 'splits'|_ }}

{# withdrawal and deposit have a destination. #} {% if preFilled.what == 'withdrawal' %} {% endif %} {# DEPOSIT HAS A SOURCE #} {% if preFilled.what == 'deposit' %} {% endif %} {# only withdrawal has budget #} {% if preFilled.what == 'withdrawal' %} {% endif %} {% for index, transaction in preFilled.transactions %} {% if preFilled.what == 'withdrawal' %} {% endif %} {% if preFilled.what == 'deposit' %} {% endif %} {% if preFilled.what == 'withdrawal' %} {% endif %} {% endfor %}
  {{ trans('list.split_number') }} {{ trans('list.description') }}{{ trans('list.destination') }}{{ trans('list.source') }}{{ trans('list.amount') }}{{ trans('list.budget') }}{{ trans('list.category') }}
#{{ loop.index }}


{{ 'add_another_split'|_ }}

{{ 'options'|_ }}

{{ ExpandedForm.optionsList('update','split-transaction') }}
{% endblock %} {% block styles %} {% endblock %} {% block scripts %} {% endblock %}