"Applied fix from trunk for revision: 1560176  " 
------------------------------------------------------------------------
r1560176 | jleroux | 2014-01-21 21:53:29 +0100 (mar. 21 janv. 2014) | 20 lignes

A patch from  Gareth Carter for "last index for paging is not calculated correctly" https://issues.apache.org/jira/browse/OFBIZ-5497

The last index (used on the last button) is not calculated correctly in ftl or the renderer classes. It currently users floor which works only for list sizes that are not multiples of the view size. When you have a list size which is a multiple of the view size, it does not subtract 1 for zero based index and therefore the last button goes to the last page + 1

Examples

listSize = 1
viewSize = 10
listSize / viewSize = 0.1
floor(0.1) = 0
This one produces the correct value

listSize = 20
viewSize = 10
listSize / viewSize = 2
floor(2) = 2
Last index should be 1 because of zero based index but never occurs

To reproduce, enter a view with a list and paging functionality, the list size must be a multiple of the view size

------------------------------------------------------------------------
?\026

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/branches/release13.07@1560182 13f79535-47bb-0310-9956-ffa450edef68