/// <summary> /// 分页获取 /// </summary> /// <param name="orderInfoPageRequestDto"></param> /// <returns></returns> public async Task <PageData> GetPageListAsync(OrderInfoPageRequestDto orderInfoPageRequestDto) { var pageData = new PageData(orderInfoPageRequestDto.PageIndex, orderInfoPageRequestDto.PageSize); var list = await _orderRespository.Entities(e => e.IsDelete == false).ToPaginated(pageData).ToListAsync(); return(pageData); }
public async Task <OrderInfoQueryDto> GetForModifyAsync(EntityQueryRequest entityQueryRequest) { var entity = await _orderRespository.Entities(e => e.Id == entityQueryRequest.Id).SingleOrDefaultAsync(); if (entity != null) { return(entity.MapEntity <OrderInfo, OrderInfoQueryDto>());//_mapper.Map<OrderInfo, OrderInfoQueryDto>(entity); } return(null); }