bug fixes

merge-requests/369/head
Sultan Khan 5 years ago
parent c6adc888ac
commit 1ac94d9ec8

@ -53,6 +53,9 @@ const GET_PRESCRIPTION_REPORT =
const GT_MY_PATIENT_QUESTION = const GT_MY_PATIENT_QUESTION =
'Services/DoctorApplication.svc/REST/GtMyPatientsQuestions'; 'Services/DoctorApplication.svc/REST/GtMyPatientsQuestions';
const PRM_SEARCH_PATIENT =
'Services/Patients.svc/REST/GetPatientInformation_PRM';
const GET_PATIENT = 'Services/DoctorApplication.svc/REST/'; const GET_PATIENT = 'Services/DoctorApplication.svc/REST/';
const GET_PRESCRIPTION_REPORT_FOR_IN_PATIENT = const GET_PRESCRIPTION_REPORT_FOR_IN_PATIENT =

@ -87,13 +87,18 @@ class PatientService extends BaseService {
ClinicByProjectIdRequest(); ClinicByProjectIdRequest();
ReferToDoctorRequest _referToDoctorRequest; ReferToDoctorRequest _referToDoctorRequest;
Future<dynamic> getPatientList( patient, patientType) async { Future<dynamic> getPatientList(patient, patientType, {isView}) async {
hasError = false; hasError = false;
int val = int.parse(patientType); int val = int.parse(patientType);
var url;
if (isView == false && patientType == '1') {
url = PRM_SEARCH_PATIENT;
} else {
url = GET_PATIENT + SERVICES_PATIANT[val];
}
dynamic localRes; dynamic localRes;
await baseAppClient.post( await baseAppClient.post(
GET_PATIENT + SERVICES_PATIANT[val], url,
onSuccess: (dynamic response, int statusCode) { onSuccess: (dynamic response, int statusCode) {
localRes = response; localRes = response;
}, },
@ -101,28 +106,30 @@ class PatientService extends BaseService {
hasError = true; hasError = true;
super.error = error; super.error = error;
}, },
body:val ==7?patient: { body: val == 7
"ProjectID": patient.ProjectID, ? patient
"ClinicID": patient.ClinicID, : {
"DoctorID": patient.DoctorID, "ProjectID": patient.ProjectID,
"FirstName": patient.FirstName, "ClinicID": patient.ClinicID,
"MiddleName": patient.MiddleName, "DoctorID": patient.DoctorID,
"LastName": patient.LastName, "FirstName": patient.FirstName,
"PatientMobileNumber": patient.PatientMobileNumber, "MiddleName": patient.MiddleName,
"PatientIdentificationID": patient.PatientIdentificationID, "LastName": patient.LastName,
"PatientID": patient.PatientID, "PatientMobileNumber": patient.PatientMobileNumber,
"From": patient.From, "PatientIdentificationID": patient.PatientIdentificationID,
"To": patient.To, "PatientID": patient.PatientID,
"LanguageID": patient.LanguageID, "From": patient.From,
"stamp": patient.stamp, "To": patient.To,
"IPAdress": patient.IPAdress, "LanguageID": patient.LanguageID,
"VersionID": patient.VersionID, "stamp": patient.stamp,
"Channel": patient.Channel, "IPAdress": patient.IPAdress,
"TokenID": patient.TokenID, "VersionID": patient.VersionID,
"SessionID": patient.SessionID, "Channel": patient.Channel,
"IsLoginForDoctorApp": patient.IsLoginForDoctorApp, "TokenID": patient.TokenID,
"PatientOutSA": patient.PatientOutSA "SessionID": patient.SessionID,
}, "IsLoginForDoctorApp": patient.IsLoginForDoctorApp,
"PatientOutSA": patient.PatientOutSA
},
); );
return Future.value(localRes); return Future.value(localRes);

Loading…
Cancel
Save