PcoPeopleListQuery constructor
PcoPeopleListQuery({
- bool includeCampus = false,
- bool includeCategory = false,
- bool includeCreatedBy = false,
- bool includeMailchimpSyncStatus = false,
- bool includePeople = false,
- bool includeRules = false,
- bool includeUpdatedBy = false,
- bool includeAllRelated = false,
- String? whereBatchCompletedAt,
- String? whereCreatedAt,
- String? whereId,
- String? whereName,
- String? whereUpdatedAt,
- PcoPeopleListFilter? filterBy,
- PcoPeopleListOrder? orderBy,
- 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
PcoPeopleListQuery({
/// include associated campus
/// when true, adds `?include=campus` to url
bool includeCampus = false,
/// include associated category
/// when true, adds `?include=category` to url
bool includeCategory = false,
/// include associated created_by
/// when true, adds `?include=created_by` to url
bool includeCreatedBy = false,
/// include associated mailchimp_sync_status
/// when true, adds `?include=mailchimp_sync_status` to url
bool includeMailchimpSyncStatus = false,
/// include associated people
/// when true, adds `?include=people` to url
bool includePeople = false,
/// include associated rules
/// when true, adds `?include=rules` to url
bool includeRules = false,
/// include associated shares
/// when true, adds `?include=shares` to url
bool includeShares = false,
/// include associated updated_by
/// when true, adds `?include=updated_by` to url
bool includeUpdatedBy = false,
/// when true, adds `?include=campus,category,created_by,mailchimp_sync_status,people,rules,shares,updated_by` to url parameters
bool includeAllRelated = false,
/// Query by `batch_completed_at`
/// query on a specific batch_completed_at, url example: ?where[batch_completed_at]=2000-01-01T12:00:00Z
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereBatchCompletedAt,
/// 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 `id`
/// query on a specific id, url example: ?where[id]=primary_key
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereId,
/// 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 `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,
PcoPeopleListFilter? filterBy,
PcoPeopleListOrder? orderBy,
/// 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 || includeCampus) include.add('campus');
if (includeAllRelated || includeCategory) include.add('category');
if (includeAllRelated || includeCreatedBy) include.add('created_by');
if (includeAllRelated || includeMailchimpSyncStatus)
include.add('mailchimp_sync_status');
if (includeAllRelated || includePeople) include.add('people');
if (includeAllRelated || includeRules) include.add('rules');
if (includeAllRelated || includeShares) include.add('shares');
if (includeAllRelated || includeUpdatedBy) include.add('updated_by');
if (whereBatchCompletedAt != null)
where.add(PlanningCenterApiWhere.parse(
'batch_completed_at', whereBatchCompletedAt));
if (whereCreatedAt != null)
where.add(PlanningCenterApiWhere.parse('created_at', whereCreatedAt));
if (whereId != null) where.add(PlanningCenterApiWhere.parse('id', whereId));
if (whereName != null)
where.add(PlanningCenterApiWhere.parse('name', whereName));
if (whereUpdatedAt != null)
where.add(PlanningCenterApiWhere.parse('updated_at', whereUpdatedAt));
if (orderBy != null) order = orderString(orderBy, reverse: reverse);
}