From afb67bb0b1e7b6d5e47bd9b71cb5bed11c611741 Mon Sep 17 00:00:00 2001
From: Ivan Tyagov <ivan@nexedi.com>
Date: Fri, 10 Sep 2010 13:19:35 +0000
Subject: [PATCH] show current rows (start - stop) only if number of total rows
 > 0.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@38270 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../erp5_xhtml_style/ListBox_asHTMLLibrary.xml  | 17 +++++++++++------
 .../ERP5/bootstrap/erp5_xhtml_style/bt/revision |  2 +-
 2 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml b/product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml
index 9f2a3874e8..c481987fb2 100644
--- a/product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml
+++ b/product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml
@@ -128,18 +128,23 @@
 <div class="listbox-number-of-records"\n
      metal:define-macro="listbox_number_of_records">\n
 \n
-  <span class="listbox-current-page-start-number"\n
-        tal:content="current_page_start"/> - \n
-  <span class="listbox-current-page-stop-number"\n
-        tal:content="current_page_stop"/> \n
-  <span i18n:translate="" i18n:domain="ui">of</span>\n
+  <!-- listbox start - stop number -->\n
+  <tal:block tal:condition="python: total_line > 0">\n
+    <span class="listbox-current-page-start-number"\n
+          tal:content="current_page_start"/> - \n
+    <span class="listbox-current-page-stop-number"\n
+          tal:content="current_page_stop"/> \n
+    <span i18n:translate="" i18n:domain="ui">of</span>\n
+  </tal:block>\n
 \n
+  <!-- listbox total rows number -->\n
   <span class="listbox-current-page-total-number"\n
         tal:attributes="class python: test(is_default_listbox_field, \'listbox-current-page-total-number\', \'listbox-current-page-total-number %s-current-page-total-number\' %field_id)"\n
         i18n:translate="" i18n:domain="ui">\n
     <tal:block tal:replace="total_line" i18n:name="number">0</tal:block> records\n
   </span>\n
-  \n
+\n
+  <!-- listbox selected rows number -->\n
   <span class="listbox-current-item-number"\n
         tal:condition="show_select_column"\n
         tal:attributes="class string:${field_id}-current-item-number"\n
diff --git a/product/ERP5/bootstrap/erp5_xhtml_style/bt/revision b/product/ERP5/bootstrap/erp5_xhtml_style/bt/revision
index 0b9e0ab9d3..028ead5575 100644
--- a/product/ERP5/bootstrap/erp5_xhtml_style/bt/revision
+++ b/product/ERP5/bootstrap/erp5_xhtml_style/bt/revision
@@ -1 +1 @@
-1008
\ No newline at end of file
+1010
\ No newline at end of file
-- 
2.30.9