PcoCalendarEventQuery constructor
PcoCalendarEventQuery({
- bool includeAttachments = false,
- bool includeOwner = false,
- bool includeTags = false,
- bool includeAllRelated = false,
- String? whereApprovalStatus,
- String? whereCreatedAt,
- String? whereName,
- String? wherePercentApproved,
- String? wherePercentRejected,
- String? whereUpdatedAt,
- String? whereVisibleInChurchCenter,
- PcoCalendarEventFilter? filterBy,
- bool reverse = false,
- int perPage = 25,
- int pageOffset = 0,
- Map<
String, String> extraParams = const {}, - List<
PlanningCenterApiWhere> ? where, - Iterable<
String> filter = const <String>[], - String? order,
- Iterable<
String> include = const <String>[],
Implementation
PcoCalendarEventQuery({
/// include associated attachments
/// when true, adds `?include=attachments` to url
bool includeAttachments = false,
/// include associated owner
/// when true, adds `?include=owner` to url
bool includeOwner = false,
/// include associated tags
/// when true, adds `?include=tags` to url
bool includeTags = false,
/// when true, adds `?include=attachments,owner,tags` to url parameters
bool includeAllRelated = false,
/// Query by `approval_status`
/// query on a specific approval_status, url example: ?where[approval_status]=string
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereApprovalStatus,
/// Query by `created_at`
/// query on a specific created_at, url example: ?where[created_at]=2000-01-01T12:00:00Z
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereCreatedAt,
/// Query by `name`
/// query on a specific name, url example: ?where[name]=string
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereName,
/// Query by `percent_approved`
/// query on a specific percent_approved, url example: ?where[percent_approved]=1
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? wherePercentApproved,
/// Query by `percent_rejected`
/// query on a specific percent_rejected, url example: ?where[percent_rejected]=1
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? wherePercentRejected,
/// Query by `updated_at`
/// query on a specific updated_at, url example: ?where[updated_at]=2000-01-01T12:00:00Z
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereUpdatedAt,
/// Query by `visible_in_church_center`
/// query on a specific visible_in_church_center, url example: ?where[visible_in_church_center]=true
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereVisibleInChurchCenter,
PcoCalendarEventFilter? filterBy,
/// reverse the ordering
bool reverse = false,
// direct access to super class params
super.perPage,
super.pageOffset,
super.extraParams,
super.where,
super.filter,
super.order,
super.include,
}) : super() {
if (filterBy != null) filter.add(filterString(filterBy));
if (includeAllRelated || includeAttachments) include.add('attachments');
if (includeAllRelated || includeOwner) include.add('owner');
if (includeAllRelated || includeTags) include.add('tags');
if (whereApprovalStatus != null)
where.add(
PlanningCenterApiWhere.parse('approval_status', whereApprovalStatus));
if (whereCreatedAt != null)
where.add(PlanningCenterApiWhere.parse('created_at', whereCreatedAt));
if (whereName != null)
where.add(PlanningCenterApiWhere.parse('name', whereName));
if (wherePercentApproved != null)
where.add(PlanningCenterApiWhere.parse(
'percent_approved', wherePercentApproved));
if (wherePercentRejected != null)
where.add(PlanningCenterApiWhere.parse(
'percent_rejected', wherePercentRejected));
if (whereUpdatedAt != null)
where.add(PlanningCenterApiWhere.parse('updated_at', whereUpdatedAt));
if (whereVisibleInChurchCenter != null)
where.add(PlanningCenterApiWhere.parse(
'visible_in_church_center', whereVisibleInChurchCenter));
}