toMap method

Map<String, dynamic> toMap()

Implementation

Map<String, dynamic> toMap() => <String, dynamic>{
  "id": id,
  "detail1": detail1,
  "detail2": detail2,
  "addTags": addTags == null ? <dynamic>[] : List<dynamic>.from(addTags!.map((int x) => x)),
  "removeTags": removeTags == null ? <dynamic>[] : List<dynamic>.from(removeTags!.map((int x) => x)),
  "tags": tags == null ? <dynamic>[] : List<dynamic>.from(tags!.map((int x) => x)),
  "title": title,
  "cityCode": cityCode,
  "stars": stars,
  "address": address,
  "phoneNumber": phoneNumber,
  "email": email,
  "description": description,
  "policies": policies,
  "checkInTime": checkInTime,
  "checkOutTime": checkOutTime,
  "amenities": amenities == null ? null : List<dynamic>.from(amenities!.map((String x) => x)),
  "adminUserIds": adminUserIds == null ? <dynamic>[] : List<dynamic>.from(adminUserIds!.map((String x) => x)),
  "addAdminUserIds": addAdminUserIds == null ? <dynamic>[] : List<dynamic>.from(addAdminUserIds!.map((String x) => x)),
  "removeAdminUserIds": removeAdminUserIds == null ? <dynamic>[] : List<dynamic>.from(removeAdminUserIds!.map((String x) => x)),
};