getAllFromDonation static method
Future<PcoCollection<PcoGivingLabel> >
getAllFromDonation(
- String donationId, {
- String? id,
- PcoGivingLabelQuery? query,
Will get a PcoCollection
containing ALL PcoGivingLabel objects (expecting many)
using a path like this: /giving/v2/donations/$donationId/labels
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<PcoGivingLabel>> getAllFromDonation(
String donationId, {
String? id,
PcoGivingLabelQuery? query,
}) async {
query ??= PcoGivingLabelQuery();
query.getAll = true;
var url = '/giving/v2/donations/$donationId/labels';
if (id != null) url += '/$id';
return PcoCollection.fromApiCall<PcoGivingLabel>(url,
query: query, apiVersion: kApiVersion);
}