public PartialViewResult SearchUniqueParticipantID(int?page, bool?refresh, string uniqueParticipantID)
        {
            if (!String.IsNullOrEmpty(uniqueParticipantID))
            {
                var entries = RetrievedResult
                              .Where(s => s.UniqueParticipantId != null && s.UniqueParticipantId.ToUpper().Contains(uniqueParticipantID.Trim().ToUpper()))
                              .OrderByDescending(x => x.ProcessDatetime)
                              .GroupBy(x => new { x.URI, x.ProcessDatetime, x.ProcessErrorDescr })
                              .Select(g => new UpassFileDetail
                {
                    InstitutionID       = InstitutionID,
                    Category            = g.First().Category,
                    CategoryID          = g.First().CategoryID,
                    CardSerialNumber    = g.First().CardSerialNumber,
                    UniqueParticipantId = g.First().UniqueParticipantId,
                    Event           = g.First().Event,
                    EventID         = g.First().EventID,
                    URI             = g.First().URI,
                    ProcessDatetime = g.Key.ProcessDatetime,
                    Errors          = g.Where(r => r.Level == EVENT_STATUS.ERROR).Count(),
                    ClearedErrors   = g.Where(c => c.Level == EVENT_STATUS.CLEARED).Count(),
                    Acknowledged    = g.Where(a => a.Level == EVENT_STATUS.ACKNOWLEDGED).Count(),
                });
                SearchResult = entries.ToList();
            }
            else
            {
                SearchResult = null;
            }

            SetViewBags();
            CurrentSearchKeyword = " Unique Participant ID contains '" + uniqueParticipantID + "'";
            ViewBag.keyword      = CurrentSearchKeyword;
            return(PartialView("_FileDetails", null));
        }
        public PartialViewResult SearchFileName(int?page, bool?refresh, string fileName)
        {
            if (!String.IsNullOrEmpty(fileName))
            {
                SearchResult = RetrievedResult.Where(s => s.URI != null && (Path.GetFileName(s.URI)).ToUpper().Contains(fileName.Trim().ToUpper())).ToList();
            }
            else
            {
                SearchResult = null;
            }
            SetViewBags();

            CurrentSearchKeyword = string.Format(" File Name contains '{0}'", fileName);
            ViewBag.keyword      = CurrentSearchKeyword;

            return(PartialView("_PartialFiles", null));
        }
        public PartialViewResult SearchUniqueParticipantID(int?page, bool?refresh, string uniqueParticipantID)
        {
            if (!String.IsNullOrEmpty(uniqueParticipantID))
            {
                process(page, InstitutionID, Uri, UniqueParticipantID, DateStartTicks, CategoryID, EventID, null);
                SearchResult = RetrievedResult.Where(s => s.UniqueParticipantId != null && s.UniqueParticipantId.ToUpper().Contains(uniqueParticipantID.Trim().ToUpper())).ToList();
            }
            else
            {
                SearchResult = null;
            }

            SetViewBags();
            CurrentSearchKeyword = " Unique Participant ID contains '" + uniqueParticipantID + "'";
            ViewBag.keyword      = CurrentSearchKeyword;
            return(PartialView("_FileDetails", null));
        }