From e1c87ca5434cdc4059902f7c0b19f3f3632bd95d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sun, 31 Oct 2021 10:20:24 +0100 Subject: [PATCH] Do not display search_count if it is not higher than limit On small set of record when records are deleted the number of record could become lower than the initial search_count. As maintaining a correct search_count is complex, it is simpler to never display it if it is lower than the search limit. issue10789 review383501003 (grafted from 07165c9a8fc19768f45170df622e0998e85abee5) --HG-- branch : 6.0 --- tryton/gui/window/form.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tryton/gui/window/form.py b/tryton/gui/window/form.py index 01f5e685cc..054ba93618 100644 --- a/tryton/gui/window/form.py +++ b/tryton/gui/window/form.py @@ -640,7 +640,8 @@ class Form(SignalEvent, TabContent): menu_save.props.sensitive = not self.screen.readonly msg = name + ' / ' + str(signal_data[1]) - if signal_data[1] < signal_data[2]: + if (signal_data[1] < signal_data[2] + and signal_data[2] > self.screen.limit): msg += _(' of ') + str(signal_data[2]) self.status_label.set_text(msg) self.message_info()