Exemplo n.º 1
0
 public async Task <IReadOnlyCollection <ReadModelDto> > ModelPaginationAsync(
     int pageNumber,
     int itemsCount,
     CancellationToken token) =>
 Mapper.Map <IEnumerable <Model>, IReadOnlyCollection <ReadModelDto> >(await ModelRepository.FetchAsync(
                                                                           itemsCount,
                                                                           itemsCount * (pageNumber - 1),
                                                                           token));