From 9bd9129d7d6cda99a634558247e3a05230060299 Mon Sep 17 00:00:00 2001 From: Glenn Date: Sun, 6 Oct 2024 19:56:25 -0500 Subject: [PATCH] Fixed DonateMoney to use correct campaign name and only show couponCode if one is added. --- .env | 5 +++-- src/components/DonateMoney.vue | 18 +++++++++++------- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/.env b/.env index dc60b0adc..5f8babd34 100644 --- a/.env +++ b/.env @@ -26,7 +26,7 @@ TWILIO_AUTH_TOKEN=TWILIO_SECRET_KEY # To run in single-campaign mode, set the following environment vars VUE_APP_CAMPAIGN_MODE=single -VUE_APP_FEATURED_CAMPAIGN=2 +VUE_APP_FEATURED_CAMPAIGN=1 VUE_APP_LETTER_TEMPLATE=tmpl_951e09eb07bfd24 POSTGRES_USER=postgres @@ -35,4 +35,5 @@ POSTGRES_PORT=5432 POSTGRES_HOST=amplify_db # Enable $0 transactions (set to 'on' to enable, used in both FE and BE) -VUE_APP_EMPTY_TRANSACTIONS= \ No newline at end of file +VUE_APP_EMPTY_TRANSACTIONS=on +VUE_APP_NO_COST_MAIL=true \ No newline at end of file diff --git a/src/components/DonateMoney.vue b/src/components/DonateMoney.vue index 71f5dd9b0..15990119a 100644 --- a/src/components/DonateMoney.vue +++ b/src/components/DonateMoney.vue @@ -4,9 +4,12 @@

- Your voice is super important - please use this code - {{ couponCode }} to send email and letter for free! - Donations are optional and 100% goes to Save California Salmon 🙂 + Your voice is super important! + + Please use this code {{ couponCode }} to send email + and letter for free! + + Donations are optional and 100% goes to {{ campaign.name }} 🙂

@@ -79,9 +82,7 @@

- - Send Mail - + Send Mail
@@ -103,7 +104,10 @@ export default { computed: { // These are temporary structures until we can reorganize the frontend. noCostMailEnabled() { - return process.env.VUE_APP_NO_COST_MAIL + return Boolean(process.env.VUE_APP_NO_COST_MAIL) + }, + campaign() { + return this.$store.state.campaign }, couponCode() { return process.env.VUE_APP_COUPON_CODE