| {{payment.id }} |
{% if payment.userid is null %}
N/A
{% else %}
{{ payment.userid.firstname ~ ' ' ~ payment.userid.lastname}}
{% endif %}
|
{% if payment.userid is null %}
N/A
{% else %}
{{ payment.userid.email}}
{% endif %}
|
{{payment.orderid.productid.name ?? "N/A"}} |
{{ payment.paymentmethod ? payment.paymentmethod|upper : "N/A" }} |
{% if payment.paymentstatus is null %}
N/A
{% else %}
{% set badgeClass = '' %}
{% set statusText = payment.paymentstatus is not null ? payment.paymentstatus : 'N/A' %}
{% if statusText == 'success' %}
{% set badgeClass = 'badge bg-success' %}
{% elseif statusText == 'incompleted' or statusText == 'failed' %}
{% set badgeClass = 'badge bg-danger' %}
{% else %}
{% set badgeClass = 'badge bg-warning' %}
{% endif %}
{{ statusText|upper }}
{% endif %}
|
{% if payment.paymentDate is not null %}
"{{ payment.paymentDate|date("d-m-Y H:i:s") }} |
{% else %}
N/A |
{% endif %}
|