toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final json = <String, dynamic>{};
  if (this.checkInDate != null) {
    json[r'checkInDate'] = _dateFormatter.format(this.checkInDate!);
  } else {
    json[r'checkInDate'] = null;
  }
  if (this.checkOutDate != null) {
    json[r'checkOutDate'] = _dateFormatter.format(this.checkOutDate!);
  } else {
    json[r'checkOutDate'] = null;
  }
    json[r'requestedRooms'] = this.requestedRooms;
  if (this.hotel != null) {
    json[r'hotel'] = this.hotel;
  } else {
    json[r'hotel'] = null;
  }
  if (this.terms != null) {
    json[r'terms'] = this.terms;
  } else {
    json[r'terms'] = null;
  }
  if (this.rate != null) {
    json[r'rate'] = this.rate;
  } else {
    json[r'rate'] = null;
  }
  return json;
}