getAll static method

Will get a PcoCollection containing ALL PcoServicesReportTemplate objects (expecting many) using a path like this: /services/v2/report_templates

Available Query Filters:

  • matrix
  • people
  • plans
  • without_defaults

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<PcoServicesReportTemplate>> getAll({
  String? id,
  PcoServicesReportTemplateQuery? query,
}) async {
  query ??= PcoServicesReportTemplateQuery();
  query.getAll = true;

  var url = '/services/v2/report_templates';
  if (id != null) url += '/$id';
  return PcoCollection.fromApiCall<PcoServicesReportTemplate>(url,
      query: query, apiVersion: kApiVersion);
}