Overview

Variable name

How to type the variable

What the variable does

Bookings

{{bookings}}

Inputs an array of bookings. Useful when you want to display all the bookings within a recurring series or if you want to bundle booking data together.


What is the booking variable?

The booking variable allows you to group multiple bookings into one communication so that you can provide a summary. This is particularly useful if you use recurring bookings, as you can display all the bookings which have been booked in a series within one communication. This can also be helpful if you would like to bundle booking data together into one communication, for example all the bookings a resource has on one day.

As the booking variable lists out multiple bookings which have unique details, an array is used. An array holds lists of variables and to output all the items we can loop them using an iteration tag. Here is an example of what you could code:

{% for booking in bookings %}
{{booking.booking_start_time | date: "dd LLLL y | t"}} ({{booking.booking_timezone_abbreviation}}) | {{booking.customer_booking_total_price | currency}} | {{booking.booking_location}}

{% if booking.video_conference_link %}
| {{booking.video_conference_link | link:"Zoom link"}}</p>
{% endif %} <br>

{% endfor %}

The variables within the array can be changed to include what ever information you would like to display. The important part is that open and close the loop with:

{% for booking in bookings %}

[Insert variables into array]

{% endfor %}


How will this display within our communications?

Here is an example of an english recurring booking email template, which includes the booking variable:

or

<p>Hi {{customer_firstname}},<br>
Thank you for booking:</p>

{% for booking in bookings %}
{{booking.booking_start_time | date: "dd LLLL y | t"}} ({{booking.booking_timezone_abbreviation}}) | {{booking.customer_booking_total_price | currency}} | {{booking.booking_location}}
{% if booking.video_conference_link %}
| {{booking.video_conference_link | link:"Zoom link"}}</p>
{% endif %}
<br>
{% endfor %}

<p>{{resource_name}} will be looking after you for the duration of your visits and will be at reception to welcome you when you arrive. Your bookings will take place at the {{booking_location}}. If you have any questions prior to your bookings, please don't hesitate to get in touch by replying to this email. </p>

<p>Thanks,<br>
Lothian Activity Centre</p>

<p>Please note all times within this email are in {{booking_timezone_abbreviation}}</p>

When a customer books a recurring booking, they will then automatically receive a booking confirmation email which will be constructed using the template we have saved above. This will then display as so:


We would love to hear any feedback 👂

Did this answer your question?