getAllFromPersonAndBlockout static method

Future<PcoCollection<PcoServicesBlockoutException>> getAllFromPersonAndBlockout(
  1. String personId,
  2. String blockoutId, {
  3. String? id,
  4. PcoServicesBlockoutExceptionQuery? query,
})

Will get a PcoCollection containing ALL PcoServicesBlockoutException objects (expecting many) using a path like this: /services/v2/people/$personId/blockouts/$blockoutId/blockout_exceptions

Additional options may be specified by using the query argument, but some query options are also available as boolean flags in this function call too.

This function forces the query.getAll to be true.

Implementation

static Future<PcoCollection<PcoServicesBlockoutException>>
    getAllFromPersonAndBlockout(
  String personId,
  String blockoutId, {
  String? id,
  PcoServicesBlockoutExceptionQuery? query,
}) async {
  query ??= PcoServicesBlockoutExceptionQuery();
  query.getAll = true;

  var url =
      '/services/v2/people/$personId/blockouts/$blockoutId/blockout_exceptions';
  if (id != null) url += '/$id';
  return PcoCollection.fromApiCall<PcoServicesBlockoutException>(url,
      query: query, apiVersion: kApiVersion);
}