Пример #1
0
        // GET api/values/5
        public PathfinderVideoUI Get(string patientId, string startTime, string endTime)
        {
            if (patientId != null && startTime != null && endTime != null)
            {
                var pve = new PathfinderVideos(patientId, startTime, endTime, GetStorConnStr());


                if (pve == null || pve.Videos.Count == 0)
                {
                    return(null);
                }


                PathfinderVideoUI pathfinderVideoUI = new PathfinderVideoUI(pve.Videos[0]);

                var pathfinderEvents = new PathFinderEvents(patientId, pathfinderVideoUI.StartTime.ToString("yyyyMMddHHmmss"), pathfinderVideoUI.EndTime.ToString("yyyyMMddHHmmss"), null, null, GetStorConnStr());

                foreach (var pe in pathfinderEvents.Events)
                {
                    pathfinderVideoUI.Events.Add(new PathfinderEventUI(pe, pathfinderVideoUI.StartTime));
                }
                //ToDo: Get the URL and Token for video from Media Services
                return(pathfinderVideoUI);
            }
            throw new Exception("Invalid Query Options");
        }
Пример #2
0
 // GET api/values/5
 public IEnumerable <PathfinderVideo> Get(string patientId, string startTime, string endTime)
 {
     if (patientId != null && startTime != null && endTime != null)
     {
         var pv = new PathfinderVideos(patientId, startTime, endTime, GetStorConnStr());
         return(pv.Videos);
     }
     throw new Exception("Invalid Query Options");
 }
Пример #3
0
        // GET api/Patient/<PatientID>
        public IEnumerable <string> Get()
        {
            var pv = new PathfinderVideos(GetStorConnStr());

            return(pv.Videos.Select(x => x.PatientID).Distinct());
        }