[tryton-debian-vcs] tryton-client branch debian-wheezy-2.6 updated. debian/2.6.12-1-2-g3b231fb

Mathias Behrle tryton-debian-vcs at alioth.debian.org
Wed Oct 8 16:49:53 UTC 2014


The following commit has been merged in the debian-wheezy-2.6 branch:
https://alioth.debian.org/plugins/scmgit/cgi-bin/gitweb.cgi/?p=tryton/tryton-client.git;a=commitdiff;h=debian/2.6.12-1-2-g3b231fb

commit 3b231fbff462aa28e142e650b0c00b922be34d7e
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Wed Oct 8 13:53:11 2014 +0200

    Releasing debian version 2.6.13-1.
    
    Signed-off-by: Mathias Behrle <mathiasb at m9s.biz>

diff --git a/debian/changelog b/debian/changelog
index 69beb48..3dc0796 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+tryton-client (2.6.13-1) unstable; urgency=medium
+
+  * Merging upstream version 2.6.13.
+
+ -- Mathias Behrle <mathiasb at m9s.biz>  Wed, 08 Oct 2014 13:53:11 +0200
+
 tryton-client (2.6.12-1) unstable; urgency=medium
 
   * Merging upstream version 2.6.12.
commit 6dc3a93c26f7807e05acbaebd62bd06d3ba2195c
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Wed Oct 8 13:53:09 2014 +0200

    Merging upstream version 2.6.13.

diff --git a/CHANGELOG b/CHANGELOG
index 822a872..7c5209c 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 2.6.13 - 2014-09-29
+* Bug fixes (see mercurial logs for details)
+
 Version 2.6.12 - 2014-08-03
 * Bug fixes (see mercurial logs for details)
 
diff --git a/PKG-INFO b/PKG-INFO
index 4aa65e6..a0f1c58 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: tryton
-Version: 2.6.12
+Version: 2.6.13
 Summary: Tryton client
 Home-page: http://www.tryton.org/
 Author: B2CK
diff --git a/tryton.egg-info/PKG-INFO b/tryton.egg-info/PKG-INFO
index 4aa65e6..a0f1c58 100644
--- a/tryton.egg-info/PKG-INFO
+++ b/tryton.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: tryton
-Version: 2.6.12
+Version: 2.6.13
 Summary: Tryton client
 Home-page: http://www.tryton.org/
 Author: B2CK
diff --git a/tryton/common/domain_inversion.py b/tryton/common/domain_inversion.py
index 3da2b04..d2ad5ae 100644
--- a/tryton/common/domain_inversion.py
+++ b/tryton/common/domain_inversion.py
@@ -47,18 +47,21 @@ def is_leaf(expression):
         and expression[1] in OPERATORS)
 
 
+def constrained_leaf(part, boolop=operator.and_):
+    field, operand, value = part[:3]
+    if operand == '=' and boolop == operator.and_:
+        # We should consider that other domain inversion will set a correct
+        # value to this field
+        return True
+    return False
+
+
 def eval_leaf(part, context, boolop=operator.and_):
     field, operand, value = part[:3]
     if '.' in field:
         # In the case where the leaf concerns a m2o then having a value in the
         # evaluation context is deemed suffisant
         return bool(context.get(field.split('.')[0]))
-    if (operand == '='
-            and context.get(field) is None
-            and boolop == operator.and_):
-        # We should consider that other domain inversion will set a correct
-        # value to this field
-        return True
     context_field = context.get(field)
     if isinstance(context_field, datetime.date) and not value:
         if isinstance(context_field, datetime.datetime):
@@ -231,7 +234,8 @@ class And(object):
                 field = part[0]
                 if (field not in context
                     or field in context
-                    and eval_leaf(part, context, operator.and_)):
+                    and (eval_leaf(part, context, operator.and_)
+                            or constrained_leaf(part, operator.and_))):
                     result.append(True)
                 else:
                     return False
@@ -274,7 +278,8 @@ class Or(And):
                 field = part[0]
                 field = self.base(field)
                 if (field in context
-                        and eval_leaf(part, context, operator.or_)):
+                        and (eval_leaf(part, context, operator.or_)
+                                or constrained_leaf(part, operator.or_))):
                     return True
                 elif (field in context
                         and not eval_leaf(part, context, operator.or_)):
@@ -367,7 +372,7 @@ def test_andor_inversion():
 def test_andand_inversion():
     domain = [[['x', '=', 4], ['y', '>', 6]], ['z', '=', 3]]
     assert domain_inversion(domain, 'z') == [['z', '=', 3]]
-    assert domain_inversion(domain, 'z', {'x': 5}) == False
+    assert domain_inversion(domain, 'z', {'x': 5}) == [['z', '=', 3]]
     assert domain_inversion(domain, 'z', {'y': 5}) == False
     assert domain_inversion(domain, 'z', {'x': 4, 'y': 7}) == [['z', '=', 3]]
 
diff --git a/tryton/gui/window/view_form/screen/screen.py b/tryton/gui/window/view_form/screen/screen.py
index 7346728..d1ec7b3 100644
--- a/tryton/gui/window/view_form/screen/screen.py
+++ b/tryton/gui/window/view_form/screen/screen.py
@@ -584,12 +584,13 @@ class Screen(SignalEvent):
 
         if delete:
             for record in records:
-                if record.parent:
-                    record.parent.save(force_reload=False)
                 if record in record.group.record_deleted:
                     record.group.record_deleted.remove(record)
                 if record in record.group.record_removed:
                     record.group.record_removed.remove(record)
+                if record.parent:
+                    # Save parent without deleted children
+                    record.parent.save(force_reload=False)
                 record.destroy()
 
         if idx > 0:
diff --git a/tryton/gui/window/win_export.py b/tryton/gui/window/win_export.py
index d67c155..c7a7314 100644
--- a/tryton/gui/window/win_export.py
+++ b/tryton/gui/window/win_export.py
@@ -289,7 +289,7 @@ class WinExport(NoModal):
             return
         try:
             lines = RPCExecute('model', 'ir.export.line', 'read',
-                sum((x['export_fields'] for x in exports), []), None)
+                sum((list(x['export_fields']) for x in exports), []), None)
         except RPCException:
             return
         id2lines = {}
diff --git a/tryton/version.py b/tryton/version.py
index ab4a797..2c927dc 100644
--- a/tryton/version.py
+++ b/tryton/version.py
@@ -1,6 +1,6 @@
 #This file is part of Tryton.  The COPYRIGHT file at the top level of
 #this repository contains the full copyright notices and license terms.
 PACKAGE = "tryton"
-VERSION = "2.6.12"
+VERSION = "2.6.13"
 LICENSE = "GPL-3"
 WEBSITE = "http://www.tryton.org/"
-- 
tryton-client



More information about the tryton-debian-vcs mailing list