toJson method

  1. @override
Map<String, Object?> toJson()

Implementation

@override
Map<String, Object?> toJson() => {
      if (about != null) "about": encodeValue(about),
      if (customData != null) "custom_data": encodeValue(customData),
      if (reference != null) "reference": encodeValue(reference),
      if (taxCode != null) "tax_code": encodeValue(taxCode),
      "name": encodeValue(name),
      "price": encodeValue(price),
      "quantity": encodeValue(quantity),
      "type": encodeValue(type),
    };