toMap method
Implementation
Map<String, dynamic> toMap() => {
"id": id,
"business_name": businessName,
"business_address": businessAddress,
"city": city,
"state": state,
"country": country,
"latitude": latitude,
"longitude": longitude,
"postal_code": postalCode,
"business_description": businessDescription,
"business_image": businessImage,
"business_type": businessType == null ? [] : List<dynamic>.from(businessType!.map((x) => x.toJson())),
"status": status,
"music_type_display": musicTypeDisplay,
"music_type_list": musicTypeList == null ? [] : List<dynamic>.from(musicTypeList!.map((x) => x.toMap())),
"tags": tags == null ? [] : List<dynamic>.from(tags!.map((x) => x)),
"gallery_attachment_array": galleryAttachmentArray == null ? [] : List<dynamic>.from(galleryAttachmentArray!.map((x) => x.toJson())),
"user_id": userId,
"business_id": businessId,
"review": review,
"description": description,
"impressed_by": impressedBy,
"created_at": createdAt,
"rating": rating,
"review_attachment": reviewAttachment == null ? [] : List<dynamic>.from(reviewAttachment!.map((x) => x.toJson())),
"captions": captions,
"attachment": attachment == null ? [] : List<dynamic>.from(attachment!.map((x) => x.toJson())),
};