toJson method

Map<String, dynamic> toJson()

Converts a OrderInfo object to a JSON object

Implementation

Map<String, dynamic> toJson() {
  return {
    'name': name,
    'phone_number': phoneNumber,
    'email': email,
    'shipping_address': shippingAddress?.toJson(),
  }..removeWhere(_nullFilter);
}