How to add Promotion Time base on the Dynamic Coupon

  • 2 July 2021
  • 1 reply

Badge +4

If I have created an abandoned email using flow and included Dynamic Promotion Code inside the email.

The promotion will only be activated when the email send out, and ends in 3 hours after the email is out.  

How can I show the start and end date of the Promotion in the email Content


Best answer by David To 2 July 2021, 22:07

View original

1 reply

Userlevel 7
Badge +60

Hello @pmjchan,

Great question! 

Although it is possible to display the current date and time the email was sent out and even display a time X-days later; it is currently not possible to calculate X-hours later. 

To display the current date and time, you can use the following syntax: {% today "%m/%d/%Y %I:%M" as today %} {{ today }} which would display as 07/02/2021 04:05. You can also re-order and redisplay how the dates and time is rendered by referencing the Django filters and tags available here:

Furthermore, if you did decide to opt-in to using X-days later instead, @retention has a great answer in the following Community post. I would also suggest taking a look at the How to Format Date Variables in Templates article to learn more about formatting dates within a template. 

I hope this helps!