Ejemplo n.º 1
0
        public IEnumerable <Doctor> GetFilteredDoctors(DoctorFilter filter)
        {
            ISpecification <Doctor> specification = new DoctorSpecificationConverter(filter).GetSpecification();
            var doctors = Find(specification);

            Bind(doctors);
            return(doctors);
        }
Ejemplo n.º 2
0
        public IEnumerable <Doctor> GetFilteredDoctors(DoctorFilter filter)
        {
            ISpecification <Doctor> specification = new DoctorSpecificationConverter(filter).GetSpecification();
            var doctors   = Find(specification);
            var eagerDocs = GetAllEager();
            IEnumerable <Doctor> result = new List <Doctor>();

            foreach (var doctor in doctors)
            {
                foreach (var eagerDoc in eagerDocs)
                {
                    if (doctor.GetId() == eagerDoc.GetId())
                    {
                        result.Append(eagerDoc);
                    }
                }
            }
            return(result);
        }