SEBSERV-384 fixed

This commit is contained in:
anhefti 2023-03-14 10:07:43 +01:00
parent 9032549f59
commit e63a09847b

View file

@ -412,9 +412,13 @@ public class ConfigurationNodeController extends EntityController<ConfigurationN
if (attrs.size() < end) {
end = attrs.size();
}
int numOfPages = attrs.size() / this.paginationService.getPageSize(pageSize);
if (attrs.size() % this.paginationService.getPageSize(pageSize) != 0) {
numOfPages++;
}
return new Page<>(
attrs.size() / this.paginationService.getPageSize(pageSize),
numOfPages,
this.paginationService.getPageNumber(pageNumber),
sort,
attrs.subList(start, end));