Spring Boot, Sorting, Searching, Filtering, Pagination.
searchRequest.getSortBy().isBlank()){ sortBy = "id"; } if(searchRequest.getDirection() == null || searchRequest.getDirection().isBlank()){ direction = "DESC"; } sortDirection = Sort.Direction.fromString(direction); return PageRequest.of(searchRequest.getPageNo(), searchRequest.getPageSize(),