From ccc75fb5e558add3b28029aecbef0ca030edd8a2 Mon Sep 17 00:00:00 2001 From: Calvin Date: Wed, 19 Sep 2012 23:11:00 +0800 Subject: [PATCH] fix bug of pagination --- examples/quickstart/src/main/webapp/WEB-INF/tags/pagination.tag | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/quickstart/src/main/webapp/WEB-INF/tags/pagination.tag b/examples/quickstart/src/main/webapp/WEB-INF/tags/pagination.tag index e6da2f1d..2e4e1262 100644 --- a/examples/quickstart/src/main/webapp/WEB-INF/tags/pagination.tag +++ b/examples/quickstart/src/main/webapp/WEB-INF/tags/pagination.tag @@ -7,7 +7,7 @@ <% int current = page.getNumber() + 1; int begin = Math.max(1, current - paginationSize/2); -int end = Math.min(begin + paginationSize/2 - 1, page.getTotalPages()); +int end = Math.min(begin + (paginationSize - 1), page.getTotalPages()); request.setAttribute("current", current); request.setAttribute("begin", begin);