Template Variables: Difference between revisions
Jump to navigation
Jump to search
| (4 intermediate revisions by 2 users not shown) | |||
| Line 274: | 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] - | [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 758: | Line 758: | ||
[CANCELLEDTIME] - date when the booking was cancelled | [CANCELLEDTIME] - date when the booking was cancelled | ||
[CANCELLEDTIME:{%A, %e %B, %Y}] - date when the booking was cancelled | [CANCELLEDTIME:{%A, %e %B, %Y}] - date when the booking was cancelled | ||
[CANCELURL] - URL to view and cancel bookings | [CANCELURL] - URL to view and cancel bookings | ||
| Line 790: | Line 790: | ||
[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. | [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. | ||
[CURRENTTIME] - current time | [CURRENTTIME] - current time. | ||
[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. | [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. | ||
| Line 818: | Line 818: | ||
[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. | [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. | ||
[MODIFYDATE:{%A, %e %B, %Y}] - last booking modification date/time | [MODIFYDATE:{%A, %e %B, %Y}] - last booking modification date/time. | ||
[PAYMENTDATE:{%A, %e %B, %Y}] - most recent payment date | [PAYMENTDATE:{%A, %e %B, %Y}] - most recent payment date | ||
| Line 833: | Line 833: | ||
The following codes can be used in any order between the {} brackets to create custom time and date formats. | The following codes can be used in any order between the {} brackets to create custom time and date formats. | ||
%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 ("%") | |||
== Booking Group variables == | == Booking Group variables == | ||
| Line 1,053: | Line 1,035: | ||
[INVOICEDATES] - invoice date invoice number if invoicees are involved | [INVOICEDATES] - invoice date invoice number if invoicees are involved | ||
[INVOICEDATE:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days | [INVOICEDATE:+1day{%A, %e %B, %Y}] - optional date offset and display format. The offset can be any plus or minus any number of days. | ||
[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 | [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. | ||
=== Invoice Values === | === Invoice Values === | ||
| Line 1,180: | Line 1,162: | ||
[INVOICEPENDPAYNEXTDATE] - date of the next pending payment | [INVOICEPENDPAYNEXTDATE] - date of the next pending payment | ||
[INVOICEPENDPAYNUM] - all (auto and manual) pending payments including failed but the value is displayed with a decimal point and no thousands separator (for calculation). | [INVOICEPENDPAYNUM] - all (auto and manual) pending payments including failed but the value is displayed with a decimal point and no thousands separator (for calculation). | ||
| Line 1,684: | Line 1,664: | ||
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: | 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]* | 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 | or this to convert EUR to USD | ||
| Line 1,894: | Line 1,874: | ||
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. | 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></></code> button to see this: | |||
<code><p>[INVOICETABLE]</p></code> | |||
You can fix the formatting issues by changing it to this: | |||
<code><p></p>[INVOICETABLE]</code> | |||