login flow completion
parent
d794787459
commit
52fddc5323
@ -1,292 +1,321 @@
|
||||
import 'package:hmg_patient_app_new/core/utils/date_util.dart';
|
||||
import 'dart:convert';
|
||||
|
||||
class AuthenticatedUser {
|
||||
String? setupID;
|
||||
String? setupId;
|
||||
int? patientType;
|
||||
int? patientID;
|
||||
int? patientId;
|
||||
String? firstName;
|
||||
String? middleName;
|
||||
String? lastName;
|
||||
String? firstNameN;
|
||||
String? middleNameN;
|
||||
String? lastNameN;
|
||||
int? relationshipID;
|
||||
int? relationshipId;
|
||||
int? gender;
|
||||
String? dateofBirth;
|
||||
DateTime? dateofBirthDataTime;
|
||||
dynamic dateofBirthN;
|
||||
String? nationalityID;
|
||||
dynamic phoneResi;
|
||||
dynamic phoneOffice;
|
||||
String? nationalityId;
|
||||
String? phoneResi;
|
||||
String? phoneOffice;
|
||||
String? mobileNumber;
|
||||
dynamic faxNumber;
|
||||
String? faxNumber;
|
||||
String? emailAddress;
|
||||
dynamic bloodGroup;
|
||||
dynamic rHFactor;
|
||||
dynamic rhFactor;
|
||||
bool? isEmailAlertRequired;
|
||||
bool? isSMSAlertRequired;
|
||||
bool? isSmsAlertRequired;
|
||||
String? preferredLanguage;
|
||||
bool? isPrivilegedMember;
|
||||
dynamic memberID;
|
||||
dynamic memberId;
|
||||
dynamic expiryDate;
|
||||
dynamic isHmgEmployee;
|
||||
dynamic employeeID;
|
||||
dynamic emergencyContactName;
|
||||
dynamic emergencyContactNo;
|
||||
dynamic employeeId;
|
||||
String? emergencyContactName;
|
||||
String? emergencyContactNo;
|
||||
int? patientPayType;
|
||||
dynamic dHCCPatientRefID;
|
||||
dynamic dhccPatientRefId;
|
||||
bool? isPatientDummy;
|
||||
int? status;
|
||||
dynamic isStatusCleared;
|
||||
int? patientIdentificationType;
|
||||
String? patientIdentificationNo;
|
||||
int? projectID;
|
||||
int? infoSourceID;
|
||||
int? projectId;
|
||||
int? infoSourceId;
|
||||
dynamic address;
|
||||
int? age;
|
||||
String? ageDesc;
|
||||
int? areaID;
|
||||
int? areaId;
|
||||
int? crsVerificationStatus;
|
||||
String? crsVerificationStatusDesc;
|
||||
String? crsVerificationStatusDescN;
|
||||
int? createdBy;
|
||||
String? genderDescription;
|
||||
dynamic iR;
|
||||
dynamic iSOCityID;
|
||||
dynamic iSOCountryID;
|
||||
String? healthIdFromNhicViaVida;
|
||||
dynamic ir;
|
||||
dynamic isoCityId;
|
||||
dynamic isoCountryId;
|
||||
bool? isVerfiedFromNhic;
|
||||
List<ListPrivilege>? listPrivilege;
|
||||
dynamic marital;
|
||||
int? outSA;
|
||||
dynamic pOBox;
|
||||
dynamic occupationId;
|
||||
int? outSa;
|
||||
dynamic poBox;
|
||||
bool? receiveHealthSummaryReport;
|
||||
int? sourceType;
|
||||
dynamic strDateofBirth;
|
||||
dynamic tempAddress;
|
||||
dynamic zipCode;
|
||||
dynamic isFamily;
|
||||
dynamic cRSVerificationStatus;
|
||||
// dynamic patientPayType;
|
||||
// dynamic patientType;
|
||||
// dynamic status;
|
||||
dynamic eHealthIdField;
|
||||
dynamic authenticatedUserPatientPayType;
|
||||
dynamic authenticatedUserPatientType;
|
||||
dynamic authenticatedUserStatus;
|
||||
|
||||
AuthenticatedUser(
|
||||
{this.setupID,
|
||||
this.patientType,
|
||||
this.patientID,
|
||||
this.firstName,
|
||||
this.middleName,
|
||||
this.lastName,
|
||||
this.firstNameN,
|
||||
this.middleNameN,
|
||||
this.lastNameN,
|
||||
this.relationshipID,
|
||||
this.gender,
|
||||
this.dateofBirth,
|
||||
this.dateofBirthN,
|
||||
this.nationalityID,
|
||||
this.phoneResi,
|
||||
this.phoneOffice,
|
||||
this.mobileNumber,
|
||||
this.faxNumber,
|
||||
this.emailAddress,
|
||||
this.bloodGroup,
|
||||
this.rHFactor,
|
||||
this.isEmailAlertRequired,
|
||||
this.isSMSAlertRequired,
|
||||
this.preferredLanguage,
|
||||
this.isPrivilegedMember,
|
||||
this.memberID,
|
||||
this.expiryDate,
|
||||
this.isHmgEmployee,
|
||||
this.employeeID,
|
||||
this.emergencyContactName,
|
||||
this.emergencyContactNo,
|
||||
this.patientPayType,
|
||||
this.dHCCPatientRefID,
|
||||
this.isPatientDummy,
|
||||
this.status,
|
||||
this.isStatusCleared,
|
||||
this.patientIdentificationType,
|
||||
this.patientIdentificationNo,
|
||||
this.projectID,
|
||||
this.infoSourceID,
|
||||
this.address,
|
||||
this.age,
|
||||
this.ageDesc,
|
||||
this.areaID,
|
||||
this.createdBy,
|
||||
this.genderDescription,
|
||||
this.iR,
|
||||
this.iSOCityID,
|
||||
this.iSOCountryID,
|
||||
this.listPrivilege,
|
||||
this.marital,
|
||||
this.outSA,
|
||||
this.pOBox,
|
||||
this.receiveHealthSummaryReport,
|
||||
this.sourceType,
|
||||
this.strDateofBirth,
|
||||
this.tempAddress,
|
||||
this.zipCode,
|
||||
this.isFamily,
|
||||
this.cRSVerificationStatus});
|
||||
AuthenticatedUser({
|
||||
this.setupId,
|
||||
this.patientType,
|
||||
this.patientId,
|
||||
this.firstName,
|
||||
this.middleName,
|
||||
this.lastName,
|
||||
this.firstNameN,
|
||||
this.middleNameN,
|
||||
this.lastNameN,
|
||||
this.relationshipId,
|
||||
this.gender,
|
||||
this.dateofBirth,
|
||||
this.dateofBirthN,
|
||||
this.nationalityId,
|
||||
this.phoneResi,
|
||||
this.phoneOffice,
|
||||
this.mobileNumber,
|
||||
this.faxNumber,
|
||||
this.emailAddress,
|
||||
this.bloodGroup,
|
||||
this.rhFactor,
|
||||
this.isEmailAlertRequired,
|
||||
this.isSmsAlertRequired,
|
||||
this.preferredLanguage,
|
||||
this.isPrivilegedMember,
|
||||
this.memberId,
|
||||
this.expiryDate,
|
||||
this.isHmgEmployee,
|
||||
this.employeeId,
|
||||
this.emergencyContactName,
|
||||
this.emergencyContactNo,
|
||||
this.patientPayType,
|
||||
this.dhccPatientRefId,
|
||||
this.isPatientDummy,
|
||||
this.status,
|
||||
this.isStatusCleared,
|
||||
this.patientIdentificationType,
|
||||
this.patientIdentificationNo,
|
||||
this.projectId,
|
||||
this.infoSourceId,
|
||||
this.address,
|
||||
this.age,
|
||||
this.ageDesc,
|
||||
this.areaId,
|
||||
this.crsVerificationStatus,
|
||||
this.crsVerificationStatusDesc,
|
||||
this.crsVerificationStatusDescN,
|
||||
this.createdBy,
|
||||
this.genderDescription,
|
||||
this.healthIdFromNhicViaVida,
|
||||
this.ir,
|
||||
this.isoCityId,
|
||||
this.isoCountryId,
|
||||
this.isVerfiedFromNhic,
|
||||
this.listPrivilege,
|
||||
this.marital,
|
||||
this.occupationId,
|
||||
this.outSa,
|
||||
this.poBox,
|
||||
this.receiveHealthSummaryReport,
|
||||
this.sourceType,
|
||||
this.strDateofBirth,
|
||||
this.tempAddress,
|
||||
this.zipCode,
|
||||
this.eHealthIdField,
|
||||
this.authenticatedUserPatientPayType,
|
||||
this.authenticatedUserPatientType,
|
||||
this.authenticatedUserStatus,
|
||||
});
|
||||
|
||||
AuthenticatedUser.fromJson(Map<String, dynamic> json) {
|
||||
setupID = json['SetupID'];
|
||||
patientType = json['PatientType'];
|
||||
patientID = json['PatientID'];
|
||||
firstName = json['FirstName'];
|
||||
middleName = json['MiddleName'];
|
||||
lastName = json['LastName'];
|
||||
firstNameN = json['FirstNameN'];
|
||||
middleNameN = json['MiddleNameN'];
|
||||
lastNameN = json['LastNameN'];
|
||||
relationshipID = json['RelationshipID'];
|
||||
gender = json['Gender'];
|
||||
dateofBirth = json['DateofBirth'];
|
||||
dateofBirthDataTime = DateUtil.convertStringToDate(json['DateofBirth']);
|
||||
dateofBirthN = json['DateofBirthN'];
|
||||
nationalityID = json['NationalityID'];
|
||||
phoneResi = json['PhoneResi'];
|
||||
phoneOffice = json['PhoneOffice'];
|
||||
mobileNumber = json['MobileNumber'];
|
||||
faxNumber = json['FaxNumber'];
|
||||
emailAddress = json['EmailAddress'];
|
||||
bloodGroup = json['BloodGroup'];
|
||||
rHFactor = json['RHFactor'];
|
||||
isEmailAlertRequired = json['IsEmailAlertRequired'];
|
||||
isSMSAlertRequired = json['IsSMSAlertRequired'];
|
||||
preferredLanguage = json['PreferredLanguage'];
|
||||
isPrivilegedMember = json['IsPrivilegedMember'];
|
||||
memberID = json['MemberID'];
|
||||
expiryDate = json['ExpiryDate'];
|
||||
isHmgEmployee = json['IsHmgEmployee'];
|
||||
employeeID = json['EmployeeID'];
|
||||
emergencyContactName = json['EmergencyContactName'];
|
||||
emergencyContactNo = json['EmergencyContactNo'];
|
||||
patientPayType = json['PatientPayType'];
|
||||
dHCCPatientRefID = json['DHCCPatientRefID'];
|
||||
isPatientDummy = json['IsPatientDummy'];
|
||||
status = json['Status'];
|
||||
isStatusCleared = json['IsStatusCleared'];
|
||||
patientIdentificationType = json['PatientIdentificationType'];
|
||||
patientIdentificationNo = json['PatientIdentificationNo'];
|
||||
projectID = json['ProjectID'];
|
||||
infoSourceID = json['InfoSourceID'];
|
||||
address = json['Address'];
|
||||
age = json['Age'];
|
||||
ageDesc = json['AgeDesc'];
|
||||
areaID = json['AreaID'];
|
||||
createdBy = json['CreatedBy'];
|
||||
genderDescription = json['GenderDescription'];
|
||||
iR = json['IR'];
|
||||
iSOCityID = json['ISOCityID'];
|
||||
iSOCountryID = json['ISOCountryID'];
|
||||
if (json['ListPrivilege'] != null) {
|
||||
listPrivilege = [];
|
||||
json['ListPrivilege'].forEach((v) {
|
||||
listPrivilege!.add(new ListPrivilege.fromJson(v));
|
||||
});
|
||||
}
|
||||
marital = json['Marital'];
|
||||
outSA = json['OutSA'];
|
||||
pOBox = json['POBox'];
|
||||
receiveHealthSummaryReport = json['ReceiveHealthSummaryReport'];
|
||||
sourceType = json['SourceType'];
|
||||
strDateofBirth = json['StrDateofBirth'];
|
||||
tempAddress = json['TempAddress'];
|
||||
zipCode = json['ZipCode'];
|
||||
isFamily = json['IsFamily'];
|
||||
cRSVerificationStatus = json['CRSVerificationStatus'];
|
||||
}
|
||||
factory AuthenticatedUser.fromRawJson(String str) => AuthenticatedUser.fromJson(json.decode(str));
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['SetupID'] = this.setupID;
|
||||
data['PatientType'] = this.patientType;
|
||||
data['PatientID'] = this.patientID;
|
||||
data['FirstName'] = this.firstName;
|
||||
data['MiddleName'] = this.middleName;
|
||||
data['LastName'] = this.lastName;
|
||||
data['FirstNameN'] = this.firstNameN;
|
||||
data['MiddleNameN'] = this.middleNameN;
|
||||
data['LastNameN'] = this.lastNameN;
|
||||
data['RelationshipID'] = this.relationshipID;
|
||||
data['Gender'] = this.gender;
|
||||
data['DateofBirth'] = this.dateofBirth;
|
||||
data['DateofBirthN'] = this.dateofBirthN;
|
||||
data['NationalityID'] = this.nationalityID;
|
||||
data['PhoneResi'] = this.phoneResi;
|
||||
data['PhoneOffice'] = this.phoneOffice;
|
||||
data['MobileNumber'] = this.mobileNumber;
|
||||
data['FaxNumber'] = this.faxNumber;
|
||||
data['EmailAddress'] = this.emailAddress;
|
||||
data['BloodGroup'] = this.bloodGroup;
|
||||
data['RHFactor'] = this.rHFactor;
|
||||
data['IsEmailAlertRequired'] = this.isEmailAlertRequired;
|
||||
data['IsSMSAlertRequired'] = this.isSMSAlertRequired;
|
||||
data['PreferredLanguage'] = this.preferredLanguage;
|
||||
data['IsPrivilegedMember'] = this.isPrivilegedMember;
|
||||
data['MemberID'] = this.memberID;
|
||||
data['ExpiryDate'] = this.expiryDate;
|
||||
data['IsHmgEmployee'] = this.isHmgEmployee;
|
||||
data['EmployeeID'] = this.employeeID;
|
||||
data['EmergencyContactName'] = this.emergencyContactName;
|
||||
data['EmergencyContactNo'] = this.emergencyContactNo;
|
||||
data['PatientPayType'] = this.patientPayType;
|
||||
data['DHCCPatientRefID'] = this.dHCCPatientRefID;
|
||||
data['IsPatientDummy'] = this.isPatientDummy;
|
||||
data['Status'] = this.status;
|
||||
data['IsStatusCleared'] = this.isStatusCleared;
|
||||
data['PatientIdentificationType'] = this.patientIdentificationType;
|
||||
data['PatientIdentificationNo'] = this.patientIdentificationNo;
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['InfoSourceID'] = this.infoSourceID;
|
||||
data['Address'] = this.address;
|
||||
data['Age'] = this.age;
|
||||
data['AgeDesc'] = this.ageDesc;
|
||||
data['AreaID'] = this.areaID;
|
||||
data['CreatedBy'] = this.createdBy;
|
||||
data['GenderDescription'] = this.genderDescription;
|
||||
data['IR'] = this.iR;
|
||||
data['ISOCityID'] = this.iSOCityID;
|
||||
data['ISOCountryID'] = this.iSOCountryID;
|
||||
if (this.listPrivilege != null) {
|
||||
data['ListPrivilege'] =
|
||||
this.listPrivilege!.map((v) => v.toJson()).toList();
|
||||
}
|
||||
data['Marital'] = this.marital;
|
||||
data['OutSA'] = this.outSA;
|
||||
data['POBox'] = this.pOBox;
|
||||
data['ReceiveHealthSummaryReport'] = this.receiveHealthSummaryReport;
|
||||
data['SourceType'] = this.sourceType;
|
||||
data['StrDateofBirth'] = this.strDateofBirth;
|
||||
data['TempAddress'] = this.tempAddress;
|
||||
data['ZipCode'] = this.zipCode;
|
||||
data['IsFamily'] = this.isFamily;
|
||||
data['CRSVerificationStatus'] = this.cRSVerificationStatus;
|
||||
return data;
|
||||
}
|
||||
String toRawJson() => json.encode(toJson());
|
||||
|
||||
factory AuthenticatedUser.fromJson(Map<String, dynamic> json) => AuthenticatedUser(
|
||||
setupId: json["SetupID"],
|
||||
patientType: json["PatientType"],
|
||||
patientId: json["PatientID"],
|
||||
firstName: json["FirstName"],
|
||||
middleName: json["MiddleName"],
|
||||
lastName: json["LastName"],
|
||||
firstNameN: json["FirstNameN"],
|
||||
middleNameN: json["MiddleNameN"],
|
||||
lastNameN: json["LastNameN"],
|
||||
relationshipId: json["RelationshipID"],
|
||||
gender: json["Gender"],
|
||||
dateofBirth: json["DateofBirth"],
|
||||
dateofBirthN: json["DateofBirthN"],
|
||||
nationalityId: json["NationalityID"],
|
||||
phoneResi: json["PhoneResi"],
|
||||
phoneOffice: json["PhoneOffice"],
|
||||
mobileNumber: json["MobileNumber"],
|
||||
faxNumber: json["FaxNumber"],
|
||||
emailAddress: json["EmailAddress"],
|
||||
bloodGroup: json["BloodGroup"],
|
||||
rhFactor: json["RHFactor"],
|
||||
isEmailAlertRequired: json["IsEmailAlertRequired"],
|
||||
isSmsAlertRequired: json["IsSMSAlertRequired"],
|
||||
preferredLanguage: json["PreferredLanguage"],
|
||||
isPrivilegedMember: json["IsPrivilegedMember"],
|
||||
memberId: json["MemberID"],
|
||||
expiryDate: json["ExpiryDate"],
|
||||
isHmgEmployee: json["IsHmgEmployee"],
|
||||
employeeId: json["EmployeeID"],
|
||||
emergencyContactName: json["EmergencyContactName"],
|
||||
emergencyContactNo: json["EmergencyContactNo"],
|
||||
patientPayType: json["PatientPayType"],
|
||||
dhccPatientRefId: json["DHCCPatientRefID"],
|
||||
isPatientDummy: json["IsPatientDummy"],
|
||||
status: json["Status"],
|
||||
isStatusCleared: json["IsStatusCleared"],
|
||||
patientIdentificationType: json["PatientIdentificationType"],
|
||||
patientIdentificationNo: json["PatientIdentificationNo"],
|
||||
projectId: json["ProjectID"],
|
||||
infoSourceId: json["InfoSourceID"],
|
||||
address: json["Address"],
|
||||
age: json["Age"],
|
||||
ageDesc: json["AgeDesc"],
|
||||
areaId: json["AreaID"],
|
||||
crsVerificationStatus: json["CRSVerificationStatus"],
|
||||
crsVerificationStatusDesc: json["CRSVerificationStatusDesc"],
|
||||
crsVerificationStatusDescN: json["CRSVerificationStatusDescN"],
|
||||
createdBy: json["CreatedBy"],
|
||||
genderDescription: json["GenderDescription"],
|
||||
healthIdFromNhicViaVida: json["HealthIDFromNHICViaVida"],
|
||||
ir: json["IR"],
|
||||
isoCityId: json["ISOCityID"],
|
||||
isoCountryId: json["ISOCountryID"],
|
||||
isVerfiedFromNhic: json["IsVerfiedFromNHIC"],
|
||||
listPrivilege: json["ListPrivilege"] == null ? [] : List<ListPrivilege>.from(json["ListPrivilege"]!.map((x) => ListPrivilege.fromJson(x))),
|
||||
marital: json["Marital"],
|
||||
occupationId: json["OccupationID"],
|
||||
outSa: json["OutSA"],
|
||||
poBox: json["POBox"],
|
||||
receiveHealthSummaryReport: json["ReceiveHealthSummaryReport"],
|
||||
sourceType: json["SourceType"],
|
||||
strDateofBirth: json["StrDateofBirth"],
|
||||
tempAddress: json["TempAddress"],
|
||||
zipCode: json["ZipCode"],
|
||||
eHealthIdField: json["eHealthIDField"],
|
||||
authenticatedUserPatientPayType: json["patientPayType"],
|
||||
authenticatedUserPatientType: json["patientType"],
|
||||
authenticatedUserStatus: json["status"],
|
||||
);
|
||||
|
||||
Map<String, dynamic> toJson() => {
|
||||
"SetupID": setupId,
|
||||
"PatientType": patientType,
|
||||
"PatientID": patientId,
|
||||
"FirstName": firstName,
|
||||
"MiddleName": middleName,
|
||||
"LastName": lastName,
|
||||
"FirstNameN": firstNameN,
|
||||
"MiddleNameN": middleNameN,
|
||||
"LastNameN": lastNameN,
|
||||
"RelationshipID": relationshipId,
|
||||
"Gender": gender,
|
||||
"DateofBirth": dateofBirth,
|
||||
"DateofBirthN": dateofBirthN,
|
||||
"NationalityID": nationalityId,
|
||||
"PhoneResi": phoneResi,
|
||||
"PhoneOffice": phoneOffice,
|
||||
"MobileNumber": mobileNumber,
|
||||
"FaxNumber": faxNumber,
|
||||
"EmailAddress": emailAddress,
|
||||
"BloodGroup": bloodGroup,
|
||||
"RHFactor": rhFactor,
|
||||
"IsEmailAlertRequired": isEmailAlertRequired,
|
||||
"IsSMSAlertRequired": isSmsAlertRequired,
|
||||
"PreferredLanguage": preferredLanguage,
|
||||
"IsPrivilegedMember": isPrivilegedMember,
|
||||
"MemberID": memberId,
|
||||
"ExpiryDate": expiryDate,
|
||||
"IsHmgEmployee": isHmgEmployee,
|
||||
"EmployeeID": employeeId,
|
||||
"EmergencyContactName": emergencyContactName,
|
||||
"EmergencyContactNo": emergencyContactNo,
|
||||
"PatientPayType": patientPayType,
|
||||
"DHCCPatientRefID": dhccPatientRefId,
|
||||
"IsPatientDummy": isPatientDummy,
|
||||
"Status": status,
|
||||
"IsStatusCleared": isStatusCleared,
|
||||
"PatientIdentificationType": patientIdentificationType,
|
||||
"PatientIdentificationNo": patientIdentificationNo,
|
||||
"ProjectID": projectId,
|
||||
"InfoSourceID": infoSourceId,
|
||||
"Address": address,
|
||||
"Age": age,
|
||||
"AgeDesc": ageDesc,
|
||||
"AreaID": areaId,
|
||||
"CRSVerificationStatus": crsVerificationStatus,
|
||||
"CRSVerificationStatusDesc": crsVerificationStatusDesc,
|
||||
"CRSVerificationStatusDescN": crsVerificationStatusDescN,
|
||||
"CreatedBy": createdBy,
|
||||
"GenderDescription": genderDescription,
|
||||
"HealthIDFromNHICViaVida": healthIdFromNhicViaVida,
|
||||
"IR": ir,
|
||||
"ISOCityID": isoCityId,
|
||||
"ISOCountryID": isoCountryId,
|
||||
"IsVerfiedFromNHIC": isVerfiedFromNhic,
|
||||
"ListPrivilege": listPrivilege == null ? [] : List<dynamic>.from(listPrivilege!.map((x) => x.toJson())),
|
||||
"Marital": marital,
|
||||
"OccupationID": occupationId,
|
||||
"OutSA": outSa,
|
||||
"POBox": poBox,
|
||||
"ReceiveHealthSummaryReport": receiveHealthSummaryReport,
|
||||
"SourceType": sourceType,
|
||||
"StrDateofBirth": strDateofBirth,
|
||||
"TempAddress": tempAddress,
|
||||
"ZipCode": zipCode,
|
||||
"eHealthIDField": eHealthIdField,
|
||||
"patientPayType": authenticatedUserPatientPayType,
|
||||
"patientType": authenticatedUserPatientType,
|
||||
"status": authenticatedUserStatus,
|
||||
};
|
||||
}
|
||||
|
||||
class ListPrivilege {
|
||||
int? iD;
|
||||
int? id;
|
||||
String? serviceName;
|
||||
bool? previlege;
|
||||
dynamic region;
|
||||
|
||||
ListPrivilege({this.iD, this.serviceName, this.previlege, this.region});
|
||||
ListPrivilege({
|
||||
this.id,
|
||||
this.serviceName,
|
||||
this.previlege,
|
||||
this.region,
|
||||
});
|
||||
|
||||
factory ListPrivilege.fromRawJson(String str) => ListPrivilege.fromJson(json.decode(str));
|
||||
|
||||
String toRawJson() => json.encode(toJson());
|
||||
|
||||
ListPrivilege.fromJson(Map<String, dynamic> json) {
|
||||
iD = json['ID'];
|
||||
serviceName = json['ServiceName'];
|
||||
previlege = json['Previlege'];
|
||||
region = json['Region'];
|
||||
}
|
||||
factory ListPrivilege.fromJson(Map<String, dynamic> json) => ListPrivilege(
|
||||
id: json["ID"],
|
||||
serviceName: json["ServiceName"],
|
||||
previlege: json["Previlege"],
|
||||
region: json["Region"],
|
||||
);
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['ID'] = this.iD;
|
||||
data['ServiceName'] = this.serviceName;
|
||||
data['Previlege'] = this.previlege;
|
||||
data['Region'] = this.region;
|
||||
return data;
|
||||
}
|
||||
Map<String, dynamic> toJson() => {
|
||||
"ID": id,
|
||||
"ServiceName": serviceName,
|
||||
"Previlege": previlege,
|
||||
"Region": region,
|
||||
};
|
||||
}
|
||||
|
||||
@ -0,0 +1,73 @@
|
||||
import 'dart:convert';
|
||||
|
||||
class CommonAuthanticatedRequest {
|
||||
String? sessionId;
|
||||
double? versionId;
|
||||
int? channel;
|
||||
int? languageId;
|
||||
String? ipAdress;
|
||||
String? generalid;
|
||||
double? latitude;
|
||||
double? longitude;
|
||||
int? deviceTypeId;
|
||||
int? patientType;
|
||||
int? patientTypeId;
|
||||
String? tokenId;
|
||||
int? patientId;
|
||||
int? patientOutSa;
|
||||
|
||||
CommonAuthanticatedRequest({
|
||||
this.sessionId,
|
||||
this.versionId,
|
||||
this.channel,
|
||||
this.languageId,
|
||||
this.ipAdress,
|
||||
this.generalid,
|
||||
this.latitude,
|
||||
this.longitude,
|
||||
this.deviceTypeId,
|
||||
this.patientType,
|
||||
this.patientTypeId,
|
||||
this.tokenId,
|
||||
this.patientId,
|
||||
this.patientOutSa,
|
||||
});
|
||||
|
||||
factory CommonAuthanticatedRequest.fromRawJson(String str) => CommonAuthanticatedRequest.fromJson(json.decode(str));
|
||||
|
||||
String toRawJson() => json.encode(toJson());
|
||||
|
||||
factory CommonAuthanticatedRequest.fromJson(Map<String, dynamic> json) => CommonAuthanticatedRequest(
|
||||
sessionId: json["SessionID"],
|
||||
versionId: json["VersionID"]?.toDouble(),
|
||||
channel: json["Channel"],
|
||||
languageId: json["LanguageID"],
|
||||
ipAdress: json["IPAdress"],
|
||||
generalid: json["generalid"],
|
||||
latitude: json["Latitude"],
|
||||
longitude: json["Longitude"],
|
||||
deviceTypeId: json["DeviceTypeID"],
|
||||
patientType: json["PatientType"],
|
||||
patientTypeId: json["PatientTypeID"],
|
||||
tokenId: json["TokenID"],
|
||||
patientId: json["PatientID"],
|
||||
patientOutSa: json["PatientOutSA"],
|
||||
);
|
||||
|
||||
Map<String, dynamic> toJson() => {
|
||||
"SessionID": sessionId,
|
||||
"VersionID": versionId,
|
||||
"Channel": channel,
|
||||
"LanguageID": languageId,
|
||||
"IPAdress": ipAdress,
|
||||
"generalid": generalid,
|
||||
"Latitude": latitude,
|
||||
"Longitude": longitude,
|
||||
"DeviceTypeID": deviceTypeId,
|
||||
"PatientType": patientType,
|
||||
"PatientTypeID": patientTypeId,
|
||||
"TokenID": tokenId,
|
||||
"PatientID": patientId,
|
||||
"PatientOutSA": patientOutSa,
|
||||
};
|
||||
}
|
||||
@ -1,14 +1,17 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:hmg_patient_app_new/presentation/authentication/login.dart';
|
||||
import 'package:hmg_patient_app_new/presentation/home/landing_page.dart';
|
||||
import 'package:hmg_patient_app_new/splashPage.dart';
|
||||
|
||||
class AppRoutes {
|
||||
static const String initialRoute = '/initialRoute';
|
||||
static const String loginScreen = '/loginScreen';
|
||||
static const String registerNewScreen = '/registerNewScreen';
|
||||
static const String landingScreen = '/landingScreen';
|
||||
|
||||
static Map<String, WidgetBuilder> get routes => {
|
||||
initialRoute: (context) => SplashPage(),
|
||||
loginScreen: (context) => LoginScreen(),
|
||||
landingScreen: (context) => LandingPage(),
|
||||
};
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue