コード例 #1
0
        public PaginationOutputDto GetAll(int page, int pageSize, string sortBy, string sortDirection)
        {
            var entities = _productQueries.GetAll(page, pageSize, sortBy, sortDirection).ToList();

            var pagedRecord = new PaginationOutputDto
            {
                Content      = _productCreateAssembler.FromEntityList(entities),
                TotalRecords = _productQueries.CountAll(),
                CurrentPage  = page,
                PageSize     = pageSize
            };

            return(pagedRecord);
        }