import 'package:hmg_patient_app/uitl/date_uitl.dart';
class List_BloodGroupDetailsModel {
  int? iD;
  int? patientID;
  int? patientType;
  bool? patientOutSA;
  int? zipCode;
  String? cellNumber;
  String? cityCode;
  String? city;
  int? gender;
  String? bloodGroup;
  String? nationalID;
  bool? isActive;
  int? createdBy;
  DateTime? createdOn;
  int? editedBy;
  DateTime? editedOn;

  List_BloodGroupDetailsModel(
      {this.iD,
        this.patientID,
        this.patientType,
        this.patientOutSA,
        this.zipCode,
        this.cellNumber,
        this.cityCode,
        this.city,
        this.gender,
        this.bloodGroup,
        this.nationalID,
        this.isActive,
        this.createdBy,
        this.createdOn,
        this.editedBy,
        this.editedOn});

  List_BloodGroupDetailsModel.fromJson(Map<String, dynamic> json) {
    iD = json['ID'];
    patientID = json['PatientID'];
    patientType = json['PatientType'];
    patientOutSA = json['PatientOutSA'];
    zipCode = json['ZipCode'];
    cellNumber = json['CellNumber'];
    cityCode = json['CityCode'];
    city = json['City'];
    gender = json['Gender'];
    bloodGroup = json['BloodGroup'];
    nationalID = json['NationalID'];
    isActive = json['IsActive'];
    createdBy = json['CreatedBy'];
    createdOn = DateUtil.convertStringToDate(json['CreatedOn']);// json['CreatedOn'];
    editedBy = json['EditedBy'];
    editedOn = DateUtil.convertStringToDate(json['EditedOn']);//json['EditedOn'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['ID'] = this.iD;
    data['PatientID'] = this.patientID;
    data['PatientType'] = this.patientType;
    data['PatientOutSA'] = this.patientOutSA;
    data['ZipCode'] = this.zipCode;
    data['CellNumber'] = this.cellNumber;
    data['CityCode'] = this.cityCode;
    data['City'] = this.city;
    data['Gender'] = this.gender;
    data['BloodGroup'] = this.bloodGroup;
    data['NationalID'] = this.nationalID;
    data['IsActive'] = this.isActive;
    data['CreatedBy'] = this.createdBy;
    data['CreatedOn'] = this.createdOn;
    data['EditedBy'] = this.editedBy;
    data['EditedOn'] = this.editedOn;
    return data;
  }
}