Reviewers: ,


Please review this at http://codereview.tryton.org/403001/

Affected files:
  M tryton/gui/window/view_form/view/list_gtk/parser.py


Index: tryton/gui/window/view_form/view/list_gtk/parser.py
===================================================================

--- a/tryton/gui/window/view_form/view/list_gtk/parser.py
+++ b/tryton/gui/window/view_form/view/list_gtk/parser.py
@@ -64,13 +64,11 @@
     store = treeview.get_model()
     unsaved_records = [x for x in store.group if x.id < 0]
     search_string = screen.screen_container.get_text() or None
-    if screen.search_count == len(store):
+    if screen.search_count == len(store) or unsaved_records:
ids = screen.search_filter(search_string=search_string, only_ids=True)
         store.sort(ids)
     else:
         screen.search_filter(search_string=search_string)
-    for record in unsaved_records:
-        store.group.append(record)


 def realized(func):



--
[email protected] mailing list

Reply via email to