|
|
|
@ -5,7 +5,7 @@ |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* You may obtain a copy of the License at |
|
|
|
* |
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
* |
|
|
|
* Unless required by applicable law or agreed to in writing, software |
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS, |
|
|
|
@ -315,6 +315,9 @@ public class DefaultEntityQueryRepository implements EntityQueryRepository { |
|
|
|
String countQuery = String.format("select count(id) %s", fromClauseCount); |
|
|
|
int totalElements = jdbcTemplate.queryForObject(countQuery, ctx, Integer.class); |
|
|
|
|
|
|
|
if (totalElements == 0) { |
|
|
|
return new PageData<>(); |
|
|
|
} |
|
|
|
String dataQuery = String.format("select * %s", fromClauseData); |
|
|
|
|
|
|
|
EntityDataSortOrder sortOrder = pageLink.getSortOrder(); |
|
|
|
|