Ejemplo n.º 1
0
 public TaggedInpatientStayArrays getStayMovementsByPatient()
 {
     TaggedInpatientStayArrays result = new TaggedInpatientStayArrays();
     if (!mySession.ConnectionSet.IsAuthorized)
     {
         result.fault = new FaultTO("Connections not ready for operation", "Need to login?");
     }
     if (result.fault != null)
     {
         return result;
     }
     try
     {
         EncounterApi api = new EncounterApi();
         IndexedHashtable t = api.getStayMovementsByPatient(mySession.ConnectionSet, mySession.Patient.LocalPid);
         result = new TaggedInpatientStayArrays(t);
     }
     catch (Exception e)
     {
         result.fault = new FaultTO(e);
     }
     return result;
 }
Ejemplo n.º 2
0
        public TaggedInpatientStayArrays getStayMovementsByDateRange(string fromDate, string toDate)
        {
            TaggedInpatientStayArrays result = new TaggedInpatientStayArrays();
            if (!mySession.ConnectionSet.IsAuthorized)
            {
                result.fault = new FaultTO("Connections not ready for operation", "Need to login?");
            }
            else if (fromDate == "")
            {
                result.fault = new FaultTO("Missing fromDate");
            }
            else if (toDate == "")
            {
                result.fault = new FaultTO("Missing toDate");
            }
            if (result.fault != null)
            {
                return result;
            }

            try
            {
                EncounterApi api = new EncounterApi();
                IndexedHashtable t = api.getStayMovementsByDateRange(mySession.ConnectionSet,fromDate,toDate);
                result = new TaggedInpatientStayArrays(t);
            }
            catch (Exception e)
            {
                result.fault = new FaultTO(e);
            }
            return result;
        }