User Tools

Site Tools


leon:airport-fees-query-language

'Airport Fees' Query Language

'Airport fees' with query language options

Creating conditions for applicable prices under the 'Airport Fees' is possible using the 'Query Language' (QL).

The query language allows the creation of conditions applicable to each price of the Airport Fees pricelist and apply the prices that meet the criteria of conditions.


How it works

To create the conditions using the QL the following steps have to be performed:

Example of 'Airport Fees Query Language'
  • Click on the icon located by the price of selected item
  • In the Airport Fees Query Language pop-up window create the conditions according to the available documentation:
    • Name - name of each condition
    • Expression - a condition created using the QL
    • Price - price applicable to each condition
    • +/- - option to add and remove the lines with the conditions
    • Click on 'APPLY' to apply changes
  • Click on 'SAVE' to save the updates to the Airport Fees pricelist and the newly created conditions

Additionally, within the Airport Fees Query Language pop-up window the Documentation is available.

The documentation contains Basic examples with the link to the Expressions language page, as well as variables that can be used within the 'Expressions'.

Operators

The following operators can be used when creating the expressions:

  1. Logical operators
    • not or !
    • and or &&
    • or or ||
  2. Comparison Operators
    • == (equal)
    • === (identical)
    • != (not equal)
    • !== (not identical)
    • < (less than)
    • > (greater than)
    • (less than or equal to)
    • >= (greater than or equal to)
    • matches (regex match)
    • contains
    • starts with
    • ends with

For more information on the expressions, go to Expressions language page.

EXAMPLE

Example of the condition
Calculation in the Quote

Settings

The screenshot on the right-hand side presents an example of Query Language applied in the 'Expression':

  • Default price for the Extra high fuel cost fee is set to $1000
  • The price in the Query Language expression is set to $2500 subject to the following condition:
    • The number of PAX on the flight has to be less than 10, and
    • Flight time needs to be greater than 2 hours

Calculations

The example on the right-hand side presents 3 flights within the request:

  1. LTN - WAW - FERRY flight with 01:59 flight time
  2. WAW - JFK - flight with 2 pax and 10:38 flight time
  3. JFK - WAW - FERRY flight with 09:55 flight time

Based on the Query Language expression, Flight 1 does not meet the criteria of minimum flight time required and the default price of $1000 is applied to LTN. Flights 2 and 3 meet both criteria and the prices of $2500 are applied to both WAW and JFK airports.


leon/airport-fees-query-language.txt · Last modified: 2024/12/18 11:07 (external edit)