getShippingZones method

Future<List<WooShippingZone>> getShippingZones()

Implementation

Future<List<WooShippingZone>> getShippingZones() async {
  List<WooShippingZone> shippingZones = [];
  _setApiResourceUrl(path: 'shipping/zones');
  final response = await get(queryUri.toString());
  for (var z in response) {
    var sZone = WooShippingZone.fromJson(z);
    _printToLog('shipping zones gotten here : ' + sZone.toString());
    shippingZones.add(sZone);
  }
  return shippingZones;
}