{% extends 'payment/transaction_details.html' %}
{% from 'payment/macros.html' import warning_message %}

{% block details %}
    {% if not transaction.data._migrated %}
        <dt>{% trans %}Transaction ID{% endtrans %}</dt>
        <dd>{{ transaction.data.txn_id }}</dd>
        <dt>{% trans %}Invoice ID{% endtrans %}</dt>
        <dd>{{ transaction.data.invoice }}</dd>
        <dt>{% trans %}Payer e-mail{% endtrans %}</dt>
        <dd>{{ transaction.data.payer_email }}</dd>
    {% endif %}
{% endblock %}

{% block warning_box %}
    {% call warning_message() %}
        <p>{% trans %}The paid amount does not match the required amount. Please contact the registrant to solve the issue.{% endtrans %}</p>
        <p>{% trans %}Paid: {% endtrans %}{{ format_currency(transaction.amount, transaction.currency, locale=session.lang) }}</p>
        <p>{% trans %}Required: {% endtrans %}{{ format_currency(registrant.getTotal(), transaction.currency, locale=session.lang) }}</p>
    {% endcall %}
{% endblock %}

{% extends 'payment/transaction_details.html' %}
{% from 'payment/macros.html' import warning_message %}

{% block details %}
    {% if not transaction.data._migrated %}
        <dt>{% trans %}Transaction ID{% endtrans %}</dt>
        <dd>{{ transaction.data.txn_id }}</dd>
        <dt>{% trans %}Invoice ID{% endtrans %}</dt>
        <dd>{{ transaction.data.invoice }}</dd>
        <dt>{% trans %}Payer e-mail{% endtrans %}</dt>
        <dd>{{ transaction.data.payer_email }}</dd>
    {% endif %}
{% endblock %}

{% block warning_box %}
    {% if transaction.amount != registrant.getTotal() %}
        {% call warning_message() %}
            <p>{% trans %}The paid amount does not match the required amount. Please contact the registrant to solve the issue.{% endtrans %}</p>
            <p>{% trans %}Paid: {% endtrans %}{{ format_currency(transaction.amount, transaction.currency, locale=session.lang) }}</p>
            <p>{% trans %}Required: {% endtrans %}{{ format_currency(registrant.getTotal(), transaction.currency, locale=session.lang) }}</p>
        {% endcall %}
    {% endif %}
{% endblock %}

Fix transaction info warning box
Payment/PayPal: Fix transaction info warning box

Hide the warning box indicating mismatching amounts paid/expected in the
registrant payment details with Paypal when the amounts are correct
