public RadiologyReport[] getRadiologyReports(string dfn, string fromDate, string toDate, int nrpts) { MdoQuery request = VistaUtils.buildReportTextRequest(dfn, fromDate, toDate, nrpts, "OR_R18:IMAGING~RIM;ORDV08;0;"); string response = (string)cxn.query(request); return(toRadiologyReports(response)); }
// Get all vital signs for given patient (RDV call) public VitalSignSet[] getVitalSigns(string dfn) { MdoQuery request = buildGetVitalSignsRdvRequest(dfn); string response = (string)cxn.query(request); return(toVitalSignsFromRdv(response)); }
public KeyValuePair <string, string>[] getRpcList(string target) { MdoQuery request = buildGetRpcListRequest(target); string response = (string)cxn.query(request); return(toRpcArray(response)); }
public ChemHemReport getChemHemReport(string dfn, ref string nextDate) { MdoQuery request = buildGetChemHemReportRequest(dfn, nextDate); string response = (string)cxn.query(request, new MenuOption(VistaConstants.CPRS_CONTEXT)); return(toChemHemReport(response, ref nextDate)); }
public ChemHemReport getChemHemReport(string dfn, ref string nextDate) { MdoQuery request = buildGetChemHemReportRequest(dfn, nextDate); string response = (string)cxn.query(request); return(toChemHemReport(response, ref nextDate)); }
public List <SiteId> getSitesForStation() { MdoQuery request = buildGetSitesForStationRequest(); string response = (string)cxn.query(request, new MenuOption("AMOJ VL APPTFL")); return(siteIdsToMdo(response)); }
public string[] getReminderReportTemplates() { MdoQuery request = builtGetReminderReportTemplatesRequest(); string response = (string)cxn.query(request, new MenuOption("AMOJ VL CPGPI")); return(StringUtils.split(response, StringUtils.CRLF)); }
public VitalSignSet[] getVitalSigns(string dfn) { MdoQuery mq = buildGetVitalSignsRequest(dfn); string response = (string)cxn.query(mq); return(vistaDao.toVitalSignsFromRdv(response)); }
public Consult[] getConsultsForPatient(string dfn) { MdoQuery request = buildGetConsultsForPatientRequest(dfn); string response = (string)cxn.query(request); return(toConsults(response)); }
public CytologyReport[] getCytologyReports(string dfn, string fromDate, string toDate, int nrpts) { string request = buildGetCytologyReportsRequest(dfn, fromDate, toDate, nrpts); string response = (string)cxn.query(request); return(toCytologyReports(response)); }
public string visit() { //if (creds.FederatedUid == VistaConstants.ADMINISTRATIVE_FEDERATED_UID) //{ // creds.LocalUid = VistaAccount.getAdminLocalUid(creds.AuthenticationSource.SiteId.Id); //} validateCredentials(); setupVisit(); MdoQuery request = buildVisitRequest(); string response = (string)cxn.query(request); string[] flds = StringUtils.split(response, StringUtils.CRLF); if (!success(flds)) { throw new UnauthorizedAccessException("Visit failed: Invalid credentials?"); } if (flds.Length >= 8) { cxn.IsTestSource = (flds[7] == "0"); } acct.IsAuthenticated = true; cxn.IsRemote = true; //creds.AuthenticatorId = cxn.DataSource.SiteId.Id; //creds.AuthenticatorName = cxn.DataSource.SiteId.Name; return("OK"); }
internal IList <Medication> refillMeds(IList <string> medsToRefill) { OMP_O09_PID omp_o09 = new OMP_O09_PID(); fillMshSegment(omp_o09.MSH, HL7Constants.FIELD_SEPARATOR.ToString(), "MHV EVAULT", "200MHS", "SYS.MHV.MED.VA.GOV", "DNS", "MHV VISTA", _cxn.DataSource.SiteId.Id, _cxn.DataSource.Provider, "DNS", "", "OMP", "O09", "OMP_O09", "", "P", "2.4"); //fillMshSegment(omp_o09.MSH, HL7Constants.FIELD_SEPARATOR.ToString(), "", "", "", "", "", // _cxn.DataSource.SiteId.Id, _cxn.DataSource.Provider, "", "", "OMP", "O09", "OMP_O09", "", "T", "2.4"); addIdToPID(omp_o09.getPid(), _cxn.Pid, 1, "", ""); buildRxeAndOrcSegments(omp_o09, medsToRefill); PipeParser pp = new PipeParser(); string request = pp.Encode(omp_o09); string response = (string)_cxn.query(request); return(new RxRefillDecoder().parse(response)); //throw new NotImplementedException("This function needs to be completed."); }
internal IList <Medication> getMedsHl7() { QBP_Q13_PID msg = new QBP_Q13_PID(); fillMshSegment(msg.MSH, HL7Constants.FIELD_SEPARATOR.ToString(), "MHV EVAULT", "200MHS", "127.0.0.1", "DNS", "MHV VISTA", _cxn.DataSource.SiteId.Id, _cxn.DataSource.Provider, "DNS", "", "QBP", "Q13", "QBP_Q13", "", "P", "2.4"); fillQpdSegment(msg, msg.QPD, "0", new DateTime(), new DateTime(), "", "Q13", "RxList"); addIdToPID(msg.getPid(), _cxn.Pid, 1, "", ""); fillRdfSegment(msg.RDF, DATA_FIELDs); fillRcpSegment(msg.RCP); string response = (string)_cxn.query(msg.encode()); return(toMedsFromHL7(response)); }
public static string getVariableValue(AbstractConnection cxn, string arg) { MdoQuery request = buildGetVariableValueRequest(arg); string response = ""; try { response = (string)cxn.query(request); return(response); } catch (Exception exc) { throw new MdoException(request, response, exc); } }
//public VistaRpcQuery executePlus(MdoQuery vq) //{ // if (cxn.Account.PrimaryPermission == null || // String.IsNullOrEmpty(cxn.Account.PrimaryPermission.Name)) // { // throw new UnauthorizedAccessException("Current context is empty"); // } // AbstractPermission currentContext = cxn.Account.PrimaryPermission; // if (currentContext.Name != VistaConstants.MDWS_CONTEXT && currentContext.Name != VistaConstants.DDR_CONTEXT) // { // changeContext(cxn); // } // VistaRpcQuery result = ((VistaConnection)cxn).query(vq, null, true); // if (currentContext.Name != VistaConstants.MDWS_CONTEXT && currentContext.Name != VistaConstants.DDR_CONTEXT) // { // ((VistaAccount)cxn.Account).setContext(currentContext); // } // return result; //} public string execute(MdoQuery vq) { if (cxn.Account.PrimaryPermission == null || String.IsNullOrEmpty(cxn.Account.PrimaryPermission.Name)) { throw new UnauthorizedAccessException("Current context is empty"); } AbstractPermission currentContext = cxn.Account.PrimaryPermission; if (currentContext.Name != VistaConstants.MDWS_CONTEXT && currentContext.Name != VistaConstants.DDR_CONTEXT) { changeContext(cxn); } string response = (string)cxn.query(vq); if (currentContext.Name != VistaConstants.MDWS_CONTEXT && currentContext.Name != VistaConstants.DDR_CONTEXT) { ((VistaAccount)cxn.Account).setContext(currentContext); } return(response); }
static string sendCachedBuildDdrFilerCreateCptRecordString(AbstractConnection cxn) { String cachedRequestStr = "[XWB]113021.108\tDDR FILER50003ADDf2008\"IENs\",100570551t001102081^.01^+70551,^70551t001203081^2^+70551,^MRI BRAIN W/O DYEt001301681^3^+70551,^238t001401481^6^+70551,^Ct001502081^8^+70551,^2900101f"; return(toCreateUpdateDeleteRecordResponse((String)cxn.query(cachedRequestStr))); }
public IList <EwlItem> getEwl(string pid, string status, string startDate, string stopDate) { MdoQuery request = buildGetEwlQuery(pid, status, startDate, stopDate); string response = (string)cxn.query(request); return(toEwl(response)); }
public string getLrDfn(string dfn) { MdoQuery request = buildGetLrDfnRequest(dfn); string response = (string)cxn.query(request); return(response); }
/// <summary> /// Turn a DFN in to a LRDFN. Can be a long running query as it traverses the entire patient file until a record is found with the specified LRDFN. /// Only use if you absolutely need to find the patient's DFN when starting with only the LRDFN! /// </summary> /// <param name="lrdfn">LAB DATA (63) file ID</param> /// <returns></returns> public string getDfnFromLrdfn(string lrdfn) { MdoQuery request = buildGetDfnFromLrdfnRequest(lrdfn); string response = (string)cxn.query(request); return(response); }