toJson method
Implementation
Map<String, dynamic> toJson() {
return {
"email": email ?? "Unknown",
"first_name": firstName ?? "Unknown",
"last_name": lastName ?? "Unknown",
"phone_number": phoneNumber ?? "Unknown",
"apartment": apartment ?? "NA",
"floor": floor ?? "NA",
"building": building ?? "NA",
"street": street ?? "NA",
"postal_code": postalCode ?? "NA",
"city": city ?? "NA",
"state": state ?? "NA",
"country": country ?? "NA",
"shipping_method": shippingMethod ?? "NA",
};
}