Sorting

How to sort

Sorting is the same as a regular Craft Element Query sort, except you would use one of bookings special sorting handles (see below).

WARNING

This is for sorting regular Craft elements by special bookings parameters. These will not work if you are querying availability.

Sorting Handles

bookings:nextSlot

Sort by the next available slot of the events.

{% set query = craft.products.orderBy('bookings:nextSlot asc').all() %}