示例#1
0
        public List <ExamType> GetExamTypeeBySearch(ExamTypeSearchCriteria model)
        {
            IQueryable <ExamType> examTypes = db.ExamTypes.Where(c => c.isDelete == false).AsQueryable();

            if (!string.IsNullOrEmpty(model.Name))
            {
                examTypes = examTypes.Where(c => c.Name.ToLower().Contains(model.Name.ToLower()));
            }

            return(examTypes.ToList());
        }
        //
        // GET: /ExamType/
        public ActionResult Index(ExamTypeSearchCriteria model)
        {
            var examtypes = _examTypeManager.GetExamTypeeBySearch(model);

            if (examtypes == null)
            {
                examtypes = new List <ExamType>();
            }


            model.ExamTypes = examtypes;
            return(View(model));
        }
示例#3
0
 public List <ExamType> GetExamTypeeBySearch(ExamTypeSearchCriteria model)
 {
     return(_examTypeRepository.GetExamTypeeBySearch(model));
 }