예제 #1
0
        public IList <PatientRequest> GetPengingQueue()
        {
            //TODO: add filters
            var patientQueries = _patientRequestsRepository.GetAll(x => x.Status == PatientRequestStatuses.AwaitingForDonor,
                                                                   q => q.Include(x => x.PatientInfo));

            return(SortQueue(patientQueries));
        }
예제 #2
0
 public IList <PatientRequest> GetPatientRequests()
 {
     return(_patientRequestsRepository.GetAll(
                include: x => x.Include(p => p.RequestsRelation)
                .Include(p => p.OrganInfo)
                .Include(p => p.PatientInfo)
                .Include(p => p.RequestsRelation))
            .OrderBy(p => p.OrganInfo.Name)
            .ThenByDescending(p => p.Priority)
            .ThenBy(p => p.Created)
            .ToList());
 }