Author: lektran
Date: Tue Jun 12 00:14:11 2007 New Revision: 546401 URL: http://svn.apache.org/viewvc?view=rev&rev=546401 Log: Reverting commit r544779 based on advice from Ray Barlow, not apllicable to the 4.0 branch Modified: ofbiz/branches/release4.0/applications/order/webapp/ordermgr/entry/catalog/keywordsearch.ftl Modified: ofbiz/branches/release4.0/applications/order/webapp/ordermgr/entry/catalog/keywordsearch.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/release4.0/applications/order/webapp/ordermgr/entry/catalog/keywordsearch.ftl?view=diff&rev=546401&r1=546400&r2=546401 ============================================================================== --- ofbiz/branches/release4.0/applications/order/webapp/ordermgr/entry/catalog/keywordsearch.ftl (original) +++ ofbiz/branches/release4.0/applications/order/webapp/ordermgr/entry/catalog/keywordsearch.ftl Tue Jun 12 00:14:11 2007 @@ -31,23 +31,23 @@ <#if productIds?has_content> <div class="product-prevnext"> <#-- Start Page Select Drop-Down --> - <#assign viewIndexMax = Static["java.lang.Math"].ceil((listSize - 1)?double / viewSize?double)> + <#assign viewIndexMax = Static["java.lang.Math"].ceil(listSize?double / viewSize?double)> <select name="pageSelect" class="selectBox" onchange="window.location=this[this.selectedIndex].value;"> - <option value="#">${uiLabelMap.CommonPage} ${viewIndex?int + 1} ${uiLabelMap.CommonOf} ${viewIndexMax + 1}</option> - <#list 0..viewIndexMax as curViewNum> - <option value="<@ofbizUrl>keywordsearch/~VIEW_SIZE=${viewSize}/~VIEW_INDEX=${curViewNum?int}/~clearSearch=N</@ofbizUrl>">${uiLabelMap.CommonGotoPage} ${curViewNum + 1}</option> + <option value="#">${uiLabelMap.CommonPage} ${viewIndex?int + 1} ${uiLabelMap.CommonOf} ${viewIndexMax}</option> + <#list 1..viewIndexMax as curViewNum> + <option value="<@ofbizUrl>keywordsearch/~VIEW_INDEX=${curViewNum?int - 1}/~VIEW_SIZE=${viewSize}/~clearSearch=N</@ofbizUrl>">${uiLabelMap.CommonGotoPage} ${curViewNum}</option> </#list> </select> <#-- End Page Select Drop-Down --> <b> - <#if (viewIndex?int > 0)> - <a href="<@ofbizUrl>keywordsearch/~VIEW_SIZE=${viewSize}/~VIEW_INDEX=${viewIndex?int - 1}/~clearSearch=N</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonPrevious}</a> | + <#if 0 < viewIndex?int> + <a href="<@ofbizUrl>keywordsearch/~VIEW_INDEX=${viewIndex-1}/~VIEW_SIZE=${viewSize}/~clearSearch=N</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonPrevious}</a> | </#if> - <#if (listSize?int > 0)> + <#if 0 < listSize?int> <span class="tabletext">${lowIndex+1} - ${highIndex} ${uiLabelMap.CommonOf} ${listSize}</span> </#if> <#if highIndex?int < listSize?int> - | <a href="<@ofbizUrl>keywordsearch/~VIEW_SIZE=${viewSize}/~VIEW_INDEX=${viewIndex+1}/~clearSearch=N</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonNext}</a> + | <a href="<@ofbizUrl>keywordsearch/~VIEW_INDEX=${viewIndex+1}/~VIEW_SIZE=${viewSize}/~clearSearch=N</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonNext}</a> </#if> </b> </div> @@ -66,23 +66,23 @@ <#if productIds?has_content> <div class="product-prevnext"> <#-- Start Page Select Drop-Down --> - <#assign viewIndexMax = Static["java.lang.Math"].ceil((listSize - 1)?double / viewSize?double)> + <#assign viewIndexMax = Static["java.lang.Math"].ceil(listSize?double / viewSize?double)> <select name="pageSelect" class="selectBox" onchange="window.location=this[this.selectedIndex].value;"> - <option value="#">${uiLabelMap.CommonPage} ${viewIndex?int + 1} ${uiLabelMap.CommonOf} ${viewIndexMax + 1}</option> - <#list 0..viewIndexMax as curViewNum> - <option value="<@ofbizUrl>keywordsearch/~VIEW_SIZE=${viewSize}/~VIEW_INDEX=${curViewNum?int}/~clearSearch=N</@ofbizUrl>">${uiLabelMap.CommonGotoPage} ${curViewNum + 1}</option> + <option value="#">${uiLabelMap.CommonPage} ${viewIndex?int + 1} ${uiLabelMap.CommonOf} ${viewIndexMax}</option> + <#list 1..viewIndexMax as curViewNum> + <option value="<@ofbizUrl>keywordsearch/~VIEW_INDEX=${curViewNum?int - 1}/~VIEW_SIZE=${viewSize}/~clearSearch=N</@ofbizUrl>">${uiLabelMap.CommonGotoPage} ${curViewNum}</option> </#list> </select> <#-- End Page Select Drop-Down --> <b> - <#if (viewIndex?int > 0)> - <a href="<@ofbizUrl>keywordsearch/~VIEW_SIZE=${viewSize}/~VIEW_INDEX=${viewIndex?int - 1}/~clearSearch=N</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonPrevious}</a> | + <#if 0 < viewIndex?int> + <a href="<@ofbizUrl>keywordsearch/~VIEW_INDEX=${viewIndex-1}/~VIEW_SIZE=${viewSize}/~clearSearch=N</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonPrevious}</a> | </#if> - <#if (listSize?int > 0)> + <#if 0 < listSize?int> <span class="tabletext">${lowIndex+1} - ${highIndex} ${uiLabelMap.CommonOf} ${listSize}</span> </#if> <#if highIndex?int < listSize?int> - | <a href="<@ofbizUrl>keywordsearch/~VIEW_SIZE=${viewSize}/~VIEW_INDEX=${viewIndex+1}/~clearSearch=N</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonNext}</a> + | <a href="<@ofbizUrl>keywordsearch/~VIEW_INDEX=${viewIndex+1}/~VIEW_SIZE=${viewSize}/~clearSearch=N</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonNext}</a> </#if> </b> </div> |
Free forum by Nabble | Edit this page |