[tryton-debian-vcs] tryton-modules-sale branch upstream-2.2 created. d95c44513a496bb1eba8835353347cc911bd34ad

Mathias Behrle tryton-debian-vcs at alioth.debian.org
Wed Nov 27 17:08:43 UTC 2013


The following commit has been merged in the upstream-2.2 branch:
https://alioth.debian.org/plugins/scmgit/cgi-bin/gitweb.cgi/?p=tryton/tryton-modules-sale.git;a=commitdiff;h=d95c44513a496bb1eba8835353347cc911bd34ad
commit d95c44513a496bb1eba8835353347cc911bd34ad
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Sun Feb 24 19:48:25 2013 +0100

    Adding upstream version 2.2.3.

diff --git a/CHANGELOG b/CHANGELOG
index 9c2d639..2a08e05 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 2.2.3 - 2012-11-05
+* Bug fixes (see mercurial logs for details)
+
 Version 2.2.2 - 2012-05-07
 * Bug fixes (see mercurial logs for details)
 
diff --git a/PKG-INFO b/PKG-INFO
index b7072d4..467c044 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: trytond_sale
-Version: 2.2.2
+Version: 2.2.3
 Summary: Define sale order.
 Add to product sale informations.
 Define the sale price as the list price.
diff --git a/__tryton__.py b/__tryton__.py
index 777bbca..36b35aa 100644
--- a/__tryton__.py
+++ b/__tryton__.py
@@ -8,7 +8,7 @@
     'name_es_ES': 'Venta',
     'name_fr_FR': 'Vente',
     'name_nl_NL': 'Verkoop',
-    'version': '2.2.2',
+    'version': '2.2.3',
     'author': 'B2CK',
     'email': 'info at b2ck.com',
     'website': 'http://www.tryton.org/',
diff --git a/sale.py b/sale.py
index 25c3151..adf44cb 100644
--- a/sale.py
+++ b/sale.py
@@ -1044,7 +1044,8 @@ class SaleLine(ModelSQL, ModelView):
             'required': Eval('type') == 'line',
             'readonly': ~Eval('_parent_sale', {}),
             }, on_change=['product', 'quantity', 'unit',
-            '_parent_sale.currency', '_parent_sale.party'],
+            '_parent_sale.currency', '_parent_sale.party',
+            '_parent_sale.sale_date'],
         depends=['type', 'unit_digits'])
     unit = fields.Many2One('product.uom', 'Unit',
             states={
@@ -1070,7 +1071,8 @@ class SaleLine(ModelSQL, ModelView):
             'readonly': ~Eval('_parent_sale', {}),
             },
         on_change=['product', 'unit', 'quantity', 'description',
-            '_parent_sale.party', '_parent_sale.currency'],
+            '_parent_sale.party', '_parent_sale.currency',
+            '_parent_sale.sale_date'],
         context={
             'locations': If(Bool(Eval('_parent_sale', {}).get( 'warehouse')),
                 [Eval('_parent_sale', {}).get('warehouse', 0)], []),
diff --git a/setup.py b/setup.py
index 721a34e..e711ce0 100644
--- a/setup.py
+++ b/setup.py
@@ -67,5 +67,5 @@ setup(name='trytond_sale',
     sale = trytond.modules.sale
     """,
     test_suite='tests',
-    test_loader='trytond.test_loader:Loader',
+    tests_loader='trytond.test_loader:Loader',
 )
diff --git a/trytond_sale.egg-info/PKG-INFO b/trytond_sale.egg-info/PKG-INFO
index 7d649ae..c553d62 100644
--- a/trytond_sale.egg-info/PKG-INFO
+++ b/trytond_sale.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: trytond-sale
-Version: 2.2.2
+Version: 2.2.3
 Summary: Define sale order.
 Add to product sale informations.
 Define the sale price as the list price.
commit 17ac75d9d60e630afe43ecd5881232fef6e2abe8
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Wed May 9 11:47:28 2012 +0200

    Adding upstream version 2.2.2.

diff --git a/CHANGELOG b/CHANGELOG
index c07ac6e..9c2d639 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 2.2.2 - 2012-05-07
+* Bug fixes (see mercurial logs for details)
+
 Version 2.2.1 - 2011-12-26
 * Bug fixes (see mercurial logs for details)
 
diff --git a/COPYRIGHT b/COPYRIGHT
index a9feb41..83c0f58 100644
--- a/COPYRIGHT
+++ b/COPYRIGHT
@@ -1,6 +1,6 @@
-Copyright (C) 2008-2011 Cédric Krier.
+Copyright (C) 2008-2012 Cédric Krier.
 Copyright (C) 2008-2011 Bertrand Chenal.
-Copyright (C) 2008-2011 B2CK SPRL.
+Copyright (C) 2008-2012 B2CK SPRL.
 Copyright (C) 2004-2008 Tiny SPRL.
 
 This program is free software: you can redistribute it and/or modify
diff --git a/PKG-INFO b/PKG-INFO
index d2cf512..b7072d4 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: trytond_sale
-Version: 2.2.1
+Version: 2.2.2
 Summary: Define sale order.
 Add to product sale informations.
 Define the sale price as the list price.
diff --git a/__tryton__.py b/__tryton__.py
index f57b590..777bbca 100644
--- a/__tryton__.py
+++ b/__tryton__.py
@@ -8,7 +8,7 @@
     'name_es_ES': 'Venta',
     'name_fr_FR': 'Vente',
     'name_nl_NL': 'Verkoop',
-    'version': '2.2.1',
+    'version': '2.2.2',
     'author': 'B2CK',
     'email': 'info at b2ck.com',
     'website': 'http://www.tryton.org/',
diff --git a/invoice.py b/invoice.py
index 447bcd0..b936a9a 100644
--- a/invoice.py
+++ b/invoice.py
@@ -9,6 +9,13 @@ class Invoice(ModelSQL, ModelView):
     sales = fields.Many2Many('sale.sale-account.invoice',
             'invoice', 'sale', 'Sales', readonly=True)
 
+    def copy(self, ids, default=None):
+        if default is None:
+            default = {}
+        default = default.copy()
+        default.setdefault('sales', False)
+        return super(Invoice, self).copy(ids, default=default)
+
 Invoice()
 
 
@@ -18,4 +25,11 @@ class InvoiceLine(ModelSQL, ModelView):
     sale_lines = fields.Many2Many('sale.line-account.invoice.line',
             'invoice_line', 'sale_line', 'Sale Lines', readonly=True)
 
+    def copy(self, ids, default=None):
+        if default is None:
+            default = {}
+        default = default.copy()
+        default.setdefault('sale_lines', False)
+        return super(InvoiceLine, self).copy(ids, default=default)
+
 InvoiceLine()
diff --git a/sale.py b/sale.py
index c817e99..25c3151 100644
--- a/sale.py
+++ b/sale.py
@@ -1088,7 +1088,7 @@ class SaleLine(ModelSQL, ModelView):
             states={
                 'invisible': ~Eval('type').in_(['line', 'subtotal']),
                 'readonly': ~Eval('_parent_sale'),
-                }, on_change_with=['type', 'quantity', 'unit_price',
+                }, on_change_with=['type', 'quantity', 'unit_price', 'unit',
                 '_parent_sale.currency'],
             depends=['type']), 'get_amount')
     description = fields.Text('Description', size=None, required=True)
@@ -1370,6 +1370,8 @@ class SaleLine(ModelSQL, ModelView):
         ignored_ids = set(
             l.id for i in line.sale.invoices_ignored for l in i.lines)
         for invoice_line in line.invoice_lines:
+            if invoice_line.type != 'line':
+                continue
             if ((invoice_line.invoice and
                     invoice_line.invoice.state != 'cancel') or
                 invoice_line.id in ignored_ids):
diff --git a/trytond_sale.egg-info/PKG-INFO b/trytond_sale.egg-info/PKG-INFO
index 9f8ee0f..7d649ae 100644
--- a/trytond_sale.egg-info/PKG-INFO
+++ b/trytond_sale.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: trytond-sale
-Version: 2.2.1
+Version: 2.2.2
 Summary: Define sale order.
 Add to product sale informations.
 Define the sale price as the list price.
-- 
tryton-modules-sale



More information about the tryton-debian-vcs mailing list