public List <PharmacyFields> getPharmacyFields(string PatientMasterVisitID) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); List <PharmacyFields> drg = patientEncounter.getPharmacyFields(PatientMasterVisitID); return(drg); }
public int saveUpdatePharmacy(string PatientMasterVisitID, string PatientId, string LocationID, string OrderedBy, string UserID, string DispensedBy, string RegimenLine, string ModuleID, string pmscmFlag, string prescription, string TreatmentProgram, string PeriodTaken, string TreatmentPlan, string TreatmentPlanReason, string Regimen, string regimenText, string prescriptionDate, string dispensedDate) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); PatientEncounterManager patientEncounterManager = new PatientEncounterManager(); JavaScriptSerializer parser = new JavaScriptSerializer(); int val = 0; var drugPrescription = parser.Deserialize <List <DrugPrescription> >(prescription); string RegimenType = ""; for (int i = 0; i < drugPrescription.Count; i++) { if (!RegimenType.ToUpper().Contains(drugPrescription[i].DrugAbbr.ToUpper())) { if (drugPrescription[i].DrugAbbr != "") { RegimenType += drugPrescription[i].DrugAbbr + "/"; } } } result = patientEncounter.saveUpdatePharmacy(PatientMasterVisitID, PatientId, LocationID, OrderedBy, UserID, RegimenType.TrimEnd('/'), DispensedBy, RegimenLine, ModuleID, drugPrescription, pmscmFlag, TreatmentProgram, PeriodTaken, TreatmentPlan, TreatmentPlanReason, Regimen, prescriptionDate, dispensedDate); //-- Raise event if result is>0 for sharing with IL if (result > 0) { MessageEventArgs arg = new MessageEventArgs() { PatientId = Convert.ToInt32(PatientId), EntityId = result, // the orderId EventOccurred = "Prescription Raised", MessageType = MessageType.DrugPrescriptionRaised, FacilityId = 0, PatientMasterVisitId = Convert.ToInt32(PatientMasterVisitID) }; Publisher.RaiseEventAsync(this, arg).ConfigureAwait(false); // -- } if (result > 0) { val = patientEncounterManager.AddpatientEncounter(Convert.ToInt32(PatientId), Convert.ToInt32(PatientMasterVisitID), patientEncounterManager.GetPatientEncounterId("EncounterType", "Pharmacy-encounter".ToLower()), 204, Convert.ToInt32(UserID)); } return((val > 0) ? result : 0); // return result; }
public void getPharmacyDrugFrequency(DropDownList ddl) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); List <DrugFrequency> drg = patientEncounter.getPharmacyDrugFrequency(); ddl.Items.Add(new ListItem("Select", "0")); if (drg != null && drg.Count > 0) { foreach (var item in drg) { ddl.Items.Add(new ListItem(item.frequency, item.id)); } } }
public void getPharmacyTreatmentProgram(DropDownList ddl) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); List <KeyValue> kv = patientEncounter.getPharmacyTreatmentProgram(); ddl.Items.Add(new ListItem("Select", "0")); if (kv != null && kv.Count > 0) { foreach (var item in kv) { ddl.Items.Add(new ListItem(item.DisplayName, item.ItemId)); } } }
public ArrayList getPharmacyTreatmentProgramList() { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); List <KeyValue> kv = patientEncounter.getPharmacyTreatmentProgram(); ArrayList lst = new ArrayList(); if (kv != null && kv.Count > 0) { foreach (var item in kv) { lst.Add(item.DisplayName); } } return(lst); }
public string getPharmacyDrugMultiplier(string frequencyID) { try { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); List <DrugFrequency> drg = patientEncounter.getPharmacyDrugFrequency(); List <DrugFrequency> filteredList = drg.Where(x => x.id == frequencyID).ToList(); return(filteredList[0].multiplier); } catch { return("0"); } }
public DataTable getPharmacyPendingPrescriptions(string PatientMasterVisitID, string patientID) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); return(patientEncounter.getPharmacyPendingPrescriptions(PatientMasterVisitID, patientID)); }
public DataTable getPharmacyRegimens(string regimenLine) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); return(patientEncounter.getPharmacyRegimens(regimenLine)); }
public DataTable getPharmacyDrugSwitchInterruptionReason(string treatmentPlan) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); return(patientEncounter.getPharmacyDrugSubstitutionInterruptionReason(treatmentPlan)); }
public List <DrugBatch> getPharmacyDrugBatch(string drugPk) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); return(patientEncounter.getPharmacyDrugBatch(drugPk)); }
public List <PharmacyFields> getPharmacyCurrentRegimen(string patientId) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); return(patientEncounter.getPharmacyCurrentRegimen(patientId)); }
public DataTable getPharmacyDrugList(string PMSCM, string treatmentPlan) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); return(patientEncounter.getPharmacyDrugList(PMSCM, treatmentPlan)); }
public DataTable loadPatientLatestPharmacyPrescription(string PatientID, string FacilityID) { IPatientPharmacy patientEncounter = (IPatientPharmacy)ObjectFactory.CreateInstance("BusinessProcess.CCC.BPatientPharmacy, BusinessProcess.CCC"); return(patientEncounter.getLatestPharmacyPrescriptionDetails(PatientID, FacilityID)); }