class PhotoSpecialServiceScheduleModel {
  int? photoOfficeID;
  String? fromDate;
  String? toDate;
  int? photoOfficeAppointmentScheduleID;
  String? photoOfficeName;
  String? description;
  String? areaName;
  String? latitude;
  String? longitude;
  int? distanceKM;
  int? totalItemsCount;
  List<PhotoOfficeScheduleSlots>? photoOfficeScheduleSlots;

  PhotoSpecialServiceScheduleModel(
      {this.photoOfficeID,
      this.fromDate,
      this.toDate,
      this.photoOfficeAppointmentScheduleID,
      this.photoOfficeName,
      this.description,
      this.areaName,
      this.latitude,
      this.longitude,
      this.distanceKM,
      this.totalItemsCount,
      this.photoOfficeScheduleSlots});

  PhotoSpecialServiceScheduleModel.fromJson(Map<String, dynamic> json) {
    photoOfficeID = json['photoOfficeID'];
    fromDate = json['fromDate'];
    toDate = json['toDate'];
    photoOfficeAppointmentScheduleID = json['photoOfficeAppointmentScheduleID'];
    photoOfficeName = json['photoOfficeName'];
    description = json['description'];
    areaName = json['areaName'];
    latitude = json['latitude'];
    longitude = json['longitude'];
    distanceKM = json['distanceKM'];
    totalItemsCount = json['totalItemsCount'];
    if (json['photoOfficeScheduleSlots'] != null) {
      photoOfficeScheduleSlots = <PhotoOfficeScheduleSlots>[];
      json['photoOfficeScheduleSlots'].forEach((v) {
        photoOfficeScheduleSlots!.add(PhotoOfficeScheduleSlots.fromJson(v));
      });
    }
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = <String, dynamic>{};
    data['photoOfficeID'] = photoOfficeID;
    data['fromDate'] = fromDate;
    data['toDate'] = toDate;
    data['photoOfficeAppointmentScheduleID'] = photoOfficeAppointmentScheduleID;
    data['photoOfficeName'] = photoOfficeName;
    data['description'] = description;
    data['areaName'] = areaName;
    data['latitude'] = latitude;
    data['longitude'] = longitude;
    data['distanceKM'] = distanceKM;
    data['totalItemsCount'] = totalItemsCount;
    if (photoOfficeScheduleSlots != null) {
      data['photoOfficeScheduleSlots'] = photoOfficeScheduleSlots!.map((v) => v.toJson()).toList();
    }
    return data;
  }
}

class PhotoOfficeScheduleSlots {
  int? id;
  String? slotDate;
  String? startTime;
  String? endTime;

  PhotoOfficeScheduleSlots({this.id, this.slotDate, this.startTime, this.endTime});

  PhotoOfficeScheduleSlots.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    slotDate = json['slotDate'];
    startTime = json['startTime'];
    endTime = json['endTime'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = <String, dynamic>{};
    data['id'] = id;
    data['slotDate'] = slotDate;
    data['startTime'] = startTime;
    data['endTime'] = endTime;
    return data;
  }
}
