diff --git a/product/ERP5Form/ListBox.py b/product/ERP5Form/ListBox.py index 30a61f7a44afbf28bfbadd827528f036538f2421..25f2611ff157464b7f9bbbbe3f312e1fc125d133 100644 --- a/product/ERP5Form/ListBox.py +++ b/product/ERP5Form/ListBox.py @@ -1445,7 +1445,6 @@ class ListBoxRenderer: selection_name = self.getSelectionName() start = self.getLineStart() max_lines = self.getMaxLineNumber() - report_section_list = [] if self.isReportTreeMode(): @@ -2152,6 +2151,10 @@ class ListBoxHTMLRenderer(ListBoxRenderer): def getMaxLineNumber(self): """Return the maximum number of lines shown in a page. """ + list_lines =self.getParamDict().get('list_lines', None) + if list_lines is not None: + # it's possible to override max lines from selection parameters + return list_lines return self.field.get_value('lines') getMaxLineNumber = VolatileCachingMethod(getMaxLineNumber)