getEventQueryFromType

Function

Get the events query based on type.

  • getEventQueryFromType(type: "upcoming" | "past" | "cancelled" | "draft", options: IQueryFeaturesOptions) : IQueryFeaturesOptions

Parameters

Parameter Type Default Notes
type Required "upcoming" | "past" | "cancelled" | "draft"

string to indicate event type with the options upcoming, past, cancelled and draft

options Required IQueryFeaturesOptions

query features request options

Returns

an IQueryFeaturesOptions that has the same values as options but for the modified Where and OrderBy properties

IQueryFeaturesOptions

Function defined in events/src/util.ts:82