class UserListEntity { String? msg; int? code; List? data; UserListEntity({this.msg, this.code, this.data}); UserListEntity.fromJson(Map json) { msg = json['msg']; code = json['code']; if (json['data'] != null) { data = []; json['data'].forEach((v) { data!.add(new Data.fromJson(v)); }); } } Map toJson() { final Map data = new Map(); data['msg'] = this.msg; data['code'] = this.code; if (this.data != null) { data['data'] = this.data!.map((v) => v.toJson()).toList(); } return data; } } class Data { String? patientId; String? userRelationship; String? patientName; String? identificationCard; int? documentType; String? allergyHistory; String? pastHistory; String? familyHistory; String? patientPhone; String? homeAddress; int? isDefault; Data( {this.patientId, this.userRelationship, this.patientName, this.identificationCard, this.documentType, this.allergyHistory, this.pastHistory, this.familyHistory, this.patientPhone, this.homeAddress, this.isDefault}); Data.fromJson(Map json) { patientId = json['patientId']; userRelationship = json['userRelationship']; patientName = json['patientName']; identificationCard = json['identificationCard']; documentType = json['documentType']; allergyHistory = json['allergyHistory']; pastHistory = json['pastHistory']; familyHistory = json['familyHistory']; patientPhone = json['patientPhone']; homeAddress = json['homeAddress']; isDefault = json['isDefault']; } Map toJson() { final Map data = new Map(); data['patientId'] = this.patientId; data['userRelationship'] = this.userRelationship; data['patientName'] = this.patientName; data['identificationCard'] = this.identificationCard; data['documentType'] = this.documentType; data['allergyHistory'] = this.allergyHistory; data['pastHistory'] = this.pastHistory; data['familyHistory'] = this.familyHistory; data['patientPhone'] = this.patientPhone; data['homeAddress'] = this.homeAddress; data['isDefault'] = this.isDefault; return data; } }