items
Returns an array of serviceOptionsAndVariants
items that match the query.
Description
items
contains the current page of results retrieved by the query.
If no results match the query, items
is an empty array.
The page size is defined by the limit()
function and can be retrieved using the pageSize
property. You can use the next()
and prev()
functions returned by serviceOptionsAndVariants
to navigate the pages of a query result.
Type:
NAME
TYPE
DESCRIPTION
ID of the serviceOptionsAndVariants
object.
Price of the most expensive service variant.
Price of the cheapest service variant.
Service options. Note that currently only a single option is supported per service.
Revision number, which increments by 1 each time the serviceOptionsAndVariants
object is updated.
To prevent conflicting changes,
the current revision must be passed when updating and deleting the serviceOptionsAndVariants
object.
Ignored when creating a serviceOptionsAndVariants
object.
ID of the service related to these options and variants.
Information about the service's variants.
Was this helpful?
items
from a query result1const returnedItems = results.items;2
items
from the result1import { serviceOptionsAndVariants } from 'wix-bookings.v2';23export async function myQueryFunction() {4 const results = await serviceOptionsAndVariants5 .queryServiceOptionsAndVariants()6 .find();78 const returnedItems = results.items;910 if (returnedItems.length > 0) {11 return items;12 } else {13 // Handle if no matching items found14 }15}16