getMOSReport() 공개 메소드

public getMOSReport ( gov.va.medora.mdo.dao.AbstractConnection cxn, Patient patient ) : TextReport
cxn gov.va.medora.mdo.dao.AbstractConnection
patient Patient
리턴 TextReport
예제 #1
0
파일: PatientLib.cs 프로젝트: OSEHRA/mdws
        public TaggedText getMOSReport(string appPwd, string EDIPI)
        {
            TaggedText result = new TaggedText();

            if (String.IsNullOrEmpty(appPwd))
            {
                result.fault = new FaultTO("Missing appPwd");
            }
            else if (String.IsNullOrEmpty(EDIPI))
            {
                result.fault = new FaultTO("Missing EDIPI");
            }

            if (result.fault != null)
            {
                return result;
            }

            try
            {
                AbstractConnection cxn = new MdoOracleConnection(new DataSource() { ConnectionString = mySession.MdwsConfiguration.MosConnectionString });
                PatientApi api = new PatientApi();
                Patient p = new Patient() { EDIPI = EDIPI };
                TextReport rpt = api.getMOSReport(cxn, p);
                result.text = rpt.Text;
                result.tag = "VADIR";
            }
            catch (Exception exc)
            {
                result.fault = new FaultTO(exc);
            }
            return result;
        }