Compare commits
4 Commits
developmen
...
roaa_redes
| Author | SHA1 | Date |
|---|---|---|
|
|
39b4c3d55f | 4 years ago |
|
|
99d47226d3 | 4 years ago |
|
|
486594240e | 4 years ago |
|
|
59d7fc4e76 | 4 years ago |
Binary file not shown.
|
Before Width: | Height: | Size: 38 KiB |
@ -1,25 +0,0 @@
|
||||
class DoctorErSignAssessmentReqModel {
|
||||
String setupID;
|
||||
int signInType;
|
||||
int loginDoctorID;
|
||||
int patientID;
|
||||
|
||||
DoctorErSignAssessmentReqModel(
|
||||
{this.setupID, this.signInType, this.loginDoctorID, this.patientID});
|
||||
|
||||
DoctorErSignAssessmentReqModel.fromJson(Map<String, dynamic> json) {
|
||||
setupID = json['SetupID'];
|
||||
signInType = json['SignInType'];
|
||||
loginDoctorID = json['LoginDoctorID'];
|
||||
patientID = json['PatientID'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['SetupID'] = this.setupID;
|
||||
data['SignInType'] = this.signInType;
|
||||
data['LoginDoctorID'] = this.loginDoctorID;
|
||||
data['PatientID'] = this.patientID;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,145 +0,0 @@
|
||||
class PrescriptionEntityModel {
|
||||
dynamic appointmentNo;
|
||||
dynamic clinicName;
|
||||
dynamic createdBy;
|
||||
dynamic createdOn;
|
||||
dynamic doctorName;
|
||||
dynamic doseDailyQuantity;
|
||||
dynamic doseDailyUnitID;
|
||||
dynamic doseDetail;
|
||||
dynamic doseDurationDays;
|
||||
dynamic doseTimingID;
|
||||
dynamic episodeID;
|
||||
dynamic frequencyID;
|
||||
dynamic icdCode10ID;
|
||||
dynamic indication;
|
||||
dynamic isDispensed;
|
||||
dynamic isMedicineCovered;
|
||||
dynamic isSIG;
|
||||
dynamic medicationName;
|
||||
dynamic medicationPrice;
|
||||
dynamic medicineCode;
|
||||
dynamic orderTypeDescription;
|
||||
dynamic qty;
|
||||
dynamic quantity;
|
||||
dynamic remarks;
|
||||
dynamic routeID;
|
||||
dynamic startDate;
|
||||
dynamic status;
|
||||
dynamic stopDate;
|
||||
dynamic uom;
|
||||
dynamic pharmacistRemarks;
|
||||
dynamic pharmacyInervention;
|
||||
dynamic refill;
|
||||
dynamic mediSpanGPICode;
|
||||
|
||||
PrescriptionEntityModel(
|
||||
{this.appointmentNo,
|
||||
this.clinicName,
|
||||
this.createdBy,
|
||||
this.createdOn,
|
||||
this.doctorName,
|
||||
this.doseDailyQuantity,
|
||||
this.doseDailyUnitID,
|
||||
this.doseDetail,
|
||||
this.doseDurationDays,
|
||||
this.doseTimingID,
|
||||
this.episodeID,
|
||||
this.frequencyID,
|
||||
this.icdCode10ID,
|
||||
this.indication,
|
||||
this.isDispensed,
|
||||
this.isMedicineCovered,
|
||||
this.isSIG,
|
||||
this.medicationName,
|
||||
this.medicationPrice,
|
||||
this.medicineCode,
|
||||
this.orderTypeDescription,
|
||||
this.qty,
|
||||
this.quantity,
|
||||
this.remarks,
|
||||
this.routeID,
|
||||
this.startDate,
|
||||
this.status,
|
||||
this.stopDate,
|
||||
this.uom,
|
||||
this.pharmacistRemarks,
|
||||
this.mediSpanGPICode,
|
||||
this.pharmacyInervention,
|
||||
this.refill});
|
||||
|
||||
PrescriptionEntityModel.fromJson(Map<String, dynamic> json) {
|
||||
appointmentNo = json['appointmentNo'];
|
||||
clinicName = json['clinicName'];
|
||||
createdBy = json['createdBy'];
|
||||
createdOn = json['createdOn'];
|
||||
doctorName = json['doctorName'];
|
||||
doseDailyQuantity = json['doseDailyQuantity'];
|
||||
doseDailyUnitID = json['doseDailyUnitID'];
|
||||
doseDetail = json['doseDetail'];
|
||||
doseDurationDays = json['doseDurationDays'];
|
||||
doseTimingID = json['doseTimingID'];
|
||||
episodeID = json['episodeID'];
|
||||
frequencyID = json['frequencyID'];
|
||||
icdCode10ID = json['icdCode10ID'];
|
||||
indication = json['indication'];
|
||||
isDispensed = json['isDispensed'];
|
||||
isMedicineCovered = json['isMedicineCovered'];
|
||||
isSIG = json['isSIG'];
|
||||
medicationName = json['medicationName'];
|
||||
medicationPrice = json['medicationPrice'];
|
||||
medicineCode = json['medicineCode'];
|
||||
orderTypeDescription = json['orderTypeDescription'];
|
||||
qty = json['qty'];
|
||||
quantity = json['quantity'];
|
||||
remarks = json['remarks'];
|
||||
routeID = json['routeID'];
|
||||
startDate = json['startDate'];
|
||||
status = json['status'];
|
||||
stopDate = json['stopDate'];
|
||||
uom = json['uom'];
|
||||
pharmacistRemarks = json['pharmacistRemarks'];
|
||||
mediSpanGPICode = json['mediSpanGPICode'];
|
||||
refill = json['refill'];
|
||||
pharmacyInervention = json['interventionID'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['appointmentNo'] = this.appointmentNo;
|
||||
data['clinicName'] = this.clinicName;
|
||||
data['createdBy'] = this.createdBy;
|
||||
data['createdOn'] = this.createdOn;
|
||||
data['doctorName'] = this.doctorName;
|
||||
data['doseDailyQuantity'] = this.doseDailyQuantity;
|
||||
data['doseDailyUnitID'] = this.doseDailyUnitID;
|
||||
data['doseDetail'] = this.doseDetail;
|
||||
data['doseDurationDays'] = this.doseDurationDays;
|
||||
data['doseTimingID'] = this.doseTimingID;
|
||||
data['episodeID'] = this.episodeID;
|
||||
data['frequencyID'] = this.frequencyID;
|
||||
data['icdCode10ID'] = this.icdCode10ID;
|
||||
data['indication'] = this.indication;
|
||||
data['isDispensed'] = this.isDispensed;
|
||||
data['isMedicineCovered'] = this.isMedicineCovered;
|
||||
data['isSIG'] = this.isSIG;
|
||||
data['medicationName'] = this.medicationName;
|
||||
data['medicationPrice'] = this.medicationPrice;
|
||||
data['medicineCode'] = this.medicineCode;
|
||||
data['orderTypeDescription'] = this.orderTypeDescription;
|
||||
data['qty'] = this.qty;
|
||||
data['quantity'] = this.quantity;
|
||||
data['remarks'] = this.remarks;
|
||||
data['routeID'] = this.routeID;
|
||||
data['startDate'] = this.startDate;
|
||||
data['status'] = this.status;
|
||||
data['stopDate'] = this.stopDate;
|
||||
data['uom'] = this.uom;
|
||||
data['pharmacistRemarks'] = this.pharmacistRemarks;
|
||||
data['mediSpanGPICode'] = this.mediSpanGPICode;
|
||||
data['refill'] = this.refill;
|
||||
data['interventionID'] = this.pharmacyInervention;
|
||||
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,20 +1,26 @@
|
||||
class PrescriptionReqModel {
|
||||
String vidaAuthTokenID;
|
||||
dynamic patientMRN;
|
||||
dynamic appNo;
|
||||
dynamic admissionNo;
|
||||
|
||||
PrescriptionReqModel(
|
||||
{ this.patientMRN, this.appNo});
|
||||
{this.vidaAuthTokenID, this.patientMRN, this.appNo, this.admissionNo});
|
||||
|
||||
PrescriptionReqModel.fromJson(Map<String, dynamic> json) {
|
||||
vidaAuthTokenID = json['VidaAuthTokenID'];
|
||||
patientMRN = json['PatientMRN'];
|
||||
appNo = json['AppointmentNo'];
|
||||
|
||||
admissionNo = json['AdmissionNo'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['VidaAuthTokenID'] = this.vidaAuthTokenID;
|
||||
data['PatientMRN'] = this.patientMRN;
|
||||
data['AppointmentNo'] = this.appNo;
|
||||
data['AdmissionNo'] = this.admissionNo;
|
||||
|
||||
return data;
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,19 +0,0 @@
|
||||
import 'package:charts_flutter/flutter.dart' as charts;
|
||||
import 'package:charts_flutter/flutter.dart';
|
||||
import 'package:doctor_app_flutter/config/size_config.dart';
|
||||
import 'package:doctor_app_flutter/widgets/data_display/list/flexible_container.dart';
|
||||
import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
class TimeSeriesSales {
|
||||
final DateTime time;
|
||||
final int sales;
|
||||
|
||||
TimeSeriesSales(this.time, this.sales);
|
||||
}
|
||||
|
||||
class TimeSeriesSales2 {
|
||||
final DateTime time;
|
||||
final double sales;
|
||||
|
||||
TimeSeriesSales2(this.time, this.sales);
|
||||
}
|
||||
@ -0,0 +1,64 @@
|
||||
class RequestPatientLabOrders {
|
||||
double versionID;
|
||||
int channel;
|
||||
int languageID;
|
||||
String iPAdress;
|
||||
String generalid;
|
||||
int patientOutSA;
|
||||
String sessionID;
|
||||
bool isDentalAllowedBackend;
|
||||
int deviceTypeID;
|
||||
int patientID;
|
||||
String tokenID;
|
||||
int patientTypeID;
|
||||
int patientType;
|
||||
|
||||
RequestPatientLabOrders(
|
||||
{this.versionID,
|
||||
this.channel,
|
||||
this.languageID,
|
||||
this.iPAdress,
|
||||
this.generalid,
|
||||
this.patientOutSA,
|
||||
this.sessionID,
|
||||
this.isDentalAllowedBackend,
|
||||
this.deviceTypeID,
|
||||
this.patientID,
|
||||
this.tokenID,
|
||||
this.patientTypeID,
|
||||
this.patientType});
|
||||
|
||||
RequestPatientLabOrders.fromJson(Map<String, dynamic> json) {
|
||||
versionID = json['VersionID'];
|
||||
channel = json['Channel'];
|
||||
languageID = json['LanguageID'];
|
||||
iPAdress = json['IPAdress'];
|
||||
generalid = json['generalid'];
|
||||
patientOutSA = json['PatientOutSA'];
|
||||
sessionID = json['SessionID'];
|
||||
isDentalAllowedBackend = json['isDentalAllowedBackend'];
|
||||
deviceTypeID = json['DeviceTypeID'];
|
||||
patientID = json['PatientID'];
|
||||
tokenID = json['TokenID'];
|
||||
patientTypeID = json['PatientTypeID'];
|
||||
patientType = json['PatientType'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['VersionID'] = this.versionID;
|
||||
data['Channel'] = this.channel;
|
||||
data['LanguageID'] = this.languageID;
|
||||
data['IPAdress'] = this.iPAdress;
|
||||
data['generalid'] = this.generalid;
|
||||
data['PatientOutSA'] = this.patientOutSA;
|
||||
data['SessionID'] = this.sessionID;
|
||||
data['isDentalAllowedBackend'] = this.isDentalAllowedBackend;
|
||||
data['DeviceTypeID'] = this.deviceTypeID;
|
||||
data['PatientID'] = this.patientID;
|
||||
data['TokenID'] = this.tokenID;
|
||||
data['PatientTypeID'] = this.patientTypeID;
|
||||
data['PatientType'] = this.patientType;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,32 +0,0 @@
|
||||
class StpMasterListRequestModel {
|
||||
bool isDentalAllowedBackend;
|
||||
int languageID;
|
||||
int projectID;
|
||||
int parameterGroup;
|
||||
int parameterType;
|
||||
|
||||
StpMasterListRequestModel(
|
||||
{this.isDentalAllowedBackend,
|
||||
this.languageID,
|
||||
this.projectID,
|
||||
this.parameterGroup,
|
||||
this.parameterType});
|
||||
|
||||
StpMasterListRequestModel.fromJson(Map<String, dynamic> json) {
|
||||
isDentalAllowedBackend = json['isDentalAllowedBackend'];
|
||||
languageID = json['LanguageID'];
|
||||
projectID = json['ProjectID'];
|
||||
parameterGroup = json['parameterGroup'];
|
||||
parameterType = json['parameterType'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['isDentalAllowedBackend'] = this.isDentalAllowedBackend;
|
||||
data['LanguageID'] = this.languageID;
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['parameterGroup'] = this.parameterGroup;
|
||||
data['parameterType'] = this.parameterType;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,22 +0,0 @@
|
||||
class StpMasterListResponseModel {
|
||||
int parameterCode;
|
||||
String description;
|
||||
Null descriptionN;
|
||||
|
||||
StpMasterListResponseModel(
|
||||
{this.parameterCode, this.description, this.descriptionN});
|
||||
|
||||
StpMasterListResponseModel.fromJson(Map<String, dynamic> json) {
|
||||
parameterCode = json['ParameterCode'];
|
||||
description = json['Description'];
|
||||
descriptionN = json['DescriptionN'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['ParameterCode'] = this.parameterCode;
|
||||
data['Description'] = this.description;
|
||||
data['DescriptionN'] = this.descriptionN;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,66 +0,0 @@
|
||||
class AcceptOrRejectReqModel {
|
||||
int patientID;
|
||||
int projectID;
|
||||
int admissionNo;
|
||||
int prescriptionNo;
|
||||
int orderNo;
|
||||
String remarks;
|
||||
int memberID;
|
||||
int accessLevel;
|
||||
int languageID;
|
||||
int lineItemNo;
|
||||
bool patientOutSA;
|
||||
int interventionStatus;
|
||||
int status;
|
||||
|
||||
AcceptOrRejectReqModel(
|
||||
{this.patientID,
|
||||
this.projectID,
|
||||
this.admissionNo,
|
||||
this.prescriptionNo,
|
||||
this.orderNo,
|
||||
this.remarks,
|
||||
this.memberID,
|
||||
this.accessLevel,
|
||||
this.languageID,
|
||||
this.lineItemNo,
|
||||
this.patientOutSA,
|
||||
this.interventionStatus,
|
||||
this.status
|
||||
});
|
||||
|
||||
AcceptOrRejectReqModel.fromJson(Map<String, dynamic> json) {
|
||||
patientID = json['PatientID'];
|
||||
projectID = json['ProjectID'];
|
||||
admissionNo = json['AdmissionNo'];
|
||||
prescriptionNo = json['PrescriptionNo'];
|
||||
orderNo = json['OrderNo'];
|
||||
remarks = json['Remarks'];
|
||||
memberID = json['MemberID'];
|
||||
accessLevel = json['AccessLevel'];
|
||||
languageID = json['LanguageID'];
|
||||
lineItemNo = json['LineItemNo'];
|
||||
patientOutSA = json['PatientOutSA'];
|
||||
interventionStatus = json['InterventionStatus'];
|
||||
status = json['Status'];
|
||||
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['PatientID'] = this.patientID;
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['AdmissionNo'] = this.admissionNo;
|
||||
data['PrescriptionNo'] = this.prescriptionNo;
|
||||
data['OrderNo'] = this.orderNo;
|
||||
data['Remarks'] = this.remarks;
|
||||
data['MemberID'] = this.memberID;
|
||||
data['AccessLevel'] = this.accessLevel;
|
||||
data['LanguageID'] = this.languageID;
|
||||
data['LineItemNo'] = this.lineItemNo;
|
||||
data['PatientOutSA'] = this.patientOutSA;
|
||||
data['InterventionStatus'] = this.interventionStatus;
|
||||
data['Status'] = this.status;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,4 +0,0 @@
|
||||
class AcceptOrRejectResModel {
|
||||
|
||||
|
||||
}
|
||||
@ -1,32 +0,0 @@
|
||||
class InterventionMedicationHistoryReqModel {
|
||||
int projectID;
|
||||
int patientID;
|
||||
int admissionNo;
|
||||
int orderNo;
|
||||
int prescriptionNo;
|
||||
|
||||
InterventionMedicationHistoryReqModel(
|
||||
{this.projectID,
|
||||
this.patientID,
|
||||
this.admissionNo,
|
||||
this.orderNo,
|
||||
this.prescriptionNo});
|
||||
|
||||
InterventionMedicationHistoryReqModel.fromJson(Map<String, dynamic> json) {
|
||||
projectID = json['ProjectID'];
|
||||
patientID = json['PatientID'];
|
||||
admissionNo = json['AdmissionNo'];
|
||||
orderNo = json['OrderNo'];
|
||||
prescriptionNo = json['PrescriptionNo'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['PatientID'] = this.patientID;
|
||||
data['AdmissionNo'] = this.admissionNo;
|
||||
data['OrderNo'] = this.orderNo;
|
||||
data['PrescriptionNo'] = this.prescriptionNo;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,96 +0,0 @@
|
||||
class InterventionMedicationHistoryResModel {
|
||||
String setupId;
|
||||
String projectId;
|
||||
int patientId;
|
||||
int admissionNo;
|
||||
int prescriptionId;
|
||||
int orderNo;
|
||||
int id;
|
||||
int interventionId;
|
||||
Null intervention;
|
||||
String remark;
|
||||
int commentedBy;
|
||||
bool isDoctor;
|
||||
bool isActive;
|
||||
int createdBy;
|
||||
String createdByName;
|
||||
String createdByNameN;
|
||||
String createdOn;
|
||||
Null editedBy;
|
||||
Null editedByName;
|
||||
Null editedByNameN;
|
||||
Null editedOn;
|
||||
|
||||
InterventionMedicationHistoryResModel(
|
||||
{this.setupId,
|
||||
this.projectId,
|
||||
this.patientId,
|
||||
this.admissionNo,
|
||||
this.prescriptionId,
|
||||
this.orderNo,
|
||||
this.id,
|
||||
this.interventionId,
|
||||
this.intervention,
|
||||
this.remark,
|
||||
this.commentedBy,
|
||||
this.isDoctor,
|
||||
this.isActive,
|
||||
this.createdBy,
|
||||
this.createdByName,
|
||||
this.createdByNameN,
|
||||
this.createdOn,
|
||||
this.editedBy,
|
||||
this.editedByName,
|
||||
this.editedByNameN,
|
||||
this.editedOn});
|
||||
|
||||
InterventionMedicationHistoryResModel.fromJson(Map<String, dynamic> json) {
|
||||
setupId = json['SetupId'];
|
||||
projectId = json['ProjectId'];
|
||||
patientId = json['PatientId'];
|
||||
admissionNo = json['AdmissionNo'];
|
||||
prescriptionId = json['PrescriptionId'];
|
||||
orderNo = json['OrderNo'];
|
||||
id = json['Id'];
|
||||
interventionId = json['InterventionId'];
|
||||
intervention = json['Intervention'];
|
||||
remark = json['Remark'];
|
||||
commentedBy = json['CommentedBy'];
|
||||
isDoctor = json['IsDoctor'];
|
||||
isActive = json['IsActive'];
|
||||
createdBy = json['CreatedBy'];
|
||||
createdByName = json['CreatedByName'];
|
||||
createdByNameN = json['CreatedByNameN'];
|
||||
createdOn = json['CreatedOn'];
|
||||
editedBy = json['EditedBy'];
|
||||
editedByName = json['EditedByName'];
|
||||
editedByNameN = json['EditedByNameN'];
|
||||
editedOn = json['EditedOn'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['SetupId'] = this.setupId;
|
||||
data['ProjectId'] = this.projectId;
|
||||
data['PatientId'] = this.patientId;
|
||||
data['AdmissionNo'] = this.admissionNo;
|
||||
data['PrescriptionId'] = this.prescriptionId;
|
||||
data['OrderNo'] = this.orderNo;
|
||||
data['Id'] = this.id;
|
||||
data['InterventionId'] = this.interventionId;
|
||||
data['Intervention'] = this.intervention;
|
||||
data['Remark'] = this.remark;
|
||||
data['CommentedBy'] = this.commentedBy;
|
||||
data['IsDoctor'] = this.isDoctor;
|
||||
data['IsActive'] = this.isActive;
|
||||
data['CreatedBy'] = this.createdBy;
|
||||
data['CreatedByName'] = this.createdByName;
|
||||
data['CreatedByNameN'] = this.createdByNameN;
|
||||
data['CreatedOn'] = this.createdOn;
|
||||
data['EditedBy'] = this.editedBy;
|
||||
data['EditedByName'] = this.editedByName;
|
||||
data['EditedByNameN'] = this.editedByNameN;
|
||||
data['EditedOn'] = this.editedOn;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,25 +0,0 @@
|
||||
class InterventionMedicationReqModel {
|
||||
int projectID;
|
||||
int patientID;
|
||||
String fromDate;
|
||||
String toDate;
|
||||
|
||||
InterventionMedicationReqModel(
|
||||
{this.projectID, this.patientID, this.fromDate, this.toDate});
|
||||
|
||||
InterventionMedicationReqModel.fromJson(Map<String, dynamic> json) {
|
||||
projectID = json['ProjectID'];
|
||||
patientID = json['PatientID'];
|
||||
fromDate = json['FromDate'];
|
||||
toDate = json['ToDate'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['PatientID'] = this.patientID;
|
||||
data['FromDate'] = this.fromDate;
|
||||
data['ToDate'] = this.toDate;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,100 +0,0 @@
|
||||
class InterventionMedicationResModel {
|
||||
String cS;
|
||||
String iHR;
|
||||
String setupID;
|
||||
int projectID;
|
||||
int accessLevel;
|
||||
int patientID;
|
||||
String patientName;
|
||||
String description;
|
||||
int admissionNo;
|
||||
int orderNo;
|
||||
int prescriptionNo;
|
||||
int lineItemNo;
|
||||
int itemID;
|
||||
String medication;
|
||||
String doctorComments;
|
||||
String startDatetime;
|
||||
String stopDatetime;
|
||||
int status;
|
||||
int createdBy;
|
||||
int authorizedby;
|
||||
Null pharmacyRemarks;
|
||||
String statusDescription;
|
||||
|
||||
InterventionMedicationResModel(
|
||||
{this.cS,
|
||||
this.iHR,
|
||||
this.setupID,
|
||||
this.projectID,
|
||||
this.accessLevel,
|
||||
this.patientID,
|
||||
this.patientName,
|
||||
this.description,
|
||||
this.admissionNo,
|
||||
this.orderNo,
|
||||
this.prescriptionNo,
|
||||
this.lineItemNo,
|
||||
this.itemID,
|
||||
this.medication,
|
||||
this.doctorComments,
|
||||
this.startDatetime,
|
||||
this.stopDatetime,
|
||||
this.status,
|
||||
this.createdBy,
|
||||
this.authorizedby,
|
||||
this.pharmacyRemarks,
|
||||
this.statusDescription});
|
||||
|
||||
InterventionMedicationResModel.fromJson(Map<String, dynamic> json) {
|
||||
cS = json['CS'];
|
||||
iHR = json['IHR'];
|
||||
setupID = json['SetupID'];
|
||||
projectID = json['ProjectID'];
|
||||
accessLevel = json['AccessLevel'];
|
||||
patientID = json['PatientID'];
|
||||
patientName = json['PatientName'];
|
||||
description = json['Description'];
|
||||
admissionNo = json['AdmissionNo'];
|
||||
orderNo = json['OrderNo'];
|
||||
prescriptionNo = json['PrescriptionNo'];
|
||||
lineItemNo = json['LineItemNo'];
|
||||
itemID = json['ItemID'];
|
||||
medication = json['Medication'];
|
||||
doctorComments = json['DoctorComments'];
|
||||
startDatetime = json['StartDatetime'];
|
||||
stopDatetime = json['StopDatetime'];
|
||||
status = json['Status'];
|
||||
createdBy = json['CreatedBy'];
|
||||
authorizedby = json['Authorizedby'];
|
||||
pharmacyRemarks = json['PharmacyRemarks'];
|
||||
statusDescription = json['StatusDescription'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['CS'] = this.cS;
|
||||
data['IHR'] = this.iHR;
|
||||
data['SetupID'] = this.setupID;
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['AccessLevel'] = this.accessLevel;
|
||||
data['PatientID'] = this.patientID;
|
||||
data['PatientName'] = this.patientName;
|
||||
data['Description'] = this.description;
|
||||
data['AdmissionNo'] = this.admissionNo;
|
||||
data['OrderNo'] = this.orderNo;
|
||||
data['PrescriptionNo'] = this.prescriptionNo;
|
||||
data['LineItemNo'] = this.lineItemNo;
|
||||
data['ItemID'] = this.itemID;
|
||||
data['Medication'] = this.medication;
|
||||
data['DoctorComments'] = this.doctorComments;
|
||||
data['StartDatetime'] = this.startDatetime;
|
||||
data['StopDatetime'] = this.stopDatetime;
|
||||
data['Status'] = this.status;
|
||||
data['CreatedBy'] = this.createdBy;
|
||||
data['Authorizedby'] = this.authorizedby;
|
||||
data['PharmacyRemarks'] = this.pharmacyRemarks;
|
||||
data['StatusDescription'] = this.statusDescription;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,22 +0,0 @@
|
||||
class VteAssessmentRequestModel {
|
||||
String setupID;
|
||||
int parameterGroup;
|
||||
int transactionNo;
|
||||
|
||||
VteAssessmentRequestModel(
|
||||
{this.setupID = "010266", this.parameterGroup = 7, this.transactionNo});
|
||||
|
||||
VteAssessmentRequestModel.fromJson(Map<String, dynamic> json) {
|
||||
setupID = json['SetupID'];
|
||||
parameterGroup = json['ParameterGroup'];
|
||||
transactionNo = json['TransactionNo'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['SetupID'] = this.setupID;
|
||||
data['ParameterGroup'] = this.parameterGroup;
|
||||
data['TransactionNo'] = this.transactionNo;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,48 +0,0 @@
|
||||
class VteAssessmentResponseModel {
|
||||
int lineItemNo;
|
||||
String vTEType;
|
||||
String ambulationProtocol;
|
||||
String pharmacology;
|
||||
String reasonsThrombo;
|
||||
String riskScore;
|
||||
int totalScore;
|
||||
int createdBy;
|
||||
String createdOn;
|
||||
|
||||
VteAssessmentResponseModel(
|
||||
{this.lineItemNo,
|
||||
this.vTEType,
|
||||
this.ambulationProtocol,
|
||||
this.pharmacology,
|
||||
this.reasonsThrombo,
|
||||
this.riskScore,
|
||||
this.totalScore,
|
||||
this.createdBy,
|
||||
this.createdOn});
|
||||
|
||||
VteAssessmentResponseModel.fromJson(Map<String, dynamic> json) {
|
||||
lineItemNo = json['LineItemNo'];
|
||||
vTEType = json['VTE_Type'];
|
||||
ambulationProtocol = json['AmbulationProtocol'];
|
||||
pharmacology = json['Pharmacology'];
|
||||
reasonsThrombo = json['ReasonsThrombo'];
|
||||
riskScore = json['Risk_Score'];
|
||||
totalScore = json['Total_Score'];
|
||||
createdBy = json['Created_By'];
|
||||
createdOn = json['Created_On'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['LineItemNo'] = this.lineItemNo;
|
||||
data['VTE_Type'] = this.vTEType;
|
||||
data['AmbulationProtocol'] = this.ambulationProtocol;
|
||||
data['Pharmacology'] = this.pharmacology;
|
||||
data['ReasonsThrombo'] = this.reasonsThrombo;
|
||||
data['Risk_Score'] = this.riskScore;
|
||||
data['Total_Score'] = this.totalScore;
|
||||
data['Created_By'] = this.createdBy;
|
||||
data['Created_On'] = this.createdOn;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -1,66 +0,0 @@
|
||||
import 'package:doctor_app_flutter/config/config.dart';
|
||||
import 'package:doctor_app_flutter/core/service/base/base_service.dart';
|
||||
import 'package:doctor_app_flutter/core/model/pharmacy-intervention-model/accept_or_reject_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/pharmacy-intervention-model/intervention_medication_history_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/pharmacy-intervention-model/intervention_medication_history_res_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/pharmacy-intervention-model/new_medication_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/pharmacy-intervention-model/new_medication_res_model.dart';
|
||||
class InterventionMedicationService extends BaseService {
|
||||
|
||||
List<InterventionMedicationResModel> _allInterventionList = [];
|
||||
|
||||
List<InterventionMedicationHistoryResModel> _allInterventionHistoryList = [];
|
||||
|
||||
List<InterventionMedicationResModel> get allInterventionList =>
|
||||
_allInterventionList;
|
||||
|
||||
List<InterventionMedicationHistoryResModel> get allInterventionHistoryList =>
|
||||
_allInterventionHistoryList;
|
||||
|
||||
Future getInterventionMedication(
|
||||
{InterventionMedicationReqModel interventionMedicationReqModel}) async {
|
||||
hasError = false;
|
||||
await baseAppClient.post(GET_INTERVENTION_MEDICATION,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
_allInterventionList.clear();
|
||||
response['List_InterventionMedications'].forEach(
|
||||
(v) {
|
||||
_allInterventionList.add(InterventionMedicationResModel.fromJson(v));
|
||||
},
|
||||
);
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: interventionMedicationReqModel.toJson());
|
||||
}
|
||||
|
||||
Future getInterventionMedicationHistory(
|
||||
{InterventionMedicationHistoryReqModel interventionMedicationHistoryReqModel}) async {
|
||||
hasError = false;
|
||||
await baseAppClient.post(GET_INTERVENTION_MEDICATION_HISTORY,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
_allInterventionHistoryList.clear();
|
||||
response['List_InterventionHistory'].forEach(
|
||||
(v) {
|
||||
_allInterventionHistoryList.add(InterventionMedicationHistoryResModel.fromJson(v));
|
||||
},
|
||||
);
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: interventionMedicationHistoryReqModel.toJson());
|
||||
}
|
||||
|
||||
Future setAcceptedOrRejected(
|
||||
{AcceptOrRejectReqModel acceptOrRejectReqModel}) async {
|
||||
hasError = false;
|
||||
await baseAppClient.post(SET_ACCEPTED_OR_REJECTED,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
_allInterventionHistoryList.clear();
|
||||
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: acceptOrRejectReqModel.toJson());
|
||||
}
|
||||
}
|
||||
@ -1,30 +0,0 @@
|
||||
import 'package:doctor_app_flutter/config/config.dart';
|
||||
import 'package:doctor_app_flutter/core/model/vte_assessment/vte_assessment_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/vte_assessment/vte_assessment_res_model.dart';
|
||||
import 'package:doctor_app_flutter/core/service/base/base_service.dart';
|
||||
import 'package:doctor_app_flutter/core/model/discharge_summary/GetDischargeSummaryReqModel.dart';
|
||||
import 'package:doctor_app_flutter/core/model/discharge_summary/GetDischargeSummaryResModel.dart';
|
||||
|
||||
class VteAssessmentService extends BaseService {
|
||||
|
||||
List<VteAssessmentResponseModel> _allVteHistoryList = [];
|
||||
|
||||
List<VteAssessmentResponseModel> get allVteHistoryList =>
|
||||
_allVteHistoryList;
|
||||
Future getVteAssessment(
|
||||
{VteAssessmentRequestModel vteAssessmentRequestModel}) async {
|
||||
hasError = false;
|
||||
await baseAppClient.post(VTE_ASSESSMENT,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
_allVteHistoryList.clear();
|
||||
response['INP_VTEHistoryByTransactionNo_List'].forEach(
|
||||
(v) {
|
||||
_allVteHistoryList.add(VteAssessmentResponseModel.fromJson(v));
|
||||
},
|
||||
);
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: vteAssessmentRequestModel.toJson());
|
||||
}
|
||||
}
|
||||
@ -1,49 +0,0 @@
|
||||
import 'package:doctor_app_flutter/config/config.dart';
|
||||
import 'package:doctor_app_flutter/core/model/ER_sign_in/doctor_ER_sign_assessment_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/Prescriptions.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/get_medication_for_inpatient_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/get_medication_for_inpatient_request_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/perscription_pharmacy.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/post_prescrition_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_entity_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_in_patient.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_report.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_report_enh.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescriptions_order.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/request_get_list_pharmacy_for_prescriptions.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/request_prescription_report.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/request_prescription_report_enh.dart';
|
||||
import 'package:doctor_app_flutter/core/model/SOAP/Allergy/get_allergies_res_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/SOAP/Assessment/get_assessment_res_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/calculate_box_request_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/search_drug/get_medication_response_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/search_drug/item_by_medicine_request_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/search_drug/search_drug_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/search_drug/search_drug_request_model.dart';
|
||||
import 'package:doctor_app_flutter/core/service/base/lookup-service.dart';
|
||||
import 'package:doctor_app_flutter/core/model/SOAP/Assessment/get_assessment_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/patient/patiant_info_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/patient/vital_sign/patient-vital-sign-data.dart';
|
||||
import 'package:doctor_app_flutter/utils/date-utils.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
|
||||
class ERSignInService extends LookupService {
|
||||
|
||||
|
||||
Future signInERPatient({DoctorErSignAssessmentReqModel doctorErSignAssessmentReqModel}) async {
|
||||
|
||||
|
||||
hasError = false;
|
||||
|
||||
await baseAppClient.post(DOCTOR_ER_SIGN_ASSESSMENT,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: doctorErSignAssessmentReqModel.toJson());
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,238 @@
|
||||
import 'package:doctor_app_flutter/config/config.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/Prescriptions.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/get_medication_for_inpatient_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/get_medication_for_inpatient_request_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/in_patient_prescription_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/perscription_pharmacy.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_in_patient.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_report.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_report_enh.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescriptions_order.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/request_get_list_pharmacy_for_prescriptions.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/request_prescription_report.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/request_prescription_report_enh.dart';
|
||||
import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
|
||||
import '../../base/base_service.dart';
|
||||
|
||||
class PrescriptionsService extends BaseService {
|
||||
List<Prescriptions> prescriptionsList = List();
|
||||
List<GetMedicationForInPatientModel> medicationForInPatient = List();
|
||||
List<PrescriptionsOrder> prescriptionsOrderList = List();
|
||||
List<PrescriotionInPatient> prescriptionInPatientList = List();
|
||||
|
||||
InPatientPrescriptionRequestModel _inPatientPrescriptionRequestModel =
|
||||
InPatientPrescriptionRequestModel();
|
||||
GetMedicationForInPatientRequestModel _getMedicationForInPatientRequestModel =
|
||||
GetMedicationForInPatientRequestModel();
|
||||
|
||||
Future getPrescriptionInPatient({int mrn, String adn}) async {
|
||||
_inPatientPrescriptionRequestModel = InPatientPrescriptionRequestModel(
|
||||
patientMRN: mrn,
|
||||
admissionNo: adn,
|
||||
);
|
||||
hasError = false;
|
||||
prescriptionInPatientList.clear();
|
||||
|
||||
await baseAppClient.post(GET_PRESCRIPTION_IN_PATIENT,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
prescriptionsList.clear();
|
||||
response['List_PrescriptionReportForInPatient'].forEach((prescriptions) {
|
||||
prescriptionInPatientList
|
||||
.add(PrescriotionInPatient.fromJson(prescriptions));
|
||||
});
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: _inPatientPrescriptionRequestModel.toJson());
|
||||
}
|
||||
|
||||
Future getPrescriptions(PatiantInformtion patient) async {
|
||||
hasError = false;
|
||||
Map<String, dynamic> body = Map();
|
||||
body['isDentalAllowedBackend'] = false;
|
||||
await baseAppClient.postPatient(PRESCRIPTIONS, patient: patient,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
prescriptionsList.clear();
|
||||
response['PatientPrescriptionList'].forEach((prescriptions) {
|
||||
prescriptionsList.add(Prescriptions.fromJson(prescriptions));
|
||||
});
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: body);
|
||||
}
|
||||
|
||||
RequestPrescriptionReport _requestPrescriptionReport =
|
||||
RequestPrescriptionReport(
|
||||
appointmentNo: 0, isDentalAllowedBackend: false);
|
||||
List<PrescriptionReport> prescriptionReportList = List();
|
||||
|
||||
Future getPrescriptionReport(
|
||||
{Prescriptions prescriptions,
|
||||
@required PatiantInformtion patient}) async {
|
||||
hasError = false;
|
||||
_requestPrescriptionReport.dischargeNo = prescriptions.dischargeNo;
|
||||
_requestPrescriptionReport.projectID = prescriptions.projectID;
|
||||
_requestPrescriptionReport.clinicID = prescriptions.clinicID;
|
||||
_requestPrescriptionReport.setupID = prescriptions.setupID;
|
||||
_requestPrescriptionReport.episodeID = prescriptions.episodeID;
|
||||
_requestPrescriptionReport.appointmentNo = prescriptions.appointmentNo;
|
||||
|
||||
await baseAppClient.postPatient(
|
||||
prescriptions.isInOutPatient
|
||||
? GET_PRESCRIPTION_REPORT_ENH
|
||||
: GET_PRESCRIPTION_REPORT_NEW,
|
||||
patient: patient, onSuccess: (dynamic response, int statusCode) {
|
||||
prescriptionReportList.clear();
|
||||
prescriptionReportEnhList.clear();
|
||||
if (prescriptions.isInOutPatient) {
|
||||
response['ListPRM'].forEach((prescriptions) {
|
||||
prescriptionReportList
|
||||
.add(PrescriptionReport.fromJson(prescriptions));
|
||||
prescriptionReportEnhList
|
||||
.add(PrescriptionReportEnh.fromJson(prescriptions));
|
||||
});
|
||||
} else {
|
||||
response['INP_GetPrescriptionReport_List'].forEach((prescriptions) {
|
||||
prescriptionReportList
|
||||
.add(PrescriptionReport.fromJson(prescriptions));
|
||||
});
|
||||
}
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: _requestPrescriptionReport.toJson());
|
||||
}
|
||||
|
||||
RequestGetListPharmacyForPrescriptions
|
||||
requestGetListPharmacyForPrescriptions =
|
||||
RequestGetListPharmacyForPrescriptions(
|
||||
latitude: 0,
|
||||
longitude: 0,
|
||||
isDentalAllowedBackend: false,
|
||||
);
|
||||
List<PharmacyPrescriptions> pharmacyPrescriptionsList = List();
|
||||
|
||||
Future getListPharmacyForPrescriptions(
|
||||
{int itemId, @required PatiantInformtion patient}) async {
|
||||
hasError = false;
|
||||
requestGetListPharmacyForPrescriptions.itemID = itemId;
|
||||
await baseAppClient.postPatient(GET_PHARMACY_LIST, patient: patient,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
pharmacyPrescriptionsList.clear();
|
||||
response['PharmList'].forEach((prescriptions) {
|
||||
pharmacyPrescriptionsList
|
||||
.add(PharmacyPrescriptions.fromJson(prescriptions));
|
||||
});
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: requestGetListPharmacyForPrescriptions.toJson());
|
||||
}
|
||||
|
||||
RequestPrescriptionReportEnh _requestPrescriptionReportEnh =
|
||||
RequestPrescriptionReportEnh(
|
||||
isDentalAllowedBackend: false,
|
||||
);
|
||||
|
||||
List<PrescriptionReportEnh> prescriptionReportEnhList = List();
|
||||
|
||||
Future getPrescriptionReportEnh(
|
||||
{PrescriptionsOrder prescriptionsOrder,
|
||||
@required PatiantInformtion patient}) async {
|
||||
///This logic copy from the old app from class [order-history.component.ts] in line 45
|
||||
bool isInPatient = false;
|
||||
prescriptionsList.forEach((element) {
|
||||
if (prescriptionsOrder.appointmentNo == "0") {
|
||||
if (element.dischargeNo == int.parse(prescriptionsOrder.dischargeID)) {
|
||||
_requestPrescriptionReportEnh.appointmentNo = element.appointmentNo;
|
||||
_requestPrescriptionReportEnh.clinicID = element.clinicID;
|
||||
_requestPrescriptionReportEnh.projectID = element.projectID;
|
||||
_requestPrescriptionReportEnh.episodeID = element.episodeID;
|
||||
_requestPrescriptionReportEnh.setupID = element.setupID;
|
||||
_requestPrescriptionReportEnh.dischargeNo = element.dischargeNo;
|
||||
isInPatient = element.isInOutPatient;
|
||||
}
|
||||
} else {
|
||||
if (int.parse(prescriptionsOrder.appointmentNo) ==
|
||||
element.appointmentNo) {
|
||||
_requestPrescriptionReportEnh.appointmentNo = element.appointmentNo;
|
||||
_requestPrescriptionReportEnh.clinicID = element.clinicID;
|
||||
_requestPrescriptionReportEnh.projectID = element.projectID;
|
||||
_requestPrescriptionReportEnh.episodeID = element.episodeID;
|
||||
_requestPrescriptionReportEnh.setupID = element.setupID;
|
||||
_requestPrescriptionReportEnh.dischargeNo = element.dischargeNo;
|
||||
isInPatient = element.isInOutPatient;
|
||||
|
||||
///call inpGetPrescriptionReport
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
hasError = false;
|
||||
|
||||
await baseAppClient.postPatient(
|
||||
isInPatient ? GET_PRESCRIPTION_REPORT_ENH : GET_PRESCRIPTION_REPORT_NEW,
|
||||
patient: patient, onSuccess: (dynamic response, int statusCode) {
|
||||
prescriptionReportEnhList.clear();
|
||||
|
||||
if (isInPatient) {
|
||||
response['ListPRM'].forEach((prescriptions) {
|
||||
prescriptionReportEnhList
|
||||
.add(PrescriptionReportEnh.fromJson(prescriptions));
|
||||
});
|
||||
} else {
|
||||
response['INP_GetPrescriptionReport_List'].forEach((prescriptions) {
|
||||
PrescriptionReportEnh reportEnh =
|
||||
PrescriptionReportEnh.fromJson(prescriptions);
|
||||
reportEnh.itemDescription = prescriptions['ItemDescriptionN'];
|
||||
prescriptionReportEnhList.add(reportEnh);
|
||||
});
|
||||
}
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: _requestPrescriptionReportEnh.toJson());
|
||||
}
|
||||
|
||||
Future getPrescriptionsOrders() async {
|
||||
Map<String, dynamic> body = Map();
|
||||
body['isDentalAllowedBackend'] = false;
|
||||
await baseAppClient.post(GET_PRESCRIPTIONS_ALL_ORDERS,
|
||||
onSuccess: (dynamic response, int statusCode) {
|
||||
prescriptionsOrderList.clear();
|
||||
response['PatientER_GetPatientAllPresOrdersList']
|
||||
.forEach((prescriptionsOrder) {
|
||||
prescriptionsOrderList
|
||||
.add(PrescriptionsOrder.fromJson(prescriptionsOrder));
|
||||
});
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: body);
|
||||
}
|
||||
|
||||
Future getMedicationForInPatient(PatiantInformtion patient) async {
|
||||
hasError = false;
|
||||
_getMedicationForInPatientRequestModel =
|
||||
GetMedicationForInPatientRequestModel(
|
||||
isDentalAllowedBackend: false,
|
||||
admissionNo: int.parse(patient.admissionNo),
|
||||
tokenID: "@dm!n",
|
||||
projectID: patient.projectId,
|
||||
);
|
||||
await baseAppClient.postPatient(GET_MEDICATION_FOR_IN_PATIENT,
|
||||
patient: patient, onSuccess: (dynamic response, int statusCode) {
|
||||
medicationForInPatient.clear();
|
||||
response['List_GetMedicationForInpatient'].forEach((prescriptions) {
|
||||
medicationForInPatient
|
||||
.add(GetMedicationForInPatientModel.fromJson(prescriptions));
|
||||
});
|
||||
}, onFailure: (String error, int statusCode) {
|
||||
hasError = true;
|
||||
super.error = error;
|
||||
}, body: _getMedicationForInPatientRequestModel.toJson());
|
||||
}
|
||||
}
|
||||
@ -1,41 +0,0 @@
|
||||
import 'package:doctor_app_flutter/core/enum/filter_type.dart';
|
||||
import 'package:doctor_app_flutter/core/enum/view_state.dart';
|
||||
import 'package:doctor_app_flutter/core/model/ER_sign_in/doctor_ER_sign_assessment_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/Prescriptions.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/get_medication_for_inpatient_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/perscription_pharmacy.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/post_prescrition_req_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_entity_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_report.dart';
|
||||
import 'package:doctor_app_flutter/core/model/Prescriptions/prescription_report_enh.dart';
|
||||
import 'package:doctor_app_flutter/core/model/SOAP/Allergy/get_allergies_res_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/SOAP/Assessment/get_assessment_res_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/patient/patiant_info_model.dart';
|
||||
import 'package:doctor_app_flutter/core/model/patient/vital_sign/patient-vital-sign-data.dart';
|
||||
import 'package:doctor_app_flutter/core/service/patient_medical_file/ER_signin/ER_signin_service.dart';
|
||||
import 'package:doctor_app_flutter/core/service/patient_medical_file/prescription/prescription_service.dart';
|
||||
import 'package:doctor_app_flutter/core/viewModel/base_view_model.dart';
|
||||
import 'package:doctor_app_flutter/locator.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
|
||||
class ERSignInViewModel extends BaseViewModel {
|
||||
bool hasError = false;
|
||||
|
||||
ERSignInService _ERSignInService = locator<ERSignInService>();
|
||||
|
||||
Future signInERPatient({int patientId, int signInType}) async {
|
||||
hasError = false;
|
||||
await getDoctorProfile();
|
||||
DoctorErSignAssessmentReqModel doctorErSignAssessmentReqModel = new DoctorErSignAssessmentReqModel(setupID:"010266", signInType:signInType, loginDoctorID:doctorProfile.doctorID, patientID: patientId );
|
||||
setState(ViewState.BusyLocal);
|
||||
await _ERSignInService.signInERPatient(doctorErSignAssessmentReqModel: doctorErSignAssessmentReqModel);
|
||||
if (_ERSignInService.hasError) {
|
||||
error = _ERSignInService.error;
|
||||
setState(ViewState.ErrorLocal);
|
||||
} else
|
||||
setState(ViewState.Idle);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue