コード例 #1
0
        public static string PutExam(Exam exam)
        {
            WSShieldsApps.ENUMMESSAGE output
                = WSShieldsApps.ENUMMESSAGE.UNKNOWN;

            int examId = -1;

            string exceptionText = GenericUtility.BLANK;

            using (ShieldsAppsClient client = new ShieldsAppsClient())
            {
                try
                {
                    examId = client.InsertExamByHl7(out output, exam, ENTERPRISE_DEFAULT);
                }
                catch (Exception ex)
                {
                    exceptionText = EXCEPTION_FOUND + ex.ToString();
                    client.Close();
                }
            }

            return(GenericUtility.GetHL7TextForServiceMessage(EXAM_UPDATE,
                                                              (exceptionText == GenericUtility.BLANK) ?
                                                              output.ToString()
                                                                : output.ToString() + exceptionText,
                                                              examId.ToString(),
                                                              ENTERPRISE_DEFAULT));
        }
コード例 #2
0
        public static string PutDoctor(WSShieldsApps.Doctor doctor)
        {
            ENUMMESSAGE output
                = ENUMMESSAGE.UNKNOWN;

            string exceptionText = GenericUtility.BLANK;

            using (ShieldsAppsClient client = new ShieldsAppsClient())
            {
                try
                {
                    doctor.DoctorId = client.InsertUpdateDoctor(out output, doctor);
                }
                catch (Exception ex)
                {
                    client.Close();
                }
            }

            return(GenericUtility.GetHL7TextForServiceMessage(DOCTOR_UPDATE,
                                                              (exceptionText == GenericUtility.BLANK) ?
                                                              output.ToString()
                                                         : output.ToString() + exceptionText,
                                                              doctor.DoctorId.ToString(),
                                                              ENTERPRISE_DEFAULT));
        }
コード例 #3
0
        public static string PostReport(WSShieldsApps.Report report, int addendumIteration)
        {
            ENUMMESSAGE output
                = ENUMMESSAGE.UNKNOWN;

            string exceptionText = GenericUtility.BLANK;

            int reportId = -1;

            using (ShieldsAppsClient client = new ShieldsAppsClient())
            {
                try
                {
                    reportId = client.InsertReport(out output, report);
                }
                catch (Exception ex)
                {
                    exceptionText = EXCEPTION_FOUND + ex.ToString();
                    client.Close();
                }
            }

            return(GenericUtility.GetHL7TextForServiceMessage(ADDENDUM_INSERTED + "&" + addendumIteration,
                                                              (exceptionText == GenericUtility.BLANK) ?
                                                              output.ToString()
                                                                    : output.ToString() + exceptionText,
                                                              reportId.ToString(),
                                                              ENTERPRISE_DEFAULT));
        }
コード例 #4
0
 public static Exam GetExamByAccessionNo(WSShieldsApps.Exam exam)
 {
     using (ShieldsAppsClient client = new ShieldsAppsClient())
     {
         try
         {
             exam = client.GetExamByAccessionNo(exam.AccessionNo);
         }
         catch (Exception ex)
         {
             client.Close();
         }
     }
     return(exam);
 }
コード例 #5
0
        public static string PutDoctor(WSShieldsApps.Doctor doctor)
        {
            ENUMMESSAGE output
                = ENUMMESSAGE.UNKNOWN;

            string exceptionText = "";

            using (ShieldsAppsClient client = new ShieldsAppsClient())
            {
                try
                {
                    doctor.DoctorId = client.InsertUpdateDoctor(out output, doctor);
                }
                catch (Exception ex)
                {
                    client.Close();
                }
            }

            return(output.ToString() + " " + exceptionText + " " + doctor.DoctorId.ToString());
        }
コード例 #6
0
        public static string PutExam(Exam exam)
        {
            WSShieldsApps.ENUMMESSAGE output
                = WSShieldsApps.ENUMMESSAGE.UNKNOWN;

            string exceptionText = "";

            using (ShieldsAppsClient client = new ShieldsAppsClient())
            {
                try
                {
                    exam.ExamId = client.InsertExamByHl7(out output, exam, 1);
                }
                catch (Exception ex)
                {
                    exceptionText = ex.ToString();
                    client.Close();
                }
            }

            return(output.ToString() + " " + exceptionText + " " + exam.ExamId.ToString());
        }
コード例 #7
0
        public static string PostReport(WSShieldsApps.Report report, int addendumIteration)
        {
            ENUMMESSAGE output
                = ENUMMESSAGE.UNKNOWN;

            string exceptionText = "";

            int reportId = -1;

            using (ShieldsAppsClient client = new ShieldsAppsClient())
            {
                try
                {
                    reportId = client.InsertReport(out output, report);
                }
                catch (Exception ex)
                {
                    exceptionText = ex.ToString();
                    client.Close();
                }
            }

            return(output.ToString() + " " + exceptionText + " " + reportId.ToString());
        }