Package Price
The package_price tag fetches predicted price information for a package based on a selected date, time, and adult count.
The package_price tag fetches predicted price information for a package based on a selected date, time, and adult count.
This tag is particularly useful for sum-total packages that hide their individual item prices. It allows a theme to display the predicted full package price without exposing the prices of each included item. However, it can also be used for regular sum-priced packages - in this case, it will return only the sum cost of included items.
How package pricing is calculated
The package_price tag calculates the package price by:
- Summing the price of included package items.
- Predicting the price of required steps using each step's merchandising item (if individual element prices are obscured).
- Applying the selected date, time, and adult count where relevant.
Required step conditions
A required step is included in the package price when:
- The step has a merchandising item defined.
- Accommodation steps have required nights defined.
For accommodation steps, occupancy is determined by the step configuration:
- If Require that customers select accommodation for every guest is enabled, the package's adult count is used.
- Otherwise, the variant's minimum occupancy is used.
This tag does not support custom-priced packages and will raise a Liquid error if this tag is rendered with one.
Parameters
| Parameter | Required | Description |
|---|---|---|
package | ✓ | The package to fetch the price for. |
adult_count | ✓ | Number of guests for the package. |
start_date | Selected start date when the package is multi-date. | |
start_time | Selected start time for the package. | |
number_of_nights | Required nights for per-night pricing display. |
input
{% package_price package, adult_count: 2, start_date: "2024-04-15", start_time: "11:00" %}
Price: {{ result.price.fractional | money }}
Fees: {{ result.fees.fractional | money }}
Price with fees: {{ result.price_with_fees.fractional | money }}
{% endpackage_price %}output
Price: £100.00
Fees: £20.00
Price with fees: £120.00