/// <summary> /// 获取Invoice的分页列表信息 ///</summary> /// <param name="input"></param> /// <returns></returns> public async Task <PagedResultDto <InvoiceListDto> > GetPaged(GetInvoicesInput input) { var query = _entityRepository.GetAll(); // TODO:根据传入的参数添加过滤条件 var count = await query.CountAsync(); var entityList = await query .OrderBy(input.Sorting).AsNoTracking() .PageBy(input) .ToListAsync(); // var entityListDtos = ObjectMapper.Map<List<InvoiceListDto>>(entityList); var entityListDtos = entityList.MapTo <List <InvoiceListDto> >(); return(new PagedResultDto <InvoiceListDto>(count, entityListDtos)); }
public ActionResult Index(GetInvoicesInput input) { return(base.View()); }