예제 #1
0
        public async Task <PagedResultDto <DoctorFileApply> > DoctorFileApplyPage(DoctorFileApplyIn DoctorFileApplyInfo)
        {
            //初步过滤
            var query = _repository.GetAll().OrderByDescending(a => a.CreatedOn).Where(DoctorFileApplyInfo.Expression);
            //获取总数
            var tasksCount = query.Count();
            //获取总数
            var totalpage           = tasksCount / DoctorFileApplyInfo.MaxResultCount;
            var DoctorFileApplyList = await query.PageBy(DoctorFileApplyInfo.SkipTotal, DoctorFileApplyInfo.MaxResultCount).ToListAsync();

            return(new PagedResultDto <DoctorFileApply>(tasksCount, DoctorFileApplyList.MapTo <List <DoctorFileApply> >()));
        }
예제 #2
0
        public async Task <List <DoctorFileApply> > DoctorFileApplyList(DoctorFileApplyIn DoctorFileApplyInfo)
        {
            var DoctorFileApplys = await _repository.GetAllListAsync(DoctorFileApplyInfo.Expression);

            return(DoctorFileApplys);
        }