Template Variables: Difference between revisions

Jump to navigation Jump to search
Lesley (talk | contribs)
 
(128 intermediate revisions by 6 users not shown)
Line 4: Line 4:
  On this page you find a list of template variables and information on how they are used.  
  On this page you find a list of template variables and information on how they are used.  


These variables (short codes) will be replaced by the relevant information from each booking. They can be used in every text settings that allows their use . Copy them exactly as shown, including the square brackets and upper case.
These variables (short codes) will be replaced by the relevant information from each booking. They can be used in every text settings that allows their use. Copy them exactly as shown, including the square brackets and upper case.


The date variables can have an optional offset value of a number of days added after a colon, for example '''[FIRSTNIGHT:-3 days]'''
The date variables can have an optional offset value of a number of days added after a colon, for example '''[FIRSTNIGHT:-3 days]'''
Line 69: Line 69:


[PROPERTYHOUSERULES] - property house rules ({{#fas:cog}}  (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT)
[PROPERTYHOUSERULES] - property house rules ({{#fas:cog}}  (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT)
[PROPERTYHOUSERULESBR] - property house rules ({{#fas:cog}}  (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT) with line break


[PROPERTYTEMPLATE1] - Property Template 1
[PROPERTYTEMPLATE1] - Property Template 1
Line 85: Line 88:


[PROPERTYTEMPLATE8] - Property Template 8
[PROPERTYTEMPLATE8] - Property Template 8
[PROPERTYTEMPLATE1BR] - Property Template 1 with line breaks
[PROPERTYTEMPLATE2BR] - Property Template 2 with line breaks
[PROPERTYTEMPLATE3BR] - Property Template 3 with line breaks
[PROPERTYTEMPLATE4BR] - Property Template 4 with line breaks
[PROPERTYTEMPLATE5BR] - Property Template 5 with line breaks
[PROPERTYTEMPLATE6BR] - Property Template 6 with line breaks
[PROPERTYTEMPLATE7BR] - Property Template 7 with line breaks
[PROPERTYTEMPLATE8BR] - Property Template 8 with line breaks


[BOOKINGCOMHOTELID] - booking.com hotel id
[BOOKINGCOMHOTELID] - booking.com hotel id
Line 129: Line 148:
[ROOMID] - room id number
[ROOMID] - room id number


[ROOMNAME] - room names of all booked rooms (not for cancelled bookings use ROOMNAMEINC if used for cacelled bookings)
[ROOMNAME] - room names of all booked rooms (not for cancelled bookings use ROOMNAMEINC if used for cancelled bookings)


[ROOMNAMEBR] - room names with line break
[ROOMNAMEBR] - room names with line break
Line 151: Line 170:
[ROOMNAMEOFFERBR] - room names of all booked rooms with offer name with line break
[ROOMNAMEOFFERBR] - room names of all booked rooms with offer name with line break


[ROOMNAMEOFFERINC]  room names of all booked rooms with offer name inkl. cancelled bookings
[ROOMNAMEOFFERINC]  room names of all booked rooms with offer name incl. cancelled bookings


[ROOMNAMEOFFERINCBR] - room names of all booked rooms with offer name with line break
[ROOMNAMEOFFERINCBR] - room names of all booked rooms with offer name with line break
Line 179: Line 198:
[ROOMTEMPLATE8] - ROOM  Template 8
[ROOMTEMPLATE8] - ROOM  Template 8


[ROOMMETAAUXTEXT] - room meta text setting for first booked room
[ROOMTEMPLATE1BR] - ROOM Template 1 with linkbreak


[ROOMMETAAUXTEXTS] - room meta text setting for all booked rooms
[ROOMTEMPLATE2BR] - ROOM  Template 2  with linkbreak


[ROOMMETAAUXTEXTSINC] - room auxiliary text setting for all booked rooms
[ROOMTEMPLATE3BR] - ROOM  Template 3  with linkbreak
 
[ROOMTEMPLATE4BR] - ROOM  Template 4  with linkbreak
 
[ROOMTEMPLATE5BR] - ROOM  Template 5  with linkbreak
 
[ROOMTEMPLATE6BR] - ROOM  Template 6  with linkbreak
 
[ROOMTEMPLATE7BR] - ROOM  Template 7  with linkbreak
 
[ROOMTEMPLATE8BR] - ROOM  Template 8  with linkbreak
 
[ROOMMETAAUXTEXT] - room auxiliary text setting for first booked room {{#fas:cog}} (SETTINGS) PROPERTIES > ROOMS > SETUP > DISPLAY
 
[ROOMMETAAUXTEXTS] - room auxiliary text setting for all booked rooms
 
[ROOMMETAAUXTEXTSINC] - room auxiliary text setting for all booked rooms, incl. cancelled bookings


[INTERNALROOMNAME] - internal room name as used in the control panel, this is not the translated room name shown on the booking page
[INTERNALROOMNAME] - internal room name as used in the control panel, this is not the translated room name shown on the booking page


[OFFERID]  - ID of the boked offer
[OFFERID]  - ID of the booked offer


[OFFERNAME] - booked offer name for all booked rooms
[OFFERNAME] - booked offer name for all booked rooms
Line 193: Line 228:
[OFFERNAME1] - offer name for this booked room only
[OFFERNAME1] - offer name for this booked room only


[OFFERNAMEINC]  - offer name for this booked room only inluding cancelled bookings  
[OFFERNAMEINC]  - offer name for this booked room only including cancelled bookings  


[OFFERDESCRIPTION1] - offer description 1 for all booked rooms
[OFFERDESCRIPTION1] - offer description 1 for all booked rooms


[OFFERDESCRIPTION1INC] - offer description 1 for all booked rooms inkl. cancelled
[OFFERDESCRIPTION1INC] - offer description 1 for all booked rooms incl. cancelled


[OFFERDESCRIPTION2] - offer description 2 for all booked rooms
[OFFERDESCRIPTION2] - offer description 2 for all booked rooms


[OFFERDESCRIPTION2INC] - offer description 2 for all booked rooms inkl. cancelled
[OFFERDESCRIPTION2INC] - offer description 2 for all booked rooms incl. cancelled


[OFFERDESCRIPTION1-1] - offer description 1 for this booked room  
[OFFERDESCRIPTION1-1] - offer description 1 for this booked room  
Line 210: Line 245:


[OFFERSUMMARYINC] - summary offers including cancelled bookings
[OFFERSUMMARYINC] - summary offers including cancelled bookings
[UNITID1] - ID of the unit (number) for this booking number (coming soon)


[UNITNAME] - unit names of all the assigned room types in the booking group (cancelled bookings are not shown)
[UNITNAME] - unit names of all the assigned room types in the booking group (cancelled bookings are not shown)
Line 215: Line 252:
[UNITNAMEINC] - unit names of all the assigned room types in the booking group including cancelled bookings
[UNITNAMEINC] - unit names of all the assigned room types in the booking group including cancelled bookings


[UNITNAME:1] - additional information about the unit for all the assigned room types in the booking group (cancelled bookings are not shown)
[UNITNAME:1] - additional information (first) about the unit for all the assigned room types in the booking group (cancelled bookings are not shown)
 
[UNITNAME:2] - additional information (second) about the unit for all the assigned room types in the booking group (cancelled bookings are not shown)


[UNITNAME1] - unit name of the assigned room for this booking number
[UNITNAME1] - unit name of the assigned room for this booking number
Line 221: Line 260:
[UNITNAME1:1] - additional information about the assigned room for this booking number / add the additional information on each line after a | symbol where you set the unit names
[UNITNAME1:1] - additional information about the assigned room for this booking number / add the additional information on each line after a | symbol where you set the unit names


[UNITSTATUS1] - the status if the unit  
[UNITSTATUS1] - the status of the unit  


[ROOMDESCRIPTION] - Room description  from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
[ROOMDESCRIPTION] - Room description  from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
Line 228: Line 267:


[LEAVINGDAYAVAIL] - returns yes or no, can be used to trigger an Auto Action
[LEAVINGDAYAVAIL] - returns yes or no, can be used to trigger an Auto Action
[NUMROOMSAVAIL] - returns the number of available rooms (-1 if overbooked), can be used to trigger an Auto Action


[ROOMRACKRATENUM] - Rack Rate from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
[ROOMRACKRATENUM] - Rack Rate from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
Line 233: Line 274:
[ROOMCLEANINGFEENUM]  - Cleaning fee from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
[ROOMCLEANINGFEENUM]  - Cleaning fee from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT


[ROOMSECURITYDEPOSITNUM]  - Securty deposit from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
[ROOMSECURITYDEPOSITNUM]  - Security deposit from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT


[ROOMTAXPERCENTNUM]  - Tax percentate from from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
[ROOMTAXPERCENTNUM]  - Tax percentate from from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
Line 285: Line 326:


[RANDOM8] - a 8 digit random number seeded from the booking number
[RANDOM8] - a 8 digit random number seeded from the booking number
[VOUCHERPHRASE1] - Voucher Phrase - change the number to the voucher  you want to print out.
[VOUCHERAMOUNT1]  - Voucher Amount - change the number to the voucher you want to print out.


=== Content from "Info" tab ===
=== Content from "Info" tab ===
Line 301: Line 346:
[BOOKINGINFOCODETEXT:infoCode] - the most recent Text value of the specified Booking Info Code, "infoCode" in this example
[BOOKINGINFOCODETEXT:infoCode] - the most recent Text value of the specified Booking Info Code, "infoCode" in this example


[BOOKINGINFOCODEDATE:infoCode]- the most recent date value of the specified Booking Info Code, "infoCode" in this example  
[BOOKINGINFOCODEDATE:infoCode]- the most recent date value of the specified Booking Info Code, "infoCode" in this example, supports custom date/time formats {%A, %e %B, %Y} after the infoCode


[INTERNALNOTES]  - content from "Internal Notes" on the Info Tab
[INTERNALNOTES]  - content from "Internal Notes" on the Info Tab
Line 396: Line 441:
[GUESTMOBILENUM] - guests mobile number with all non-numeric characters removed
[GUESTMOBILENUM] - guests mobile number with all non-numeric characters removed


[PHONELAST1] - last digit of the guests phone number if guest phone is empty it will use the guests mobile number
[MOBILELAST1] last digit of the guests mobile number, if mobile is empty the guests phone number will be used.


[PHONELAST2] - last 2 digits of the guests phone number if guest phone is empty it will use the guests mobile number
[MOBILELAST2] last 2 digits of the guests mobile number, if mobile is empty the guests phone number will be used.


[PHONELAST3] - last 3 digits of the guests phone number if guest phone is empty it will use the guests mobile number
[MOBILELAST3] last 3 digits of the guests mobile number, if mobile is empty the guests phone number will be used.


[PHONELAST4]  - last 4 digits of the guests phone number if guest phone is empty it will use the guests mobile number
[MOBILELAST4] last 4 digits of the guests mobile number, if mobile is empty the guests phone number will be used.
 
[MOBILELAST5] last 5 digits of the guests mobile number, if mobile is empty the guests phone number will be used.
 
[MOBILELAST6] last 6 digits of the guests mobile number, if mobile is empty the guests phone number will be used.
 
[PHONELAST1]  - last digit of the guests phone number if guest phone is empty it will use the guests mobile number
 
[PHONELAST2]  - last 2 digits of the guests phone number if guest phone is empty it will use the guests mobile number
 
[PHONELAST3]  - last 3 digits of the guests phone number if guest phone is empty it will use the guests mobile number
 
[PHONELAST4]  - last 4 digits of the guests phone number if guest phone is empty it will use the guests mobile number


[PHONELAST5]  - last 5 digits of the guests phone number if guest phone is empty it will use the guests mobile number
[PHONELAST5]  - last 5 digits of the guests phone number if guest phone is empty it will use the guests mobile number


[PHONELAST6]  - last 6 digits of the guests phone number if guest phone is empty it will use the guests mobile number
[PHONELAST6]  - last 6 digits of the guests phone number if guest phone is empty it will use the guests mobile number
[GUESTSMS:49] - attempt to convert the guest mobile number into a format suitable for SMS, if country code is missing add the one supplied in the template variable, if mobile number is empty use guest phone number instead.


[GUESTCOMPANY] - company name
[GUESTCOMPANY] - company name
Line 450: Line 509:


[GUESTCUSTOMQ1] - answer to custom question 1  
[GUESTCUSTOMQ1] - answer to custom question 1  
[GUESTCUSTOMQ1BR] - answer to custom question 1 with line breaks <BR>


[GUESTCUSTOMQ2] - answer to custom question 2  
[GUESTCUSTOMQ2] - answer to custom question 2  
[GUESTCUSTOMQsBR] - answer to custom question 2 with line breaks <BR>


[GUESTCUSTOMQ3] - answer to custom question 3  
[GUESTCUSTOMQ3] - answer to custom question 3  
[GUESTCUSTOMQ3BR] - answer to custom question 3 with line breaks <BR>


[GUESTCUSTOMQ4] - answer to custom question 4
[GUESTCUSTOMQ4] - answer to custom question 4
[GUESTCUSTOMQ4BR] - answer to custom question 4 with line breaks <BR>


[GUESTCUSTOMQ5] - answer to custom question 5  
[GUESTCUSTOMQ5] - answer to custom question 5  
[GUESTCUSTOMQ5BR] - answer to custom question 5 with line breaks <BR>


[GUESTCUSTOMQ6] - answer to custom question 6
[GUESTCUSTOMQ6] - answer to custom question 6
[GUESTCUSTOMQ6BR] - answer to custom question 6 with line breaks <BR>


[GUESTCUSTOMQ7] - answer to custom question 7
[GUESTCUSTOMQ7] - answer to custom question 7
[GUESTCUSTOMQ7BR] - answer to custom question 7 with line breaks <BR>


[GUESTCUSTOMQ8] - answer to custom question 8
[GUESTCUSTOMQ8] - answer to custom question 8
[GUESTCUSTOMQ8BR] - answer to custom question 8 with line breaks <BR>


[GUESTCUSTOMQ9] - answer to custom question 9
[GUESTCUSTOMQ9] - answer to custom question 9
[GUESTCUSTOMQ9BR] - answer to custom question 9 with line breaks <BR>


[GUESTCUSTOMQ10] - answer to custom question 10  
[GUESTCUSTOMQ10] - answer to custom question 10  
[GUESTCUSTOMQ10BR] - answer to custom question 10 with line breaks <BR>


[REFERENCE] - content of the booking reference field
[REFERENCE] - content of the booking reference field
Line 491: Line 570:
[APISOURCETEXT] - human readable name of the channel
[APISOURCETEXT] - human readable name of the channel


[BOOKINGDATE] - booking date
[BOOKINGIP] - ip address of booker's computer
 
[APIMESSAGE] - api message sent by originating channel from the Channel Info setting
 
[BOOKINGDATE] - booking date in guests language


[BOOKINGTIMEDATE] - booking date and time
[BOOKINGTIMEDATE] - booking date and time in guests language


[BOOKINGDATEYYYY-MM-DD] - booking date in YYYY-MM-DD format
[BOOKINGDATEYYYY-MM-DD] - booking date in YYYY-MM-DD format


[BOOKINGIP] - ip address of booker's computer
see date and time variables below for custom time formats.
 
[APIMESSAGE] - api message sent by originating channel


=== Content from "Charges and Payments" tab (also see "Invoice/Invoicee/Room") ===
=== Content from "Charges and Payments" tab (also see "Invoice/Invoicee/Room") ===
Line 572: Line 653:
[COMMISSIONNUM] - As per [COMMISSION] but the value is displayed with a decimal point and no thousands separator and no currency symbols (for calculation)
[COMMISSIONNUM] - As per [COMMISSION] but the value is displayed with a decimal point and no thousands separator and no currency symbols (for calculation)


[COMMISSIONGROUP]  - Value of the commission of the complete group booking
[COMMISSIONGROUP]  - Value of the commission of the complete group booking with currency symbol
 
[COMMISSIONGROUPNUM]  - As per [COMMISSIONGROUP] but the value is displayed with a decimal point and no thousands separator and no currency symbols (for calculation)


[GUESTVOUCHER] - voucher code used with booking
[GUESTVOUCHER] - voucher code used with booking
Line 589: Line 672:


=== Content from "Mail & Actions" tab ===
=== Content from "Mail & Actions" tab ===
[GUESTEMAIL] - guest's Email address on the "summary" tab of the booking
[GUESTEMAIL] - guest's Email address on the "Mail & Action" tab of the booking


[GUESTLANGUAGE] - guest language
[GUESTLANGUAGE] - guest language
Line 620: Line 703:
[GUESTSADDRESSSBR1INC] - address of the first guest on the "guests" tab of this booking group incl. cancelled
[GUESTSADDRESSSBR1INC] - address of the first guest on the "guests" tab of this booking group incl. cancelled


===Cancellation, Management and Guest Login===
[GUESTSAFULLADDRESSSBR1INC] - the first address including city, postcode, sate and country from the guests tab of the booking including cancelled bookings in international  format
[CANCELURL] - URL to view and cancel bookings  


[CANCELDATE] - date until when the booking is cancellable displaying a phrase
[GUESTSAFULLADDRESSSBR1] - the first address including city, postcode, sate and country from the guests tab of the booking in International format


[CANCELDATEYYYY-MM-DD] - date until when the booking is cancellable displaying a date. If the date is in the past 00-00-0000 will be shown
[GUESTSBFULLADDRESSSBR1INC] - the first address including city, postcode, sate and country from the guests tab of the booking including cancelled bookings in European format


[DAYSTOCANCEL] - number of days until booking can be cancelled / Anzahl der Tage bis zu denen stroniert werden kann
[GUESTSBFULLADDRESSSBR1] - the first address including city, postcode, sate and country from the guests tab of the booking in European format


[GUESTLOGIN] - URL to view bookings
[GUESTSNUMBOOKINGS1] - the total number of bookings made by the first guest, a group booking counts as one booking.


[TURNOVERDAYS] - days until next arrival into the same unit.
[GUESTSNUMSTAYS1] - the total number of bookings not cancelled and not in the future made by the first guest, a group booking counts as one booking.


==Date and Time==
[GUESTSCUSTOMQ1S]  - answer to custom question 1 for all guests


Many date template variables support PHP strftime format strings between {} brackets to create custom date formats. Information on PHP strftime strings is available at [http://php.net/manual/en/function.strftime.php http://php.net/manual/en/function.strftime.php]
[GUESTSCUSTOMQ1SINC] - answer to custom question 1 for all guests including cancelled bookings


[GUESTSCUSTOMQ2S]  - answer to custom question 2 for all guests


[CURRENTDATE] - current date
[GUESTSCUSTOMQ2SINC] - answer to custom question 2 for all guests including cancelled bookings 


[CURRENTDATEYYYY-MM-DD] - current date in YYYY-MM-DD format
[GUESTSCUSTOMQ3S]  - answer to custom question 3 for all guests


[CURRENTDATE:{%A, %e %B, %Y}] - current date
[GUESTSCUSTOMQ3SINC] - answer to custom question 3 for all guests including cancelled bookings 


[CURRENTDATE:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be any valid PHP strftime format string.
[GUESTSCUSTOMQ4S] - answer to custom question 4 for all guests


[CURRENTTIME] - current time and the display can be any valid PHP strftime format string.
[GUESTSCUSTOMQ4SINC] - answer to custom question 4 for all guests including cancelled bookings 


[CURRENTTIME:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be any valid PHP strftime format string.
[GUESTSCUSTOMQ5S] - answer to custom question 5 for all guests


[DAYSTOCHECKIN] - number of days until check-in
[GUESTSCUSTOMQ5SINC] - answer to custom question 5 for all guests including cancelled bookings


[INADVANCE] - number of days between booking and check-in
[GUESTSCUSTOMQ6S] - answer to custom question 6 for all guests


[DAYSBETWEEN:2019-11-01:2019-11-10] - this template variable will calculate the number of days between the :: the dates need to be in yyyy-mm-dd format. Template variables can be used for calculation.
[GUESTSCUSTOMQ6SINC] - answer to custom question 6 for all guests including cancelled bookings 


Example:  [[DAYSBETWEEN:[FIRSTNIGHT:+5 days{%G-%m-%d}]:[CURRENTDATE:{%G-%m-%d}]] will calculate the days between 5 days after check-in and today.
[GUESTSCUSTOMQ7S] - answer to custom question 7 for all guests


[FIRSTNIGHT:{%A, %e %B, %Y}] -  first night booked
[GUESTSCUSTOMQ7SINC] - answer to custom question 7 for all guests including cancelled bookings  


[FIRSTNIGHT:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be any valid PHP strftime format string.
[GUESTSCUSTOMQ7S] - answer to custom question 8 for all guests


[LASTNIGHT:{%A, %e %B, %Y}] - last night booked
[GUESTSCUSTOMQ8SINC] - answer to custom question 8 for all guests including cancelled bookings


[LASTNIGHT:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be any valid PHP strftime format string.
[GUESTSCUSTOMQ9S] - answer to custom question 9 for all guests


[LEAVINGDAY:{%A, %e %B, %Y}] -  check-out
[GUESTSCUSTOMQ9SINC] - answer to custom question 9 for all guests including cancelled bookings  


[LEAVINGDAY:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be any valid PHP strftime format string.
[GUESTSCUSTOMQ10S] - answer to custom question 10 for all guests


[BOOKINGDATE:{%A, %e %B, %Y}] - booking date
[GUESTSCUSTOMQ10SINC] - answer to custom question 10 for all guests including cancelled bookings


[BOOKINGDATE:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be any valid PHP strftime format string.
===Cancellation, Management and Guest Login===
[CANCELLEDTIME] - date when the booking was cancelled


[MODIFYDATE:{%A, %e %B, %Y}] - last booking modification date/time, the display can be any valid PHP strftime format string.
[CANCELLEDTIME:{%A, %e %B, %Y}] - date when the booking was cancelled


[PAYMENTDATE:{%A, %e %B, %Y}] - most recent payment date
[CANCELURL] - URL to view and cancel bookings


[PAYMENTDATE:+1day{%A, %e %B, %Y}:1:1000] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be any valid PHP strftime format string. The second parameter specifies the payment to show, 0 or missing means the most recent payment. The third parameter specifies the invoicee.
[CANCELDATE] - date until when the booking is cancellable displaying a phrase


[FORMATDATE:[any template variable that creates a date]{%A, %e %B, %Y}] - format the date in the strftime format. The date value could be included by inserting a different template variable containing a date.
[CANCELDATEYYYY-MM-DD] - date until when the booking is cancellable displaying a date. If the date is in the past 00-00-0000 will be shown


== Booking Group variables ==
[DAYSTOCANCEL] - number of days from today until booking can no longer be cancelled (Not applicable for OTA bookings)
=== Custom Booking Group Table ===
create your own booking group list by specifying the columns in the order you want them to appear.


for example: [BOOKGROUP:PROP_ROOM_BREF_NAME]  
[CANCELUNTIL] - shows the number of days between check-in and the last day the booking can be cancelled. If guest can always cancel it shows 0, if guest can never cancel it shows 999. (Not applicable for OTA bookings)


column parameters
[GUESTLOGIN] - URL to view bookings


100% = 100% width
[TURNOVERDAYS] - days until next arrival into the same unit not considering black bookings


ADDR = Booking address
[TURNOVERDAYSB] - days until next arrival into the same unit considering black bookings


ADUL= the number of adults
[VACANTDAYS]  days from previous checkout to check in of current booking not considering black bookings


ARIV = Arrival date
[VACANTDAYSB]  days from previous checkout to check in of current booking considering black bookings


BOPR = Bold prices
==Date and Time==


BREF = Booking number
[CURRENTDATE] - current date


CITY = Booking city
[CURRENTDATEYYYY-MM-DD] - current date  in YYYY-MM-DD format


CHAC = Charges with currency symbol
[CURRENTDATE:{%A, %e %B, %Y}] - current date


CHAR = Charges
[CURRENTDATE:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be in a custom format.


CHIL = Number of children
[CURRENTTIME] - current time.


COUN = Booking country
[CURRENTTIME:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be in a custom format.


DEPT = Departure date
[DAYSTOCHECKIN] -  number of days until check-in


EMAI = Booking Email
[INADVANCE] - number of days between booking and check-in


EXSP = extra space between rows
[DAYSBETWEEN:2019-11-01:2019-11-10] - this template variable will calculate the number of days between the :: the dates need to be in yyyy-mm-dd format. Template variables can be used for calculation.


FLAG = Booking flag text
Example:  [[DAYSBETWEEN:[FIRSTNIGHT:+5 days{%G-%m-%d}]:[CURRENTDATE:{%G-%m-%d}]] will calculate the days between 5 days after check-in and today.


FNAM = Booking first name
[FIRSTNIGHT:{%A, %e %B, %Y}] -  first night booked


GADD = Guest address
[FIRSTNIGHT:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be in a custom format.


GCIT = Guest city
[LASTNIGHT:{%A, %e %B, %Y}] -  last night booked


GCOM = Guest company
[LASTNIGHT:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be in a custom format.


GCOU = Guest country
[LEAVINGDAY:{%A, %e %B, %Y}] -  check-out


GFLA = Guest flag text
[LEAVINGDAY:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be in a custom format.


GFNA = Guest first name
[BOOKINGDATE:{%A, %e %B, %Y}] - booking date


GLNA = Guest last name
[BOOKINGDATE:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be in a custom format.


GMOB = Guest mobile
[MODIFYDATE:{%A, %e %B, %Y}] - last booking modification date/time.


GNAM = Guest full name
[PAYMENTDATE:{%A, %e %B, %Y}] - most recent payment date


GEMA = Guest Email
[PAYMENTDATE:+1day{%A, %e %B, %Y}:1:1000] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be in a custom format. The second parameter specifies the payment to show, 0 or missing means the most recent payment. The third parameter specifies the invoicee.


GNOT = Guest note
[AUTHORIZEUNTIL] - date until which a card is authorized, this is extracted from the most recent authorize booking info code.


GPOS = Guest postcode
[AUTHORIZEUNTIL{%A, %e %B, %Y}] - custom format date until which a card is authorized, this is extracted from the most recent authorize booking info code.


GREF = Guest Id
[FORMATDATE:[any template variable that creates a date]{%A, %e %B, %Y}] - custom format the date. The date value could be included by inserting a different template variable containing a date.


GSTA = Guest state


GTEL = Guest phone
The following codes can be used in any order between the {} brackets to create custom time and date formats.


ICAN = Include cancelled bookings
    %a An abbreviated textual representation of the day Sun through Sat 
    %A A full textual representation of the day Sunday through Saturday 
    %d Two-digit day of the month (with leading zeros) 01 to 31 
    %e Day of the month, with a space preceding single digits. 1 to 31 
    %u ISO-8601 numeric representation of the day of the week 1 (for Monday) through 7 (for Sunday) 
    %w Numeric representation of the day of the week 0 (for Sunday) through 6 (for Saturday) 
    %V ISO-8601:1988 week number of the given year, starting with the first week of the year with at least 4 weekdays, with Monday being the start of the week 01 through 53 (where 53 accounts for an overlapping week) 
    %b Abbreviated month name, based on the locale Jan through Dec 
    %B Full month name, based on the locale January through December 
    %h Abbreviated month name, based on the locale (an alias of %b) Jan through Dec 
    %m Two digit representation of the month 01 (for January) through 12 (for December) 
    %y Two digit representation of the year Example: 09 for 2009, 79 for 1979 
    %Y Four digit representation for the year Example: 2038 
    %H Two digit representation of the hour in 24-hour format 00 through 23 
    %I Two digit representation of the hour in 12-hour format 01 through 12 
    %M Two digit representation of the minute 00 through 59 
    %p UPPER-CASE 'AM' or 'PM' based on the given time Example: AM for 00:31, PM for 22:23 
    %P lower-case 'am' or 'pm' based on the given time Example: am for 00:31, pm for 22:23 
    %R Same as "%H:%M" Example: 00:35 for 12:35 AM, 16:44 for 4:44 PM 
    %S Two digit representation of the second 00 through 59 
    %F Same as "%Y-%m-%d" (commonly used in database datestamps) Example: 2009-02-05 for February 5, 2009 
    %s Unix Epoch Time timestamp (same as the time() function) Example: 305815200 for September 10, 1979 08:40:00 AM 
    %% A literal percentage character ("%")


LNAM = Booking last name
== Booking Group variables ==
=== Custom Booking Group Table ===
create your own booking group list by specifying the columns in the order you want them to appear.


MOBI = Booking mobile
for example: [BOOKGROUP:PROP_ROOM_BREF_NAME]


NAME = Booking full name
column parameters


NOHE = no header
100% = 100% width


NOTE = Booking note
ADDR = Booking address


ONAM = Offer Name
ADUL= the number of adults


ONLY = Just show the one booking
ARIV = Arrival date


PAIC = Payment amount with currency symbol
BOPR = Bold prices


PAID = Paid amount
BREF = Booking number


PEOP = Number of guests
BRL1 = Last digit of booking number


PHON = Booking phone
BRL2 = Last 2 digits of booking number


POST = Booking postcode
BRL3 = Last 3 digits of booking number


PROP = Property name
BRL4 = Last 4 digits of booking number


RDE0 = Room description from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT
BRL5 = Last 5 digits of booking number


RDE1 = Room description 1 from {{#fas:cog}} (SETTINGS) PROPERTIES> ROOMS > SETUP
BRL6 = Last 6 digits of booking number


RNAM = Room Display Name
CITY = Booking city
ROOM = Room name


STAT = Booking state
CHAC = Charges with currency symbol


TOTA = Total price
CHAR = Charges


UNI2 = Unit first additional information
CHIL = Number of children
     
UNI3 = Unit second additional information


UNIT = Unit name
COUN = Booking country


DEPT = Departure date


Connect the parameters with an underscore.
EMAI = Booking Email


Examples:
EXSP = extra space between rows


[BOOKGROUP:PROP_ROOM_BREF_NAME] will display the property name, room name,  booking number and guest name in this order.
FLAG = Booking flag text


FNAM = Booking first name


[BOOKGROUP:BREF_NAME_PROP_ROOM] will display the booking number, guest name property name and  room name in this order.
GADD = Guest address


=== Booking Group Table with fixed content===
GCIT = Guest city
[BOOKGROUPROOMLIST] - create a table of guest names including room type for a group booking


[BOOKGROUPROOMLISTTOTAL] - create a table of guest names including room type for a group booking with guest totals
GCOM = Guest company


[BOOKGROUPROOMLISTCHARGETOTAL] - create a table of guest names including room type and charge for a group booking with guest totals
GCOU = Guest country


[BOOKGROUPNAMELIST] - create a table of guest names including room type and unit for a group booking
GFLA = Guest flag text


[BOOKGROUPNAMELISTTOTAL] - create a table of guest names including room type and unit for a group booking with guest totals
GFNA = Guest first name


[BOOKGROUPNAMELISTCHARGETOTAL] - create a table of guest names including room type and unit and charge for a group booking with guest totals
GLNA = Guest last name


[BOOKGROUPUNITLIST] - create a table of guest names including unit for a group booking
GMOB = Guest mobile


[BOOKGROUPUNITLISTTOTAL] - create a table of guest names including unit for a group booking with guest totals
GNAM = Guest full name


[BOOKGROUPUNITLISTCHARGETOTAL] - create a table of guest names including unit and charge for a group booking with guest totals
GEMA = Guest Email


== Invoice Variables ==
GNOT = Guest note
[INVOICENUMBER] - invoice number


[INVOICENUMBERS] - invoice number if invoicees are involved
GPOS = Guest postcode


[INVOICEDATE] - invoice date
GREF = Guest Id


[INVOICEDATE:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days and the display can be any valid PHP strftime format string.
GSTA = Guest state
=== Invoice Values ===
These template variables will display a value form the invoice.


==== Custom Invoice Values====
GTEL = Guest phone
You have the option to create a custom invoice variable to display a value from an invoice. Available content variables are:


CHA - charges
ICAN = Include cancelled bookings


CON - currency conversion. Example: CONEURUSD will convert the first currency (Euros) to the second currency (USD). CON1.234 would multiply the prices by 1.234
LNAM = Booking last name


DEC - Decimal points. Example: DEC, will show a comma as decimal point. If nothing is set the system will use the default for the language
MOBI = Booking mobile


DP0 - no decimal places
NAME = Booking full name


DP1 - 1 decimal place
NOHE = no header


DP2 - 2 decimal places
NOTE = Booking note


DP3 - 3 decimal places
NUMN = Number of nights booked


DP4 - 4 decimal places
ONAM = Offer Name


DESsome description - sum of values with "some description"
ONLY = Just show the one booking


INV - invoicee, add the invoicee number at the end. Example: INV20 to show invoicee number 20, INV0 will show items not assigned to an invoicee, INV-1 will show all items from the booking regardless of invoicee. You can combine INV[BOOKINGINVOICEEID]] to add the invoicee from the booking
PAIC = Payment amount with currency symbol


IT1 - item 1 in the invoice
PADD = Property Address


IT2 -  item 2 in the invoice
PAID = Paid amount


IT3 -  item 3 in the invoice
PCIT = Property City


IT4 -  item 4 in the invoice
PEOP = Number of guests


IT5 -  item 5 in the invoice
PHON = Booking phone


MUL - multiplier. Example: MUL1.2 will multiply all prices by 1.2
POST = Booking postcode


NUM - show with decimal place (for scripts)
PROP = Property name


THO - thousands separator. THO. will show a dot as thousand separator. If nothing is set the system will use the default for the language
RDE0 =  Room description from {{#fas:cog}} (SETTINGS) CHANNEL MANAGER > PROPERTY CONTENT > ROOM CONTENT


UPS1 - upsell 1
RDE1 = Room description 1 from {{#fas:cog}} (SETTINGS) PROPERTIES> ROOMS > SETUP


UPS2 - upsell 2
RNAM = Room Display Name
ROOM = Room name


UPS3 - upsell 3
RQTY = shows the number of rooms for each booking and a total at the bottom


UPS4 - upsell 4
STAT = Booking state


UPS5 - upsell 5
STUS = Status


ONE - shows only items from the specified booking (not the booking group)
TEXT = Prints a plain text table instead of HTML


PAY - shows payments
TOTA = Total price


QTY - shows quantity
UNI2 = Unit first additional information
     
UNI3 = Unit second additional information


SEX - status excluded. Calculate the balance of all invoice items except for the ones with these status, the status items can be a comma separated list. Example: SEX status1,status2,status4 will not show items with this status.
UNIT = Unit name


SIN - status included. Calculate the balance of all invoice items with matching status, the status items can be a comma separated list. Example: SIN status1,status2,status4 will only show items with this status.


VAT - VAT summary
Connect the parameters with an underscore.


Examples:


Connect the variables with an underscore.  
[BOOKGROUP:PROP_ROOM_BREF_NAME] will display the property name, room name,  booking number and guest name in this order.


Examples:


[INVOICEVAL:PAY_THO] will show payments with a thousands separator
[BOOKGROUP:BREF_NAME_PROP_ROOM] will display the booking number, guest name property name and  room name in this order.


[INVOICEVAL:UPS1_UPS1] will show the sum of upsell 1 and upsell 2
=== Booking Group Table with fixed content===
[BOOKGROUPROOMLIST] - create a table of guest names including room type for a group booking


==== Standard Invoice Values====
[BOOKGROUPROOMLISTTOTAL] - create a table of guest names including room type for a group booking with guest totals
[INVOICEBALANCE] - invoice balance


[INVOICEBALANCE:50%] - percentage of invoice balance
[BOOKGROUPROOMLISTCHARGETOTAL] - create a table of guest names including room type and charge for a group booking with guest totals


[INVOICEBALANCE:-100] - invoice balance with offset amount
[BOOKGROUPNAMELIST] - create a table of guest names including room type and unit for a group booking


[INVOICEBALANCENUM] - As per [INVOICEBALANCE] but the value is displayed with a decimal point and no thousands separator (for calculation).
[BOOKGROUPNAMELISTTOTAL] - create a table of guest names including room type and unit for a group booking with guest totals


[INVOICEBALANCENUM:] - As per [INVOICEBALANCE:] but the value is displayed with a decimal point and no thousands separator (for calculation).
[BOOKGROUPNAMELISTCHARGETOTAL] - create a table of guest names including room type and unit and charge for a group booking with guest totals


[INVOICEPARTBALANCE:status1,status2,!status4:10%] - Calculate the balance of all invoice items with matching status and apply optional multiplier or offset. The status items can be a comma separated list. To exclude status items prefix them with an exclamation mark, for example !status1. The offset is optional and can be specified after a second colon (:) and it can be a percentage by ending the number with the percent (%) symbol or a numeric value offset.
[BOOKGROUPUNITLIST] - create a table of guest names including unit for a group booking


[INVOICEPARTBALANCENUM:status1,status2,status4:10%] - As per INVOICEPARTBALANCE but the value is displayed with a decimal point and no thousands separator (for calculation).
[BOOKGROUPUNITLISTTOTAL] - create a table of guest names including unit for a group booking with guest totals


[INVOICEBALANCE1] - invoice balance of one booking only, not the booking group
[BOOKGROUPUNITLISTCHARGETOTAL] - create a table of guest names including unit and charge for a group booking with guest totals


[INVOICEBALANCE1NUM] - As per [INVOICEBALANCE1] but the value is displayed with a decimal point and no thousands separator (for calculation)
== Invoice Variables ==
[INVOICENUMBER] - invoice number


[INVOICECHARGES] - invoice sum of all charges
[INVOICENUMBERS] - invoice number if invoicees are involved


[INVOICECHARGES:50%] - invoice sum of all charges with percentage multiplier
[INVOICEDATE] - invoice date


[INVOICECHARGES:-100] - invoice sum of all charges with offset
[INVOICEDATES] - invoice date invoice number if invoicees are involved


[INVOICECHARGESNUM] - As per [INVOICECHARGES] but the value is displayed with a decimal point and no thousands separator (for calculation)
[INVOICEDATE:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days.


[INVOICECHARGESNUM:] - As per [INVOICECHARGES:] but the value is displayed with a decimal point and no thousands separator (for calculation)
[INVOICEDATES:+1day{%A, %e %B, %Y}] - optional date offset and display format - invoice date invoice number if invoicees are involved, The offset can be any plus or minus any number of days.


[INVOICEPARTCHARGES:status1,status2,!status4:10%] - Calculate the balance of all invoice charges with matching status and apply optional multiplier or offset. The status items can be a comma separated list. To exclude status items prefix them with an exclamation mark, for example !status1. The offset optional and can be specified after a second colon (:) and it can be a percentage by ending the number with the percent (%) symbol or a numeric value offset.
=== Invoice Values ===
These template variables will display a value form the invoice.


[INVOICEPARTCHARGESNUM:status1,status2,status4:10%] - As per INVOICEPARTCHARGES but the value is displayed with a decimal point and no thousands separator (for calculation).
==== Custom Invoice Values====
You have the option to create a custom invoice variable to display a value from an invoice. [INVOICEVAL with a selection of the following variables specifies the calculation:


[INVOICEPAYMENTS] - invoice sum of all payments
CHA - charges


[INVOICEPAYMENTS:50%] - invoice sum of all payments with percentage multiplier
CON - currency conversion. Example: CONEURUSD will convert the first currency (Euros) to the second currency (USD). CON1.234 would multiply the prices by 1.234


[INVOICEPAYMENTS:-100] - invoice sum of all payments with offset
DEC - Decimal points. Example: DEC, will show a comma as decimal point. If nothing is set the system will use the default for the language


[INVOICEPAYMENTSNUM] - As per [INVOICEPAYMENTS] but the value is displayed with a decimal point and no thousands separator (for calculation)
DP0 - no decimal places


[INVOICEPAYMENTSNUM:50%] - As per [INVOICEPAYMENTS:50%] but the value is displayed with a decimal point and no thousands separator.
DP1 - 1 decimal place


[INVOICEPARTPAYMENTS:status1,status2,!status4:10%] - Calculate the balance of all invoice payments with matching status and apply optional multiplier or offset. The status items can be a comma separated list. To exclude status items prefix them with an exclamation mark, for example !status1. The offset optional and can be specified after a second colon (:) and it can be a percentage by ending the number with the percent (%) symbol or a numeric value offset.
DP2 - 2 decimal places


[INVOICEPARTPAYMENTSNUM:status1,status2,status4:10%] - As per INVOICEPARTCHARGES but the value is displayed with a decimal point and no thousands separator (for calculation).
DP3 - 3 decimal places


[INVOICEPENDPAY] - all (auto and manual) pending payments including failed
DP4 - 4 decimal places


[INVOICEPENDPAYNUM] - all (auto and manual) pending payments including failed but the value is displayed with a decimal point and no thousands separator (for calculation).
DES - used as "DESsome description" - gives the sum of values containing the description "some description"


[INVOICEPENDPAY1234] - all (auto and manual) pending payments including failed for the specified invoicee (-1 will include all items regardless of invoicee)
INV - invoicee, add the invoicee number at the end. Example: INV20 to show invoicee number 20, INV0 will show items not assigned to an invoicee, INV-1 will show all items from the booking regardless of invoicee. You can combine INV[BOOKINGINVOICEEID]] to add the invoicee from the booking


[INVOICEPENDPAYNUM1234] - all (auto and manual) pending payments including failed for the specified invoicee (-1 will include all items regardless of invoicee) The value is displayed with a decimal point and no thousands separator (for calculation).
IT1 - item 1 in the invoice


[INVOICEPENDPAYAUTO] -   auto pending payments before due date
IT2 item 2 in the invoice


[INVOICEPENDPAYAUTONUM] - auto pending payments before due date but the value is displayed with a decimal point and no thousands separator (for calculation).
IT3 item 3 in the invoice


[INVOICEPENDPAYAUTO1234] auto pending payments before due date for the specified invoicee but the value is displayed with a decimal point and no thousands separator (for calculation) (-1 will include all items regardless of invoicee)
IT4 - item 4 in the invoice


[INVOICEPENDPAYAUTONUM1234] auto pending payments before due date for the specified invoicee but the value is displayed with a decimal point and no thousands separator (for calculation) (-1 will include all items regardless of invoicee)
IT5 - item 5 in the invoice


[INVOICEPENDPAYFAIL]  - failed pending payments (all also past)
MUL - multiplier. Example: MUL1.2 will multiply all prices by 1.2


[INVOICEPENDPAYFAILNUM] - failed pending payments (all also past)  but the value is displayed with a decimal point and no thousands separator (for calculation)
NUM - show with decimal place (for scripts)


[INVOICEPENDPAYFAIL234] - failed pending payments (all also past) for the specified invoicee  (-1 will include all items regardless of invoicee)
THO - thousands separator. THO. will show a dot as thousand separator. If nothing is set the system will use the default for the language


[INVOICEPENDPAYFAILNUM234] - failed pending payments (all also past) for the specified invoicee but the value is displayed with a decimal point and no thousands separator (for calculation) (-1 will include all items regardless of invoicee)
UPS1 - upsell 1


[INVOICEPENDPAYRULE1] - shows all pending payment for this rule (exchange 1 for the rule number)
UPS2 - upsell 2


[INVOICEPENDPAYRULENUM1] - shows all pending payment for this rule (exchange 1 for the rule number) displayed with a decimal point and no thousands separator (for calculation)
UPS3 - upsell 3


[INVOICEPENDPAYMANUAL] - manual pending payments
UPS4 - upsell 4


[INVOICEPENDPAYMANUALNUM] - manual pending payments but the value is displayed with a decimal point and no thousands separator (for calculation).
UPS5 - upsell 5


[INVOICEPENDPAYMANUALNOTDUE] manual pending payments before due date
ONE - shows only items from the specified booking (not the booking group)


[INVOICEPENDPAYMANUALNOTDUENUM] manual  pending payments before due date  but the value is displayed with a decimal point and no thousands separator (for calculation).
PAY - shows payments  


[INVOICEPENDPAYMANUALOVERDUE] manual  pending payments after due date
QTY - shows quantity


[INVOICEPENDPAYMANUALOVERDUENUM] manual  pending payments after due date  but the value is displayed with a decimal point and no thousands separator (for calculation)
SEX - status excluded. Calculate the balance of all invoice items except for the ones with these status, the status items can be a comma separated list. Example: SEX status1,status2,status4 will not show items with this status.


[INVOICECREDITS] - invoice sum of all credit items (negative items)
SIN - status included. Calculate the balance of all invoice items with matching status, the status items can be a comma separated list. Example: SIN status1,status2,status4 will only show items with this status.


[INVOICECREDITS:50%] - invoice sum of all credit items with percentage multiplier
VAT - VAT summary


[INVOICECREDITS:-100] - invoice sum of all credit items with offset


[INVOICECREDITSNUM] - As per [INVOICECREDITS] but the value is displayed with a decimal point and no thousands separator (for calculation)
Connect the variables with an underscore.


[INVOICECREDITSNUM:] - As per [INVOICECREDITS:] but the value is displayed with a decimal point and no thousands separator (for calculation)
Examples:  


[INVOICEDEBITS] - invoice sum of all debit items (positive items)
[INVOICEVAL:PAY_THO] will show payments with a thousands separator


[INVOICEDEBITS:50%] - invoice sum of all debit items with percentage multiplier
[INVOICEVAL:UPS1_UPS2] will show the sum of upsell 1 and upsell 2


[INVOICEDEBITS:-100] - invoice sum of all debit items with offset
==== Standard Invoice Values====
[INVOICEBALANCE] - invoice balance


[INVOICEDEBITSNUM] - As per [INVOICEDEBITS] but the value is displayed with a decimal point and no thousands separator (for calculations) (for calculations)
[INVOICEBALANCE:50%] - percentage of invoice balance


[INVOICEDEBITSNUM:] - As per [INVOICEDEBITS:] but the value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEBALANCE:-100] - invoice balance with offset amount


[INVOICEVAT] - invoice sum of all vat value
[INVOICEBALANCENUM] - As per [INVOICEBALANCE] but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICEVATNUM] - invoice sum of all vat value for calculations)
[INVOICEBALANCENUM:] - As per [INVOICEBALANCE:] but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICEFIRSTITEM] - price of the item listed first in the invoice
[INVOICEPARTBALANCE:status1,status2,!status4:10%] - Calculate the balance of all invoice items with matching status and apply optional multiplier or offset. The status items can be a comma separated list. To exclude status items prefix them with an exclamation mark, for example !status1. The offset is optional and can be specified after a second colon (:) and it can be a percentage by ending the number with the percent (%) symbol or a numeric value offset.


[INVOICEFIRSTITEMNUM] - price of the item listed first in the invoice but the value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEPARTBALANCENUM:status1,status2,status4:10%] - As per INVOICEPARTBALANCE but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICESECONDITEM] - price of the item listed second in the invoice
[INVOICEBALANCE1] - invoice balance of one booking only, not the booking group


[INVOICESECONDITEMNUM] - price of the item listed second in the invoice but the value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEBALANCE1NUM] - As per [INVOICEBALANCE1] but the value is displayed with a decimal point and no thousands separator (for calculation)


[INVOICETHIRDITEM] - price of the item listed third in the invoice
[INVOICECHARGES] - invoice sum of all charges


[INVOICETHIRDITEMNUM] - price of the item listed third in the invoice but the value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICECHARGES:50%] - invoice sum of all charges with percentage multiplier


[INVOICEUPSELL0] - base price without upsell items or other charges added later
[INVOICECHARGES:-100] - invoice sum of all charges with offset


[INVOICEUPSELLNUM0] - as per [INVOICEUPSELL1] but the value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICECHARGESNUM] - As per [INVOICECHARGES] but the value is displayed with a decimal point and no thousands separator (for calculation)


[INVOICEUPSELL1] - value of upsell item 1 (number can be between 0 to 20)
[INVOICECHARGESNUM:] - As per [INVOICECHARGES:] but the value is displayed with a decimal point and no thousands separator (for calculation)


[INVOICEUPSELLNUM1] - as per [INVOICEUPSELL1] but the value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEPARTCHARGES:status1,status2,!status4:10%] - Calculate the balance of all invoice charges with matching status and apply optional multiplier or offset. The status items can be a comma separated list. To exclude status items prefix them with an exclamation mark, for example !status1. The offset optional and can be specified after a second colon (:) and it can be a percentage by ending the number with the percent (%) symbol or a numeric value offset.


[INVOICEUPSELLQTY1] - quantity of upsell item 1 (number can be between 1 to 20)
[INVOICEPARTCHARGESNUM:status1,status2,status4:10%] - As per INVOICEPARTCHARGES but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICEUPSELLHEADLINE1] - headline of upsell item 1 (number can be between 1 to 20)
[INVOICEPAYMENTS] - invoice sum of all payments


[INVOICEUPSELLDESCRIPTION1] - description of upsell item 1 (number can be between 1 to 20)
[INVOICEPAYMENTS:50%] - invoice sum of all payments with percentage multiplier


[INVOICEEXTRAITEMDESC1] - Name of extra invoice item 1 (number can be between 0 to 20)
[INVOICEPAYMENTS:-100] - invoice sum of all payments with offset


[INVOICEEXTRAITEM1] - value of extra invoice item 1 (number can be between 0 to 20) Note: the order goes by the order in the dropdown list not by the order the items are entered.
[INVOICEPAYMENTSNUM] - As per [INVOICEPAYMENTS] but the value is displayed with a decimal point and no thousands separator (for calculation)


[INVOICEEXTRAITEM1] - value of extra invoice item 1 (number can be between 0 to 20) Note: the order goes by the order in the dropdown list not by the order the items are entered.  
[INVOICEPAYMENTSNUM:50%] - As per [INVOICEPAYMENTS:50%] but the value is displayed with a decimal point and no thousands separator.


[INVOICEEXTRAITEMNUM1] - as per [INVOICEEXTRAITEM1] but the value is displayed with a decimal point and no thousands separator (for calculations).
[INVOICEPARTPAYMENTS:status1,status2,!status4:10%] - Calculate the balance of all invoice payments with matching status and apply optional multiplier or offset. The status items can be a comma separated list. To exclude status items prefix them with an exclamation mark, for example !status1. The offset optional and can be specified after a second colon (:) and it can be a percentage by ending the number with the percent (%) symbol or a numeric value offset.


[INVOICEEXTRAITEMQTY1] - quantity of extra invoice item 1 (number can be between 0 to 20) Note: the order goes by the order in the dropdown list not by the order the items are entered.  
[INVOICEPARTPAYMENTSNUM:status1,status2,status4:10%] - As per INVOICEPARTCHARGES but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICEGROSS:1] - gross amount of the inserted VAT rate (number is the VAT rate), value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEPENDPAY] - all (auto and manual) pending payments including failed


INVOICEGROSSNUM:1] gross amount of the inserted VAT rate (number is the VAT rate)
[INVOICEPENDPAYNEXTDATE] - date of the next pending payment


[INVOICENET:1] - net amount of the inserted VAT rate (number is the VAT rate)
[INVOICEPENDPAYNUM] - all (auto and manual) pending payments including failed but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICENETNUM:1] - net amount of the inserted VAT rate (number is the VAT rate), value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEPENDPAY1234] - all (auto and manual) pending payments including failed for the specified invoicee (-1 will include all items regardless of invoicee)


[INVOICEVAT:1] - VAT amount of the inserted VAT rate (number is the VAT rate)
[INVOICEPENDPAYNUM1234] - all (auto and manual) pending payments including failed for the specified invoicee (-1 will include all items regardless of invoicee) The value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICEVATNUM:1] VAT amount of the inserted VAT rate (number is the VAT rate), value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEPENDPAYAUTO] -  auto  pending payments before due date


[INVOICEITEMBYDESC:Searchterm] -  searches the invoice for items with this search term and adds them up
[INVOICEPENDPAYAUTONUM] - auto pending payments before due date but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICEITEMBYDESCNUM:Searchterm] - searches the invoice for items with  this search term and adds them up, value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEPENDPAYAUTO1234auto pending payments before due date for the specified invoicee but the value is displayed with a decimal point and no thousands separator (for calculation) (-1 will include all items regardless of invoicee)


[INVOICEPAYMENTBYDESC:Searchterm] - searches the payments for items with this search term and adds them up
[INVOICEPENDPAYAUTONUM1234auto pending payments before due date for the specified invoicee but the value is displayed with a decimal point and no thousands separator (for calculation) (-1 will include all items regardless of invoicee)


[INVOICEPAYMENTBYDESCNUM:Searchterm] - searches the payments for items with  this search term and adds them up, value is displayed with a decimal point and no thousands separator (for calculations)
[INVOICEPENDPAYFAIL] - failed pending payments (all also past)


=== Invoice  Table ===
[INVOICEPENDPAYFAILNUM] - failed pending payments (all also past)  but the value is displayed with a decimal point and no thousands separator (for calculation)
These template varibles will display an invoice table.
==== Standard Invoice Tables ====
[INVOICETABLE] - invoice table


[INVOICETABLEVAT] - invoice table with vat information and vat summary
[INVOICEPENDPAYFAIL234] - failed pending payments (all also past) for the specified invoicee  (-1 will include all items regardless of invoicee)


[INVOICETABLE:$1.1$] - invoice table and currency multiplier with optional new currency symbol before or after price.
[INVOICEPENDPAYFAILNUM234] - failed pending payments (all also past) for the specified invoicee but the value is displayed with a decimal point and no thousands separator (for calculation) (-1 will include all items regardless of invoicee)


[INVOICETABLEPART:status1,status2,!status4] - Invoice table showing only items with matching status. The status items can be a comma separated list. To exclude status items prefix them with an exclamation mark, for example !status1.
[INVOICEPENDPAYRULE1] - shows all pending payment for this rule (exchange 1 for the rule number)


[INVOICETABLE2] - invoice table with status field
[INVOICEPENDPAYRULENUM1] - shows all pending payment for this rule (exchange 1 for the rule number) displayed with a decimal point and no thousands separator (for calculation)


[INVOICETABLE2:$1.1$] - invoice table with status field and currency multiplier with optional new currency symbol before or after price.
[INVOICEPENDPAYMANUAL] - manual pending payments


[INVOICETABLECHARGES] - invoice table showing charges only
[INVOICEPENDPAYMANUALNUM] - manual pending payments but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICETABLECHARGESINVOICEE1234] - invoice table showing charges only assigned to the specified invoicee, specify the invoicee Id number.
[INVOICEPENDPAYMANUALNOTDUE] manual pending payments before due date


[INVOICETABLENOTOT] - invoice table without grand total
[INVOICEPENDPAYMANUALNOTDUENUM] manual  pending payments before due date  but the value is displayed with a decimal point and no thousands separator (for calculation).


[INVOICETABLENOTOT:$1.1$] - invoice table without grand total and currency multiplier with optional new currency symbol before or after price.
[INVOICEPENDPAYMANUALOVERDUE] manual  pending payments after due date


[INVOICETABLENOTOT2- invoice table with status field without grand total
[INVOICEPENDPAYMANUALOVERDUENUM] manual pending payments after due date  but the value is displayed with a decimal point and no thousands separator (for calculation)


[INVOICETABLENOTOT2:$1.1$] - invoice table with status field without grand total and currency multiplier with optional new currency symbol before or after price.
[INVOICECREDITS] - invoice sum of all credit items (negative items)


[INVOICETABLEVAT:$1.1$] - invoice table with vat information and currency multiplier with optional new currency symbol before or after price.
[INVOICECREDITS:50%] - invoice sum of all credit items with percentage multiplier  


[INVOICETABLEVATCOMPACT] - compact version of invoice table with vat information and vat summary
[INVOICECREDITS:-100] - invoice sum of all credit items with offset


[INVOICETABLEVATCOMPACT:$1.1$] - compact version of invoice table with vat information and vat summary and currency multiplier with optional new currency symbol before or after price.
[INVOICECREDITSNUM] - As per [INVOICECREDITS] but the value is displayed with a decimal point and no thousands separator (for calculation)


[INVOICETABLEVATCOMPACTNOSUM] - compact version of invoice table with vat information without vat summary
[INVOICECREDITSNUM:] - As per [INVOICECREDITS:] but the value is displayed with a decimal point and no thousands separator (for calculation)


[INVOICETABLEVATCOMPACTNOSUM:$1.1$] - compact version of invoice table with vat information without vat summary  and currency multiplier with optional new currency symbol before or after price.
[INVOICEDEBITS] - invoice sum of all debit items (positive items)


[INVOICETABLEVATNOSUM] - invoice table with vat information without vat summary
[INVOICEDEBITS:50%] - invoice sum of all debit items with percentage multiplier


[INVOICETABLEVATNOSUM:$1.1$] - invoice table with vat information without vat summary and currency multiplier with optional new currency symbol before or after price.
[INVOICEDEBITS:-100] - invoice sum of all debit items with offset


[INVOICETABLEDATEVATNOSUM] - invoice table with vat information and date without vat summary
[INVOICEDEBITSNUM] - As per [INVOICEDEBITS] but the value is displayed with a decimal point and no thousands separator (for calculations) (for calculations)


[INVOICETABLEDATEVATNOSUM:$1.1$] - invoice table with vat information and date without vat summary and currency multiplier with optional new currency symbol before or after price.
[INVOICEDEBITSNUM:] - As per [INVOICEDEBITS:] but the value is displayed with a decimal point and no thousands separator (for calculations)


[INVOICETABLEVAT2] - invoice table with vat information and status field and vat summary
[INVOICEVAT] - invoice sum of all vat value


[INVOICETABLEVAT2:$1.1$] - invoice table with vat information and status field and vat summary and currency multiplier with optional new currency symbol before or after price.
[INVOICEVATNUM] - invoice sum of all vat value for calculations)


[INVOICETABLEVAT2NOSUM] - invoice table with vat information and status field without vat summary
[INVOICEFIRSTITEM] - price of the item listed first in the invoice


[INVOICETABLEVAT2NOSUM:$1.1$] - invoice table with vat information and status field without vat summary and currency multiplier with optional new currency symbol before or after price.
[INVOICEFIRSTITEMNUM] - price of the item listed first in the invoice but the value is displayed with a decimal point and no thousands separator (for calculations)


[INVOICETABLEVATCHARGES] - invoice table showing charges only with vat information and vat summary
[INVOICESECONDITEM] - price of the item listed second in the invoice


[INVOICETABLENOPRICE] - invoice table with no price information
[INVOICESECONDITEMNUM] - price of the item listed second in the invoice but the value is displayed with a decimal point and no thousands separator (for calculations)


[INVOICETABLEINVOICEE] - invoice table excluding items assigned to an invoicee.
[INVOICETHIRDITEM] - price of the item listed third in the invoice


[INVOICETABLEINVOICEE1234] - invoice table for a specific invoicee, specify the invoicee Id number.
[INVOICETHIRDITEMNUM] - price of the item listed third in the invoice but the value is displayed with a decimal point and no thousands separator (for calculations)


[UPSELLTABLE] - table with all upsell items
[INVOICEFOURTHITEM] - price of the item listed fourth in the invoice


[UPSELLTABLEVAT] - table with all upsell items with vat information and vat summary
[INVOICEFOURTHITEMNUM] - price of the item listed fourth in the invoice but the value is displayed with a decimal point and no thousands separator (for calculations)


[UPSELLTABLENOREFUND] - table with all upsell items except refundable items
[INVOICEFIFTHITEM] - price of the item listed fifth in the invoice


==== Custom Invoice Table ====
[INVOICEFIFTHITEMNUM] - price of the item listed fifth in the invoice but the value is displayed with a decimal point and no thousands separator (for calculations)
You have the option to create a custom invoice table. Available content variables are:


AMO - shows the net value (price x quantity)
[INVOICEUPSELL0] - base price without upsell items or other charges added later


CEX - charges excluded (charges will not be shown)
[INVOICEUPSELLNUM0]  - as per [INVOICEUPSELL1] but the value is displayed with a decimal point and no thousands separator (for calculations)


CON - currency conversion. Example: CONEURUSD will convert the first currency (Euros) to the second currency (USD). CON1.234 would multiply the prices by 1.234
[INVOICEUPSELL1] - value of upsell item 1 (number can be between 0 to 20)


CUA - currency symbol showing after the numbers. Example: CUA€ will show € after the figures
[INVOICEUPSELLNUM1] - as per [INVOICEUPSELL1] but the value is displayed with a decimal point and no thousands separator (for calculations)


CUB - currency symbol showing before the numbers. Example: CUB€ will show € before the figures
[INVOICEUPSELLQTY1] - quantity of upsell item 1 (number can be between 1 to 20)


DAT - adds a date column
[INVOICEUPSELLNAME1]  - name of the headline field of upsell item 1 (number can be between 1 to 20)


DEC - Decimal points. Example: DEC, will show a comma as decimal point. If nothing is set the system will use the default for the language
[INVOICEUPSELLSTATUS1]  - stautus of the headline field of upsell item 1 (number can be between 1 to 20)


DP0 - no decimal places
[INVOICEUPSELLHEADLINE1]  - headline (name and status if used of upsell item 1 (number can be between 1 to 20)


DP1 - 1 decimal place
[INVOICEUPSELLDESCRIPTION1]  - description of upsell item 1 (number can be between 1 to 20)


DP2 - 2 decimal places
[INVOICEUPSELLAMOUNTNUM1] - amout of upsell item 1


DP3 - 3 decimal places


DP4 - 4 decimal places


GAT -  sum for each column


GRP - Group Totals. Displays the same items as a total
[INVOICEUPSELLTYPE1] - type of upsell item 1


GRT - Grand Total
[INVOICEUPSELLPER1] - per of upsell item 1


INV - invoicee, add the invoicee number at the end. Example: INV20 to show invoicee number 20, INV0 will show items not assigned to an invoicee, INV-1 will show all items from the booking regardless of invoicee. You can combine INV[BOOKINGINVOICEEID]] to add the invoicee from the booking
[INVOICEUPSELLPERIOD1]  - period of upsell item 1  


LAN - language. Example LANDE will force the language to German


MUL - multiplier. Example: MUL1.2 will multiply all prices by 1.2
[INVOICEEXTRAITEMDESC1] - Name of extra invoice item 1 (number can be between 0 to 20)


NIN - do not show invoice number and invoice date on locked invoices
[INVOICEEXTRAITEM1] - value of extra invoice item 1 (number can be between 0 to 20) Note: the order goes by the order in the dropdown list not by the order the items are entered.


NOC - charges will not be displayed but their vat values are still calculated for the vat summary (VAT)
[INVOICEEXTRAITEM1] - value of extra invoice item 1 (number can be between 0 to 20) Note: the order goes by the order in the dropdown list not by the order the items are entered.


NOP - payments will not be displayed  
[INVOICEEXTRAITEMNUM1] - as per [INVOICEEXTRAITEM1] but the value is displayed with a decimal point and no thousands separator (for calculations).


ONE - shows only items from the specified booking (not the booking group)
[INVOICEEXTRAITEMQTY1] - quantity of extra invoice item 1 (number can be between 0 to 20)  Note: the order goes by the order in the dropdown list not by the order the items are entered.


PAA - shows a column with payment amounts
[INVOICEGROSS:1] - gross amount of the inserted VAT rate (number is the VAT rate), value is displayed with a decimal point and no thousands separator (for calculations)


PAY - shows payments
INVOICEGROSSNUM:1] gross amount of the inserted VAT rate (number is the VAT rate)


PEN - shows pending payments description
[INVOICENET:1] - net amount of the inserted VAT rate (number is the VAT rate)


PPA - shows pending payments amount
[INVOICENETNUM:1] - net amount of the inserted VAT rate (number is the VAT rate), value is displayed with a decimal point and no thousands separator (for calculations)


PRI - shows prices in a column
[INVOICEVAT:1] - VAT amount of the inserted VAT rate (number is the VAT rate)


QTY - shows quantity
[INVOICEVATNUM:1] VAT amount of the inserted VAT rate (number is the VAT rate), value is displayed with a decimal point and no thousands separator (for calculations)


SEX - status excluded. Calculate the balance of all invoice items except for the ones with these status, the status items can be a comma separated list. Example: SEX status1,status2,status4 will not show items with this status.
[INVOICEITEMBYDESC:Searchterm] - searches the invoice for items with  this search term and adds them up


SIN - status included. Calculate the balance of all invoice items with matching status, the status items can be a comma separated list. Example: SIN status1,status2,status4 will only show items with this status.
[INVOICEITEMBYDESCNUM:Searchterm] searches the invoice for items with  this search term and adds them up, value is displayed with a decimal point and no thousands separator (for calculations)


STA- shows staus
[INVOICEPAYMENTBYDESC:Searchterm] - searches the payments for items with  this search term and adds them up


THO - thousands separator. THO. will show a dot as thousand separator. If nothing is set the system will use the default for the language
[INVOICEPAYMENTBYDESCNUM:Searchterm] - searches the payments for items with  this search term and adds them up, value is displayed with a decimal point and no thousands separator (for calculations)


TOT - shows total amounts
=== Invoice  Table ===
These template varibles will display an invoice table.
==== Standard Invoice Tables ====
[INVOICETABLE] - invoice table


VAA - shows VAT amounts
[INVOICETABLEVAT] - invoice table with vat information and vat summary


VAP - shows VAT percents
[INVOICETABLE:$1.1$] - invoice table and currency multiplier with optional new currency symbol before or after price.


VAT - VAT summary
[INVOICETABLEPART:status1,status2,!status4] - Invoice table showing only items with matching status. The status items can be a comma separated list. To exclude status items prefix them with an exclamation mark, for example !status1.


[INVOICETABLE2] - invoice table with status field


Connect the variables with an underscore.  
[INVOICETABLE2:$1.1$] - invoice table with status field and currency multiplier with optional new currency symbol before or after price.


Examples:
[INVOICETABLECHARGES] - invoice table showing charges only


[INVOICE:PRI_QTY_CUA€] will create an invoice table with price and quantity in Euros.
[INVOICETABLECHARGESINVOICEE1234] - invoice table showing charges only assigned to the specified invoicee, specify the invoicee Id number.


[INVOICE:PAY_TOT_CEX] will create an invoice table which will only show payments.
[INVOICETABLENOTOT] - invoice table without grand total


[INVOICE:PRI_QTY_CUA_TOT_VAT_QTY_PAY_GRT_AMO_VAA] will create an invoice table with more information.
[INVOICETABLENOTOT:$1.1$] - invoice table without grand total and currency multiplier with optional new currency symbol before or after price.


== Invoicee Variables ==
[INVOICETABLENOTOT2] - invoice table with status field without grand total
[INVOICEEBALANCE] - invoice balance for unassigned invoice items.


[INVOICEEBALANCENUM] - invoice balance for unassigned invoice items displayed with a decimal point and no thousands separator.
[INVOICETABLENOTOT2:$1.1$] - invoice table with status field without grand total and currency multiplier with optional new currency symbol before or after price.


[INVOICEEBALANCE1234] - invoice balance for invoice items assigned to invoicee 1234 (change 1234 to the required Invoicee Id number).
[INVOICETABLEVAT:$1.1$] - invoice table with vat information and currency multiplier with optional new currency symbol before or after price.


[INVOICEEBALANCENUM1234] - invoice balance for invoice items assigned to invoicee 1234 (change 1234 to the required Invoicee Id number) displayed with a decimal point and no thousands separator.
[INVOICETABLEVATCOMPACT] - compact version of invoice table with vat information and vat summary


[INVOICEECHARGES] - invoice charges for unassigned invoice items.
[INVOICETABLEVATCOMPACT:$1.1$] - compact version of invoice table with vat information and vat summary and currency multiplier with optional new currency symbol before or after price.


[INVOICEECHARGESNUM] - invoice charges for unassigned invoice items displayed with a decimal point and no thousands separator.
[INVOICETABLEVATCOMPACTNOSUM] - compact version of invoice table with vat information without vat summary


[INVOICEECHARGES1234] - invoice charges for invoice items assigned to invoicee 1234 (change 1234 to the required Invoicee Id number).
[INVOICETABLEVATCOMPACTNOSUM:$1.1$] - compact version of invoice table with vat information without vat summary and currency multiplier with optional new currency symbol before or after price.


[INVOICEECHARGESNUM1234] - invoice charges for invoice items assigned to invoicee 1234  (change 1234 to the required Invoicee Id number) displayed with a decimal point and no thousands separator.
[INVOICETABLEVATNOSUM] - invoice table with vat information without vat summary


[INVOICEEPAYMENTS] - invoice payments for unassigned invoice items.
[INVOICETABLEVATNOSUM:$1.1$] - invoice table with vat information without vat summary and currency multiplier with optional new currency symbol before or after price.


[INVOICEEPAYMENTSNUM] - invoice payments for unassigned invoice items displayed with a decimal point and no thousands separator.
[INVOICETABLEDATEVATNOSUM] - invoice table with vat information and date without vat summary


[INVOICEEPAYMENTS1234] - invoice payments for invoice items assigned to invoicee 1234  (change 1234 to the required Invoicee Id number)
[INVOICETABLEDATEVATNOSUM:$1.1$] - invoice table with vat information and date without vat summary and currency multiplier with optional new currency symbol before or after price.


[INVOICEEPAYMENTSNUM1234] - invoice payments for invoice items assigned to invoicee 1234  (change 1234 to the required Invoicee Id number)
[INVOICETABLEVAT2] - invoice table with vat information and status field and vat summary


[INVOICEENAME] - name of the invoicee account the invoice is assigned to or blank
[INVOICETABLEVAT2:$1.1$] - invoice table with vat information and status field and vat summary and currency multiplier with optional new currency symbol before or after price.


[INVOICEECODE] - code of the invoicee account the invoice is assigned to or blank
[INVOICETABLEVAT2NOSUM] - invoice table with vat information and status field without vat summary


[INVOICEECURRENCY] - currency of the invoicee account the invoice is assigned to if it is not the property default or blank
[INVOICETABLEVAT2NOSUM:$1.1$] - invoice table with vat information and status field without vat summary and currency multiplier with optional new currency symbol before or after price.


[INVOICEETEMPLATE1] - template value 1 of the invoice account the invoice is assigned to or blank
[INVOICETABLEVATCHARGES] - invoice table showing charges only with vat information and vat summary


[INVOICEETEMPLATE2] - template value 2 of the invoice account the invoice is assigned to or blank
[INVOICETABLENOPRICE] - invoice table with no price information


[INVOICEETEMPLATE3] - template value 3 of the invoice account the invoice is assigned to or blank
[INVOICETABLEINVOICEE] - invoice table excluding items assigned to an invoicee.


[INVOICEETEMPLATE4] - template value 4 of the invoice account the invoice is assigned to or blank
[INVOICETABLEINVOICEE1234] - invoice table for a specific invoicee, specify the invoicee Id number.


[INVOICEETEMPLATE5] - template value 5 of the invoice account the invoice is assigned to or blank
[UPSELLTABLE] - table with all upsell items


[INVOICEETEMPLATE6] - template value 6 of the invoice account the invoice is assigned to or blank
[UPSELLTABLEVAT] - table with all upsell items with vat information and vat summary


[INVOICEETEMPLATE7] - template value 7 of the invoice account the invoice is assigned to or blank
[UPSELLTABLENOREFUND] - table with all upsell items except refundable items


[INVOICEETEMPLATE8] - template value 8 of the invoice account the invoice is assigned to or blank
==== Custom Invoice Table ====
You have the option to create a custom invoice table. Available content variables are:


== Guest Variables ==
AMO - shows the net value (price x quantity)
[GUESTIDS] - comma separated list of guest Id's connected to the booking


[GUESTFLAGTEXTS] - comma separated list of flag text values for each guest (when not empty) connected to the booking
CEX - charges excluded (charges will not be shown)


== Payment Request Variables ==
CON - currency conversion. Example: CONEURUSD will convert the first currency (Euros) to the second currency (USD). CON1.234 would multiply the prices by 1.234
[PAYURL] - Creates a  payment url for the payment request for the amount in the booking deposit field if non zero, otherwise the outstanding balance.


[PAYURL:25%] - Creates a payment url for the payment request for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance.
CUA - currency symbol showing after the numbers. Example: CUA€ will show € after the figures


[PAYURL:200] - Creates a payment url for the payment request url for a fixed amount. nt.
CUB - currency symbol showing before the numbers. Example: CUB€ will show € before the figures


[PAYLINK] - Creates a payment link (HTML A tag) for the payment request for the amount in the booking deposit field if non zero, otherwise the outstanding balance.
DAT - adds a date column - you have the option to control the format of the date using [[Template_Variables#Date_and_Time|date and time variables]] for example DAT{%d-%m-%Y}


[PAYLINK:25%] -Creates a payment link (HTML A tag) for the payment request for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance.
DEC - Decimal points. Example: DEC, will show a comma as decimal point. If nothing is set the system will use the default for the language


[PAYLINK:200] - Creates a  payment link (HTML A tag) for the payment request) for a fixed amount.
DP0 - no decimal places


[PAYBUTTON] - Creates a payment button for the payment request for the amount in the booking deposit field if non zero, otherwise the outstanding balance. Not recommended for emails.
DP1 - 1  decimal place


[PAYBUTTON:25%] - Creates a payment button for the payment request for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance. Not recommended for emails.
DP2  - 2 decimal places


[PAYBUTTON:200] - Creates a payment button for the payment request for a fixed amount.
DP3 - 3 decimal places


[PAYPALURL] - Creates a Paypal payment url for the amount in the booking deposit field if non zero, otherwise the outstanding balance.
DP4 - 4 decimal places


[PAYPALURL:25%] - Creates a Paypal payment url for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance.
GAT - sum for each column


[PAYPALURL:200] - Creates a Paypal payment url for a fixed amount. A zero amount will cause paypal to provide a field to enter an amount.
GRP  - Group Totals. Displays the same items as a total


[PAYPALLINK] - Creates a Paypal payment link (HTML A tag) for the amount in the booking deposit field if non zero, otherwise the outstanding balance.
GRT  - Grand Total


[PAYPALLINK:25%] - Creates a Paypal payment link (HTML A tag) for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance.
INV - invoicee, add the invoicee number at the end. Example: INV20 to show invoicee number 20, INV0 will show items not assigned to an invoicee, INV-1 will show all items from the booking regardless of invoicee. You can combine INV[BOOKINGINVOICEEID]] to add the invoicee from the booking


[PAYPALLINK:200] - Creates a Paypal payment link (HTML A tag) for a fixed amount. A zero amount will cause paypal to provide a field to enter an amount.
LAN - language. Example LANDE will force the language to German


[PAYPALBUTTON] - Creates a Paypal payment button for the amount in the booking deposit field if non zero, otherwise the outstanding balance. Not recommended for emails.
MUL - multiplier. Example: MUL1.2 will multiply all prices by 1.2


[PAYPALBUTTON:25%] - Creates a Paypal payment button for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance. Not recommended for emails.
NIN - do not show invoice number and invoice date on locked invoices


[PAYPALBUTTON:200] - Creates a Paypal payment button for a fixed amount. A zero amount will cause paypal to provide a field to enter an amount. Not recommended for emails.
NOC - charges will not be displayed but their vat values are still calculated for the vat summary (VAT)


Add a H to exclude a gateway from displaying. Example: [PAYURL:200:HST] will hide Stripe
NOP - payments will not be displayed


== Text Operators ==
ONE - shows only items from the specified booking (not the booking group)


[REPLACE|searchForThisText|replaceWithThisText|textToSearch] - replace "searchForThisText" with "replaceWithThisText" within the text "textToSearch"
ORB - order by booking, this keeps the items for each booking (room) together in the table


== iCal Links ==
PAA - shows a column with payment amounts
These template variables will create iCal links which allow the booking to be added to a calendar.


[ICALURL] - Calendar link
PAY - shows payments


[ICALURL:16] - Calendar link with check-in hour. Replace '16' with the hour check-in starts.
PEN - shows pending payments description


[ICALURL::10] - Calendar link with check-out hour. Replace '10' with the hour with the hour check-out ends.
PPA - shows pending payments amount 


[ICALURL:::summary text] - Calendar link with a summary text
PRI - shows prices in a column


[ICALURL::::description text] - Calendar link with a descriptive text
QTY - shows quantity


Example:
SEX - status excluded. Calculate the balance of all invoice items except for the ones with these status, the status items can be a comma separated list. Example: SEX status1,status2,status4 will not show items with this status.


Calendar link with check-in time 16:00, check-out time 10:00, the summary text "Booking" and the description text "Sunny Hotel":
SIN - status included.  Calculate the balance of all invoice items with matching status, the status items can be a comma separated list. Example: SIN status1,status2,status4 will only show items with this status.


[ICALURL:16:10:Booking:Sunny Hotel]
STA- shows staus


== Mathematical Operators ==
THO - thousands separator. THO. will show a dot as thousand separator. If nothing is set the system will use the default for the language


Place mathematical operators between two numbers <b>or between two template variables</b> that return a number.
TOT - shows total amounts


[+] - Example: 2 [+] 3 = 5
VAA - shows VAT amounts


[-] - Example: 5 [-] 1 = 4
VAP - shows VAT percents


[*] - Example: 3 [*] 4 = 12
VAT - VAT summary


[/] - Example: 15 [/] 5 = 3


[MIN] - Example: 2 [MIN] 3 = 2
Connect the variables with an underscore.


[MAX] - Example: 2 [MAX] 3 = 3
Examples:  


Brackets are not supported as a way to control processing order, the processing order is fixed as *, /, +, -, MIN, MAX
[INVOICE:PRI_QTY_CUA€] will create an invoice table with price and quantity in Euros.


[INVOICE:PAY_TOT_CEX] will create an invoice table which will only show payments.


=== Rounding and controlling decimal places ===
[INVOICE:PRI_QTY_CUA_TOT_VAT_QTY_PAY_GRT_AMO_VAA] will create an invoice table with more information.


==== Default ====
[INVOICE:SIN TRANSPORT] will create an invoice table with the Invoice item description for any items with the Status = Transport.


2 [/] 3 = 0.66666666666667
== Invoicee Variables ==
[INVOICEEBALANCE] - invoice balance for unassigned invoice items.


==== Rounding to the nearest integer ====
[INVOICEEBALANCENUM] - invoice balance for unassigned invoice items displayed with a decimal point and no thousands separator.


2 [/.0] 3 = 1
[INVOICEEBALANCE1234] - invoice balance for invoice items assigned to invoicee 1234 (change 1234 to the required Invoicee Id number).


==== Rounding to 1,2,3 or 4 decimal place(s) ====
[INVOICEEBALANCENUM1234] - invoice balance for invoice items assigned to invoicee 1234 (change 1234 to the required Invoicee Id number) displayed with a decimal point and no thousands separator.


2 [/.1] 3 = 0.7
[INVOICEECHARGES] - invoice charges for unassigned invoice items.


2 [/.2] 3 = 0.67
[INVOICEECHARGESNUM] - invoice charges for unassigned invoice items displayed with a decimal point and no thousands separator.


2 [/.3] 3 = 0.667
[INVOICEECHARGES1234] - invoice charges for invoice items assigned to invoicee 1234  (change 1234 to the required Invoicee Id number).


2 [/.4] 3 = 0.6667
[INVOICEECHARGESNUM1234] - invoice charges for invoice items assigned to invoicee 1234  (change 1234 to the required Invoicee Id number) displayed with a decimal point and no thousands separator.


[INVOICEEPAYMENTS] - invoice payments for unassigned invoice items.


<b>This works on all operators including [MIN] and [MAX]</b>
[INVOICEEPAYMENTSNUM] - invoice payments for unassigned invoice items displayed with a decimal point and no thousands separator.


  Note:  Always use the template variables ending with NUM. The math functions will only work with numbers with a decimal point (not a decimal comma) and no thousands separator and no currency symbol.
[INVOICEEPAYMENTS1234] - invoice payments for invoice items assigned to invoicee 1234 (change 1234 to the required Invoicee Id number)


== Currency Conversion ==
[INVOICEEPAYMENTSNUM1234] - invoice payments for invoice items assigned to invoicee 1234  (change 1234 to the required Invoicee Id number)


[CONVERT:EUR-USD] - get the actual conversion rate between two currencies, this can be used with math functions to show alternative currency values. All currencies supported by the booking page currency selector can be used.
[INVOICEENAME] - name of the invoicee account the invoice is assigned to or blank


Example: [INVOICECHARGESNUM] [*.2] [CONVERT:EUR-USD] will convert the invoice charge value from Euros to USD with two decimal points.
[INVOICEECODE] - code of the invoicee account the invoice is assigned to or blank
 
[INVOICEECURRENCY] - currency of the invoicee account the invoice is assigned to if it is not the property default or blank


If you use the multiplier to convert currencies for channels:  For example hotel id 123456 and a multiplier to convert USD to EUR at todays rate:
[INVOICEENOTES] - value of the "Notes" field for the invoicee


123456*[CONVERT:USD-EUR]*
[INVOICEETEMPLATE1] - template value 1 of the invoice account the invoice is assigned to or blank


or this to convert EUR to USD
[INVOICEETEMPLATE2] - template value 2 of the invoice account the invoice is assigned to or blank


123456*[CONVERT:EUR-USD]
[INVOICEETEMPLATE3] - template value 3 of the invoice account the invoice is assigned to or blank


123456*[CONVERT:USD-EUR][/]0.85 will convert to Euros and divides the price by 0.85 which raises it by circa 15%
[INVOICEETEMPLATE4] - template value 4 of the invoice account the invoice is assigned to or blank


==Account Variables (account of the booking) ==
[INVOICEETEMPLATE5] - template value 5 of the invoice account the invoice is assigned to or blank


[ACCOUNTID] - account id of the booked property
[INVOICEETEMPLATE6] - template value 6 of the invoice account the invoice is assigned to or blank


[ACCOUNTTEMPLATE1] - Account Template 1
[INVOICEETEMPLATE7] - template value 7 of the invoice account the invoice is assigned to or blank


[ACCOUNTTEMPLATE2] - Account Template 2
[INVOICEETEMPLATE8] - template value 8 of the invoice account the invoice is assigned to or blank


[ACCOUNTTEMPLATE3] - Account Template 3
[INVOICEETEMPLATE1BR] - template value 1 of the invoice account the invoice is assigned to or blank with linkebreak


[ACCOUNTTEMPLATE4] - Account Template 4
[INVOICEETEMPLATE2BR] - template value 2 of the invoice account the invoice is assigned to or blank with linkebreak


[COMMISSIONLIMIT] - shows the available commission amount for the owner account of the booking
[INVOICEETEMPLATE3BR] - template value 3 of the invoice account the invoice is assigned to or blank with linkebreak


[MASTERACCOUNTTEMPLATE1] - Account Template 1 from master account
[INVOICEETEMPLATE4BR] - template value 4 of the invoice account the invoice is assigned to or blank with linkebreak


[MASTERACCOUNTTEMPLATE2] - Account Template 2 from master account
[INVOICEETEMPLATE5BR] - template value 5 of the invoice account the invoice is assigned to or blank with linkebreak


[MASTERACCOUNTTEMPLATE3] - Account Template 3 from master account
[INVOICEETEMPLATE6BR] - template value 6 of the invoice account the invoice is assigned to or blank with linkebreak


[MASTERACCOUNTTEMPLATE4] - Account Template 4 from master account
[INVOICEETEMPLATE7BR] - template value 7 of the invoice account the invoice is assigned to or blank with linkebreak
 
[INVOICEETEMPLATE8BR] - template value 8 of the invoice account the invoice is assigned to or blank with linkebreak


==Account Variables (logged in account, only for display in control panel , not for auto actions or emails etc.) ==
These variables can for example used by resellers who added a custom tab to the bookings.


[LOGGEDINACCOUNTID] - account id of the logged in user
== Payment Request Variables ==
[PAYURL] - Creates a  payment url for the payment request for the amount in the booking deposit field if non zero, otherwise the outstanding balance.


[LOGGEDINACCOUNTTEMPLATE1] - Account Template 1
[PAYURL:25%] - Creates a payment url for the payment request for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance.


[LOGGEDINACCOUNTTEMPLATE2] - Account Template 2
[PAYURL:200] - Creates a payment url for the payment request url for a fixed amount. nt.


[LOGGEDINACCOUNTTEMPLATE3] - Account Template 3
[PAYLINK] - Creates a  payment link (HTML A tag) for the payment request for the amount in the booking deposit field if non zero, otherwise the outstanding balance.


[LOGGEDINACCOUNTTEMPLATE4] - Account Template 4
[PAYLINK:25%] -Creates a  payment link (HTML A tag) for the payment request for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance.


[LOGGEDINAPIKEY] - apiKey
[PAYLINK:200] - Creates a  payment link (HTML A tag) for the payment request) for a fixed amount.


[MASTERLOGGEDINACCOUNTTEMPLATE1] - Account Template 1 from master account
[PAYBUTTON] - Creates a payment button for the payment request for the amount in the booking deposit field if non zero, otherwise the outstanding balance. Not recommended for emails.


[MASTERLOGGEDINACCOUNTTEMPLATE2] - Account Template 2 from master account
[PAYBUTTON:25%] - Creates a payment button for the payment request for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance. Not recommended for emails.


[MASTERLOGGEDINACCOUNTTEMPLATE3] - Account Template 3 from master account
[PAYBUTTON:200] - Creates a payment button for the payment request for a fixed amount.


[MASTERLOGGEDINACCOUNTTEMPLATE4] - Account Template 4 from master account
[PAYPALURL] - Creates a Paypal payment url for the amount in the booking deposit field if non zero, otherwise the outstanding balance.


== Smart Logic Template Variables ==
[PAYPALURL:25%] - Creates a Paypal payment url for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance.


IF style template variables will compare two values and display a text if the comparison is true and an alternative text if the comparison is false.  
[PAYPALURL:200] - Creates a Paypal payment url for a fixed amount. A zero amount will cause paypal to provide a field to enter an amount.
Colons : are used between the two comparison values and the first text, a pipe | is used between the two texts.
 
Empty text is allowed if you do not want to display anything for a condition.
[PAYPALLINK] - Creates a Paypal payment link (HTML A tag) for the amount in the booking deposit field if non zero, otherwise the outstanding balance.
 
[PAYPALLINK:25%] - Creates a Paypal payment link (HTML A tag) for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance.
 
[PAYPALLINK:200] - Creates a Paypal payment link (HTML A tag) for a fixed amount. A zero amount will cause paypal to provide a field to enter an amount.


[IF=:if this:equals this:display this text|otherwise display this text]
[PAYPALBUTTON] - Creates a Paypal payment button for the amount in the booking deposit field if non zero, otherwise the outstanding balance. Not recommended for emails.


[IFIN:if this:is contained in this:display this text|otherwise display this text]
[PAYPALBUTTON:25%] - Creates a Paypal payment button for a percentage of the outstanding balance. Use 100% to specify the full outstanding balance. Not recommended for emails.


[IFLIKE:if this:is like this:display this text|otherwise display this text]
[PAYPALBUTTON:200] - Creates a Paypal payment button for a fixed amount. A zero amount will cause paypal to provide a field to enter an amount. Not recommended for emails.


[IF>:if this:is greater than this:display this text|otherwise display this text]
Add a H to exclude a gateway from displaying. Example: [PAYURL:200:HST] will hide Stripe


[IF>=:if this:is greater than or equal to this:display this text|otherwise display this text]
== Text Operators ==


[IF<:if this:is less than this:display this text|otherwise display this text]
[REPLACE|searchForThisText|replaceWithThisText|textToSearch] - replace "searchForThisText" with "replaceWithThisText" within the text "textToSearch"


[IF<=:if this:is less than or equal to this:display this text|otherwise display this text]


[IFBETWEEN:if this:is between this:and this:display this text|if it is lower display this text|if it is higher display this text]
[SUBSTR|startCharacterNumber|numberOfCharacters|textToGetSubstringFrom] - get a sub string from "textToGetSubstringFrom" starting at character "startCharacterNumber" (integer, 0 is the first char) with a length of "numberOfCharacters" (integer)




You can use IF variables inside other IF variables to create complex logic but the internal IF: must be processed before the external IF
1. [SUBSTR|0|4|[GUESTPHONENUM]]
They are processed in the following order from left to right so choose an internal one that is different and processed before the external one.
i.e. all the [IF=: will be processed first, then all the [IFIN: etc.


[IF=:
This will test for the first 4 characters of the Guest phone number.
[IFIN:
 
[IFLIKE:
 
[IF>:
[TRIM|  string to trim  ] - remove whitespace from the start and end of "  string to trim  "
[IF>=:
 
[IF<:
== iCal Links ==
[IF<=:
These template variables will create iCal links which allow the booking to be added to a calendar.
[IFBETWEEN:
 
[ICALURL] - Calendar link
 
[ICALURL:16] - Calendar link with check-in hour. Replace '16' with the hour check-in starts.
 
[ICALURL::10] - Calendar link with check-out hour. Replace '10' with the hour with the hour check-out ends.
 
[ICALURL:::summary text] - Calendar link with a summary text
 
[ICALURL::::description text] - Calendar link with a descriptive text
 
Example:
 
Calendar link with check-in time 16:00, check-out time 10:00, the summary text "Booking" and the description text "Sunny Hotel":
 
[ICALURL:16:10:Booking:Sunny Hotel]
 
== Mathematical Operators ==
 
Place mathematical operators between two numbers <b>or between two template variables</b> that return a number.
 
[+] - Example: 2 [+] 3 = 5
 
[-] - Example: 5 [-] 1 = 4
 
[*] - Example: 3 [*] 4 = 12
 
[/] - Example: 15 [/] 5 = 3
 
[MIN] - Example: 2 [MIN] 3 = 2
 
[MAX] - Example: 2 [MAX] 3 = 3
 
Brackets are not supported as a way to control processing order, the processing order is fixed as *, /, +, -, MIN, MAX
 
If you want to use * and - in the same calculation, for example you need 20% of the result, then you will need to use the calculation below as a * calculation will be calculated first.
 
[INVOICECHARGESNUM][*]0.2[-][INVOICESECONDITEMNUM][*]0.2[-][COMMISSIONNUM][*]0.2
 
<span style="color: #f3e504; font-size: 150%;" >{{#fas:lightbulb}} </span> Property Template 1-8 and Room Template 1-8 can be used to set calculations. If using Room Templates to make a calculation, then use Room Template 8 before Room Template 7.
 
If you want to see the value 10.
Set Room template 6 = [ROOMTEMPLATE7][+][ROOMTEMPLATE8] and enter 4 in Room template 7 and 6 in Room template 8.
 
You can set a calculation in Room Templates to show in Property Templates, but not the other way around. So "Property Template1" could pull the calculation of [ROOMTEMPLATE6] and the result = 10.
 
 
=== Rounding and controlling decimal places ===
 
==== Default ====
 
2 [/] 3 = 0.66666666666667
 
==== Rounding to the nearest integer ====
 
2 [/.0] 3 = 1
 
==== Rounding to 1,2,3 or 4 decimal place(s) ====
 
2 [/.1] 3 = 0.7
 
2 [/.2] 3 = 0.67
 
2 [/.3] 3 = 0.667
 
2 [/.4] 3 = 0.6667
 
 
<b>This works on all operators including [MIN] and [MAX]</b>
 
Note:  Always use the template variables ending with NUM. The math functions will only work with numbers with a decimal point (not a decimal comma) and no thousands separator and no currency symbol.
 
== Currency Conversion ==
 
[CONVERT:EUR-USD] - get the actual conversion rate between two currencies, this can be used with math functions to show alternative currency values. All currencies supported by the booking page currency selector can be used.
 
Example: [INVOICECHARGESNUM] [*.2]  [CONVERT:EUR-USD] will convert the invoice charge value from Euros to USD with two decimal points.
 
If you use the multiplier to convert currencies for channels:  For example hotel id 123456 and a multiplier to convert USD to EUR at todays rate:
 
123456*[CONVERT:USD-EUR]* then addition of the * at the end will convert the value back to USD when the booking is imported
 
or this to convert EUR to USD
 
123456*[CONVERT:EUR-USD]
 
123456*[CONVERT:USD-EUR][/]0.85 will convert to Euros and divides the price by 0.85 which raises it by circa 15%
 
==Account Variables (account of the booking) ==
 
[ACCOUNTUSERNAME]  - Username of the account owning the booking
 
[LOGGEDINACCOUNTUSERNAME]  - Username of the person logged in
 
[ACCOUNTID] - account id of the booked property
 
[ACCOUNTTEMPLATE1] - Account Template 1
 
[ACCOUNTTEMPLATE2] - Account Template 2
 
[ACCOUNTTEMPLATE3] - Account Template 3
 
[ACCOUNTTEMPLATE4] - Account Template 4
 
[COMMISSIONLIMIT] - shows the available commission amount for the owner account of the booking
 
[MASTERACCOUNTTEMPLATE1] - Account Template 1 from master account
 
[MASTERACCOUNTTEMPLATE2] - Account Template 2 from master account
 
[MASTERACCOUNTTEMPLATE3] - Account Template 3 from master account
 
[MASTERACCOUNTTEMPLATE4] - Account Template 4 from master account
 
==Account Variables (logged in account, only for display in control panel , not for auto actions or emails etc.) ==
These variables can for example used by resellers who added a custom tab to the bookings.
 
[LOGGEDINACCOUNTID] - account id of the logged in user
 
[LOGGEDINACCOUNTTEMPLATE1] - Account Template 1
 
[LOGGEDINACCOUNTTEMPLATE2] - Account Template 2
 
[LOGGEDINACCOUNTTEMPLATE3] - Account Template 3
 
[LOGGEDINACCOUNTTEMPLATE4] - Account Template 4
 
[LOGGEDINAPIKEY] - apiKey
 
[MASTERLOGGEDINACCOUNTTEMPLATE1] - Account Template 1 from master account
 
[MASTERLOGGEDINACCOUNTTEMPLATE2] - Account Template 2 from master account
 
[MASTERLOGGEDINACCOUNTTEMPLATE3] - Account Template 3 from master account
 
[MASTERLOGGEDINACCOUNTTEMPLATE4] - Account Template 4 from master account
 
== Smart Logic Template Variables ==
 
IF style template variables will compare two values and display a text if the comparison is true and an alternative text if the comparison is false.
Colons : are used between the two comparison values and the first text, a pipe | is used between the two texts.
Empty text is allowed if you do not want to display anything for a condition.
 
[IF=:if this:equals this:display this text|otherwise display this text]
 
[IFIN:if this:is contained in this:display this text|otherwise display this text]
 
[IFLIKE:if this:is like this:display this text|otherwise display this text]
 
[IF>:if this:is greater than this:display this text|otherwise display this text]
 
[IF>=:if this:is greater than or equal to this:display this text|otherwise display this text]
 
[IF<:if this:is less than this:display this text|otherwise display this text]
 
[IF<=:if this:is less than or equal to this:display this text|otherwise display this text]
 
[IFBETWEEN:if this:is between this:and this:display this text|if it is lower display this text|if it is higher display this text]
 
 
You can use IF variables inside other IF variables to create complex logic but the internal IF: must be processed before the external IF
 
There are special versions of each IF constructed with ^ and ~ separators like [IF=^this^this^same~different]
 
<span style="color: #f3e504; font-size: 150%;" >{{#fas:lightbulb}} </span>Only one IF of each type can be used to create complex logic.
 
The special versions are processed first so should be used as the internal IF so it's result can be processed by the outer if.
 
The special versions can also be used if you expect : or | characters within your data.
 
 
 
IF's are processed in the following order.
i.e. all the [IF=^ will be processed first, then all the [IFIN^ etc.
 
[IF=^
[IFIN^
[IFLIKE^
[IF>^
[IF>=^
[IF<^
[IF<=^
[IFBETWEEN^
[IF=:
[IFIN:
[IFLIKE:
[IF>:
[IF>=:
[IF<:
[IF<=:
[IFBETWEEN:
 
 
=== Examples ===
 
Template variables can be used inside this template variable as per the examples <span style="color: #019cde">comparison in blue</span>, <span style="color: #75d5ad">positive result in green</span>, <span style="color: #fe746c">negative result in red</span>:
 
1. [<span style="color: #019cde">IF=:[GUESTNAME]</span><span style="color: #75d5ad">:Miller</span><span style="color: #75d5ad"><span style="color: #75d5ad">:yes</span> <span style="color: #fe746c">|no</span>]
 
If the guestname is Miller the text "yes" will display. If the guest name is not Miller the text "no" will display
 
2.[<span style="color: #019cde"> IF>:[NUMADULT]:2</span><span style="color: #75d5ad">:please contact us about you bedding requirements|</span>]
 
If the number of adults is higher than 2 the text"please contact us about you bedding requirements" will display. If the number of adults is lower than or equal 2 nothing will display.
 
3. [<span style="color: #019cde">IF<:[NUMADULT]:3</span><span style="color: #75d5ad">:|linen for two adults is included free of charge</span>]
 
If the number of adults is lower than 3 nothing will display. If the number of adults is  not lower than 3 the text "linen for two adults is included free of charge" will display.
 
4. [<span style="color: #019cde">IF<=:[NUMADULT]:2</span><span style="color: #75d5ad">:yes</span><span style="color: #fe746c">|no</span>]
 
5. [<span style="color: #019cde">IF>=:[NUMADULT]:2</span><span style="color: #75d5ad">:yes</span><span style="color: #fe746c">|no</span>]
 
6. [<span style="color: #019cde">IFBETWEEN:[NUMADULT]:1:3</span><span style="color: #75d5ad">:yes</span><span style="color: #fe746c">|too low|too high</span>]
 
7. [<span style="color: #019cde">IFLIKE:[GUESTTITLE]</span><span style="color: #75d5ad">:Mr:Dear</span><span style="color: #fe746c">|Hi</span>]
 
IFLIKE works like IF= except it is case insensitive and removes any spaces from the start and end of the words
 
8. [<span style="color: #019cde">IFIN:John:[GUESTFIRSTNAME]</span><span style="color: #75d5ad">:Hi John</span><span style="color: #fe746c">|Your name does not contain John?</span>]
 
If the first word is contained in the second word the first option is displayed, otherwise the second option is displayed
 
9. [<span style="color: #019cde">IFIN:CHECKIN:[BOOKINGINFOITEMS]</span><span style="color: #75d5ad">:[BOOKINGINFOCODETEXT:CHECKIN]</span><span style="color: #fe746c">|</span>]
 
If the Booking Info Code CHECKIN has been added to the booking then you will see the value in the text (date/time) otherwise blank.
 
Using multiple IF statements to display special messages :-
 
10. [<span style="color: #019cde">IFIN:DEPOSIT:[BOOKINGINFOCODES]:|[IF=:[GUESTCOUNTRY2]:AU</span><span style="color: #75d5ad">:Credit card details are required </span><span style="color: #fe746c">|A deposit is required]|No deposit is required</span>]
 
You want  to display a special message to Australians if the booking has a DEPOSIT info item code, if a deposit is required from a non Australia they get "A deposit is required" and if no deposit is required they see "No deposit is required"
 
11. [<span style="color: #019cde">IF<:[INADVANCE]:|[IFIN:TRANSFER:[BOOKINGINFOCODES]:3</span><span style="color: #75d5ad">:Payment Due Date: ASAP </span><span style="color: #fe746c">|Payment Due Date: [FIRSTNIGHT:- 30days]]|</span>]
 
You want display a special message to your guests 3 days before checkin with a Booking Info Code = TRANSFER.
 
12. [<span style="color: #019cde">IF=:[STATUS]:Confirmed:PAID|[IF<^[INADVANCE]^30</span><span style="color: #75d5ad">^Payment Due Date: As soon as possible</span><span style="color: #fe746c">~Payment Due Date: [FIRSTNIGHT:- 30 days]]</span>]
 
You want to display a special message for your guests for any bookings with Status not = Confirmed, and if the checkin date is more than 30 days in advance, then send the message with "Payment Due Date : "or that the "Payment is due As soon as possible".
 
13. [<span style="color: #019cde">IFBETWEEN:[TURNOVERDAYS]:0:3:</span><span style="color: #75d5ad">yes|</span><span style="color: #fe746c">no</span>]
 
You want to test if the days until next arrival into the same unit is between 0 and 3 days. Could be used for offering Late Checkouts or additional days to the guest where there is a gap between bookings.


14. [<span style="color: #019cde">IF>:[VACANTDAYS]:1:</span><span style="color: #75d5ad">yes|</span><span style="color: #fe746c">no</span>]


Template variables can be used inside this template variable as per the examples <span style="color: #019cde">comparison in blue</span>, <span style="color: #75d5ad">positive result in green</span>, <span style="color: #fe746c">negative result in red</span>:
You want to test if there is 1 day from the previous checkout to check in of current booking. Could be used for offering Early Checkouts or additional days to the guest where there is a gap between bookings.


1. [<span style="color: #019cde">IF=:[GUESTNAME]</span><span style="color: #75d5ad">:Miller</span><span style="color: #75d5ad"><span style="color: #75d5ad">:yes</span> <span style="color: #fe746c">|no</span>]
15. [<span style="color: #019cde">IF=:[LEAVINGDAY:{%a}]:Sun:|[IF>=^[TURNOVERDAYS]^1</span><span style="color: #75d5ad">^yes</span><span style="color: #fe746c">~no]</span>]


If the guestname is Miller the text "yes" will display. If the guest name is not Miller the text "no" will display
You want to test if the leaving date is a Sunday and it there is a gap for 1 or more days between the current booking and the next booking.


2.[<span style="color: #019cde"> IF>:[NUMADULT]:2</span><span style="color: #75d5ad">:please contact us about you bedding requirements|</span>]
16. [<span style="color: #019cde">IF=:[LEAVINGDAY:{%u}]:1:yes|[IF=^[LEAVINGDAY:{%u}]^3</span><span style="color: #75d5ad">^yes</span><span style="color: #fe746c">]</span>]


If the number of adults is higher than 2 the text"please contact us about you bedding requirements" will display. If the number of adults is lower than or equal 2 nothing will display.
You want to test if the leaving date is a Monday or a Wednesday to send a specific message to the guest, for example a reminder that it is bin collection day.
 
3. [<span style="color: #019cde">IF<:[NUMADULT]:3</span><span style="color: #75d5ad">:|linen for two adults is included free of charge</span>]


If the number of adults is lower than 3 nothing will display. If the number of adults is  not lower than 3 the text "linen for two adults is included free of charge" will display.
17. [<span style="color: #019cde">IF=:[LEAVINGDAY:{%u}]:1:yes|[IF=^[LEAVINGDAY:{%u}]^3^yes][IF=^[LEAVINGDAY:{%u}]^6</span><span style="color: #75d5ad">^yes</span><span style="color: #fe746c">]</span>]


4. [<span style="color: #019cde">IF<=:[NUMADULT]:2</span><span style="color: #75d5ad">:yes</span><span style="color: #fe746c">|no</span>]
You have different cleaning teams for different days of the week, and you want to send a message to the appropriate team if leaving date is a Monday, Wednesday or Saturday.


5. [<span style="color: #019cde">IF>=:[NUMADULT]:2</span><span style="color: #75d5ad">:yes</span><span style="color: #fe746c">|no</span>]
18. [<span style="color: #019cde">IF<^[AUTHORIZEUNTIL{%Y-%m-%d}]^[CURRENTDATEYYYY-MM-DD]^yes~</span><span style="color: #75d5ad">no</span><span style="color: #fe746c"></span>]
 
6. [<span style="color: #019cde">IFBETWEEN:[NUMADULT]:1:3</span><span style="color: #75d5ad">:yes</span><span style="color: #fe746c">|too low|too high</span>]
 
7. [<span style="color: #019cde">IFLIKE:[GUESTTITLE]</span><span style="color: #75d5ad">:Mr:Dear|Hi</span>]
 
IFLIKE works like IF= except it is case insensitive and removes any spaces from the start and end of the words
 
8. [<span style="color: #019cde">IFIN:John:[GUESTFIRSTNAME]</span><span style="color: #75d5ad">:Hi John</span><span style="color: #fe746c">|Your name does not contain John?</span>]
 
If the first word is contained in the second word the first option is displayed, otherwise the second option is displayed
 
9. [<span style="color: #019cde">IFIN:CHECKIN:[BOOKINGINFOITEMS]</span><span style="color: #75d5ad">:[BOOKINGINFOCODETEXT:CHECKIN]</span><span style="color: #fe746c">|</span>]
 
If the Booking Info Code CHECKIN has been added to the booking then you will see the value in the text (date/time) otherwise blank.


You need to test if the Stripe authorisation has expired before the end of the booking. Then you want to automate the authorisation again . You will require multiple auto actions based on the min/max stay.


== Write out the number in Words. ==


[INWORDS]  - writes out a number in words. This works in English only.  
[INWORDS]  - writes out a number in words. This works in English only.  
Line 1,522: Line 1,855:
Expamles:  
Expamles:  


[INWORDS] 10 will write out then
[INWORDS] 10 will write "ten"


[INWORDS] [INVOICEPAYMENTSNUM] will write out the invoice sum of all payments  
[INWORDS] [INVOICEPAYMENTSNUM] will write out the invoice sum of all payments  


[INWORDS] [INVOICEPAYMENTSNUM] [+] 10 will write out the invoice sum of all payments plus 10
[INWORDS] [INVOICEPAYMENTSNUM] [+] 10 will write out the invoice sum of all payments plus 10
Example: You want  to display a special message to Australians if the booking has a DEPOSIT info item code, if a deposit is required from a non Australia they get "A deposit is required" and if no deposit is required they see "No deposit is required"
[<span style="color: #019cde">IFIN:DEPOSIT:[BOOKINGINFOCODES]:I[IF=:[GUESTCOUNTRY2]:AU</span><span style="color: #75d5ad">:Credit card details are required </span><span style="color: #fe746c">|A deposit is required]|No deposit is required</span>]


== Encoding Template Variables ==  
== Encoding Template Variables ==  
Line 1,539: Line 1,868:




Note: Always use the template variables ending with NUM if numbers are involved. The math functions will only work with numbers with a decimal point (not a decimal comma) and no thousands separator and no currency symbol.
<span style="color: #f3e504; font-size: 150%;" >{{#fas:lightbulb}} </span>  Always use the template variables ending with NUM if numbers are involved. The math functions will only work with numbers with a decimal point (not a decimal comma) and no thousands separator and no currency symbol.
 
== Using Template Variables in a HTML editor ==
When using template variables that render tables, such as [INVOICETABLE], do not place them inside <nowiki><p></nowiki> (paragraph) tags. Doing so can lead to formatting issues that affect the table’s appearance.
 
We recommend inserting the template variable as usual, then clicking the </> Code view button in the editor's toolbar. Then in the code view, locate the template variable and move it outside any surrounding <nowiki><p></nowiki> tags.
 
For example, if you have this in the editor:
<code>[INVOICETABLE]</code>
You can click the <code>&lt;/&gt;</code> button to see this:
<code>&lt;p&gt;[INVOICETABLE]&lt;/p&gt;</code>
You can fix the formatting issues by changing it to this:
<code>&lt;p&gt;&lt;/p&gt;[INVOICETABLE]</code>