From 33af8c3cd70dc9ed8556c88a9b0059397a622228 Mon Sep 17 00:00:00 2001 From: Travis Semple Date: Fri, 18 Oct 2024 15:16:54 -0700 Subject: [PATCH] Email fix for EFT refunds (#1787) --- .../eft_refund_notification_client.html | 2 +- .../eft_refund_notification_staff.html | 18 +++++++----------- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/pay-api/src/pay_api/templates/eft_refund_notification_client.html b/pay-api/src/pay_api/templates/eft_refund_notification_client.html index 8b00a25f5..cd73b2d72 100644 --- a/pay-api/src/pay_api/templates/eft_refund_notification_client.html +++ b/pay-api/src/pay_api/templates/eft_refund_notification_client.html @@ -1,6 +1,6 @@ # Refund Notice -A refund of {{ refundAmount }} has been issued to your original payment method. The processing time will be 3-5 business days. +A refund of ${{ '%.2f'|format(refundAmount) }} has been issued to your original payment method. The processing time will be 3-5 business days. **Business Registry** BC Registries and Online Services diff --git a/pay-api/src/pay_api/templates/eft_refund_notification_staff.html b/pay-api/src/pay_api/templates/eft_refund_notification_staff.html index 67f2fae5f..ff6332e7e 100644 --- a/pay-api/src/pay_api/templates/eft_refund_notification_staff.html +++ b/pay-api/src/pay_api/templates/eft_refund_notification_staff.html @@ -1,15 +1,11 @@ -# {{ state }} Refund Request for Short Name {{ shortname }} +{% set status_display = { + 'PENDING_APPROVAL': 'Pending', + 'APPROVED': 'Approved', + 'DECLINED': 'Declined' } +%} +# {{ status_display.get(status) }} Refund Request for Short Name {{ shortName }} -There is a refund request of ${{ refundAmount }} for short name: {{ shortname }} -{% if state == 'APPROVED' %} - is now approved. -{% elif state == 'DECLINED' %} - is declined with the following message: {{ decline_message }} -{% elif state == 'PENDING' %} - . -{% else %} - . -{% endif %} +The refund request of ${{ '%.2f'|format(refundAmount) }} for short name: {{ shortName }} {% if status_display.get(status) == 'Approved' %}is now approved.{% elif status_display.get(status) == 'Declined' %}is declined with the following message: {{ declineReason }}.{% else %}.{% endif %} Please review the information using the following link: