{# /***************************************************************************** File name: panel-stripe-payment.html.twig Project: Villas3 Copyright 2022-2024 Michael J. Miller, All rights reserved Purpose: dialog with details of stripe payment or member info if there's no payment intent Requires: Revision History: Date Version Details -------- ------ ------------------------------------------------- 2/11/25 3.0a4 created ******************************************************************************/ #}
{# #} {% if intent is defined %}

Payment Details

{{reservation.title_short|default('unknown')}}
{{reservation.source|default('unknown')}}: {{reservation.starts|default('')}} - {{reservation.ends|default('')}}{{reservation.reservation_id}}
{{reservation.name_full|default('unknown')}} {{reservation.country_code|default('')|country_name}}
Reservation: {{reservation_status|default('not available')}}
Payment Intent: {{intent.payment_intent_id}}
Payment ID: {{intent.payment_id}} [{{intent.type ?: 'unknown type'}}{{intent.last4?' ending in '~intent.last4 : ''}}{{intent.state ? ' - '~intent.state}}]
Date Paid
Amount
Transacton Fee
Status
{{intent.date_paid|date("Y-m-d")}} {{intent.currency|upper|currency_name}}
{% if intent.status == 'failed' %}
{{(intent.amount / 100)|number_format(2)}}
{{ intent.status}} - {{ payment.error_detail|default(intent.status) }}
{% else %}
{{intent.amount_received ? ((intent.amount_received / 100)|number_format(2)) : 'missing'}}
{{ intent.transaction_fee ? ((intent.transaction_fee / 100)|number_format(2)) : 'missing'}}
{{payment is defined ? payment.pay_status|default :intent.status}}
{% endif %}
{% if (intent.refund_amount) > 0 %}
Refund
Date
Amount
Status
{{intent.refund_date|date("Y-m-d")}}
{{(intent.refund_amount / 100)|number_format(2)}}
{{intent.refund_status}}
{% endif %}
{% elseif member is defined %}

Customer Details

{{customer.name_full|title}} {{customer.country_code|country_name}}
Payment Method {% if method.card is defined %} {{method.card.brand|title}} {{method.card.funding|title}} ending in {{method.card.last4}} {% endif %} {% if method.link is defined %} link using {{method.link.email}} {% endif %}
{% if method.card is defined %}
Expires {{method.card.exp_month}}/{{method.card.exp_year}}
{% endif %}
{% elseif payout is defined %}

Payout Details

Type{{payout.type}}
Source{{payout.source_type}}
Status{{payout.status}}
Currency{{payout.currency|upper|currency_name}}
Amount{{(payout.amount / 100)|number_format(2)}}
{% else %}

No info available

{% endif %}