getAllFromCheckInAndLocation static method
Future<PcoCollection<PcoCheckInsOption> >
getAllFromCheckInAndLocation(
- String checkInId,
- String locationId, {
- String? id,
- PcoCheckInsOptionQuery? query,
- bool includeLabel = false,
Will get a PcoCollection
containing ALL PcoCheckInsOption objects (expecting many)
using a path like this: /check-ins/v2/check_ins/$checkInId/locations/$locationId/options
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<PcoCheckInsOption>> getAllFromCheckInAndLocation(
String checkInId,
String locationId, {
String? id,
PcoCheckInsOptionQuery? query,
bool includeLabel = false,
}) async {
query ??= PcoCheckInsOptionQuery();
query.getAll = true;
if (includeLabel) query.include.add('label');
var url =
'/check-ins/v2/check_ins/$checkInId/locations/$locationId/options';
if (id != null) url += '/$id';
return PcoCollection.fromApiCall<PcoCheckInsOption>(url,
query: query, apiVersion: kApiVersion);
}