details: https://code.tryton.org/tryton/commit/1b717a685705
branch: default
user: Nicolas Évrard <[email protected]>
date: Mon Apr 20 10:41:45 2026 +0200
description:
Use a list of selection values to enable sorting in the filter window
Closes #14785
diffstat:
tryton/tryton/gui/window/view_form/view/screen_container.py | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diffs (16 lines):
diff -r 2d774ad0038c -r 1b717a685705
tryton/tryton/gui/window/view_form/view/screen_container.py
--- a/tryton/tryton/gui/window/view_form/view/screen_container.py Mon Apr
20 10:38:52 2026 +0200
+++ b/tryton/tryton/gui/window/view_form/view/screen_container.py Mon Apr
20 10:41:45 2026 +0200
@@ -627,10 +627,10 @@
for selection in selections:
entry.append_text(selection)
elif field['type'] in ['selection', 'multiselection']:
- selections = tuple(x[1] for x in field['selection'])
+ selections = [x[1] for x in field['selection']]
if field.get('sort', True):
selections.sort(key=operator.itemgetter(1))
- entry = Selection(selections)
+ entry = Selection(tuple(selections))
entry.set_vexpand(True)
elif field['type'] in ('date', 'datetime', 'time'):
date_format = common.date_format(