From bb13bb5b480a688fed453dedfd66f8b98ef03552 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Mon, 22 Oct 2012 23:00:03 +0200 Subject: [PATCH 01/32] Increase version number --- tryton.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tryton.cfg b/tryton.cfg index 45c57532f8..18627e87cb 100644 --- a/tryton.cfg +++ b/tryton.cfg @@ -1,5 +1,5 @@ [tryton] -version=2.6.0 +version=2.6.1 depends: company currency From 5dfef5fab463d3f64d323b291e8a6eed5c1885e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 25 Dec 2012 11:28:05 +0100 Subject: [PATCH 02/32] Fix typo in complete_lines issue2938 (transplanted from 151553ec11b5ff1eac9149fbf115b4b2d726c2a8) --- inventory.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inventory.py b/inventory.py index 81191a7a45..1817fd533f 100644 --- a/inventory.py +++ b/inventory.py @@ -149,8 +149,8 @@ class Inventory(Workflow, ModelSQL, ModelView): new_inventories.append(new_inventory) return new_inventories - @classmethod - def complete_lines(self, inventories): + @staticmethod + def complete_lines(inventories): ''' Complete or update the inventories ''' From e9832a1966f9ee230b186252be36e12729dfbcaa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 1 Jan 2013 22:23:32 +0100 Subject: [PATCH 03/32] Fix test on consumable in complete_lines (transplanted from e77faf01ac6412844f2a17b7160682e7ea7e2b11) --- inventory.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inventory.py b/inventory.py index 1817fd533f..d8de0fb22e 100644 --- a/inventory.py +++ b/inventory.py @@ -196,7 +196,7 @@ class Inventory(Workflow, ModelSQL, ModelView): # Create lines if needed for product_id in product_qty: if (product2type[product_id] != 'goods' - and not product2consumable[product_id]): + or product2consumable[product_id]): continue quantity, uom_id = product_qty[product_id] values = Line.create_values4complete(product_id, inventory, From 88258984cbcaaf7c512bde36a99d93a6adc1c23d Mon Sep 17 00:00:00 2001 From: Ian Wilson Date: Wed, 16 Jan 2013 12:24:27 -0800 Subject: [PATCH 04/32] Fix logic error in _set_warehouse_parent method. The `if to_update:` conditional should be inside the for loop of the method _set_warehouse_parent on the Location model. Clear the set after write. issue2951 review629004 (transplanted from 1b315604e53eed2c10fdab06fd7e78f81e35aad5) --- location.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/location.py b/location.py index 657d93ab7c..d6146ddb89 100644 --- a/location.py +++ b/location.py @@ -228,10 +228,11 @@ class Location(ModelSQL, ModelView): to_update.add(location.output_location) if not location.storage_location.parent: to_update.add(location.storage_location) - if to_update: - cls.write(list(to_update), { - 'parent': location.id, - }) + if to_update: + cls.write(list(to_update), { + 'parent': location.id, + }) + to_update.clear() @classmethod def create(cls, vals): From 31c856c01ca99cecec6985ae11d01e8bb8bb2b3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 12 Feb 2013 18:15:42 +0100 Subject: [PATCH 05/32] Prepare release 2.6.1 --- CHANGELOG | 3 +++ COPYRIGHT | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 907a61ccc7..ceabd66622 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +Version 2.6.1 - 2013-02-12 +* Bug fixes (see mercurial logs for details) + Version 2.6.0 - 2012-10-22 * Bug fixes (see mercurial logs for details) * Add Product Quantities By Warehouse diff --git a/COPYRIGHT b/COPYRIGHT index 2eaddc3007..5d0e16a6ef 100644 --- a/COPYRIGHT +++ b/COPYRIGHT @@ -1,7 +1,7 @@ Copyright (C) 2012 Openlabs Technologies & Consulting (P) LTD. -Copyright (C) 2008-2012 Cédric Krier. +Copyright (C) 2008-2013 Cédric Krier. Copyright (C) 2008-2012 Bertrand Chenal. -Copyright (C) 2008-2012 B2CK SPRL. +Copyright (C) 2008-2013 B2CK SPRL. Copyright (C) 2004-2008 Tiny SPRL. This program is free software: you can redistribute it and/or modify From 0724ce94d276464ac9259d8b75460d9a2a7a0f6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 12 Feb 2013 18:15:43 +0100 Subject: [PATCH 06/32] Added tag 2.6.1 for changeset 59f2d565d042 --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 86a70c8cf3..6113a7859f 100644 --- a/.hgtags +++ b/.hgtags @@ -7,3 +7,4 @@ c2e3b9e568b73f262ebf0b69c2ca98f97cbb886e 2.0.0 3babec8ed968fa95e07a7d90351de0e23a1125bf 2.2.0 6217a989c27b4780c99ae09ee8cd1bd99807f857 2.4.0 be073cc040e1ea0eabf77e09eaa8c8c97062e3ab 2.6.0 +59f2d565d0423a55c74b5d68cf8e40713692aba7 2.6.1 From 72ea676ef7f27faa3e9efbe81867d3ae156110ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 12 Feb 2013 18:16:01 +0100 Subject: [PATCH 07/32] Increase version number --- tryton.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tryton.cfg b/tryton.cfg index 18627e87cb..f4ea47733f 100644 --- a/tryton.cfg +++ b/tryton.cfg @@ -1,5 +1,5 @@ [tryton] -version=2.6.1 +version=2.6.2 depends: company currency From 7ffa8380da60f188a7d466ec2586985f103e6eb9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 6 Mar 2013 13:08:21 +0100 Subject: [PATCH 08/32] Fix average cost price computation context locations should be list of ids and not instances issue3037 review703002 (transplanted from 9a4d2bccf7f8fe00d32955d82342dfd627d749a1) --- move.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/move.py b/move.py index 199ad19e26..e14d229188 100644 --- a/move.py +++ b/move.py @@ -331,9 +331,10 @@ class Move(ModelSQL, ModelView): company = Company(company) context = {} - context['locations'] = Location.search([ + locations = Location.search([ ('type', '=', 'storage'), ]) + context['locations'] = [l.id for l in locations] context['stock_date_end'] = Date.today() with Transaction().set_context(context): product = Product(product_id) From 86985cbbc89bb127c12e5a2e2b711646c4aacdfa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Thu, 21 Mar 2013 19:19:52 +0100 Subject: [PATCH 09/32] Use forecast for quantity by warehouse to include today moves review718002 (transplanted from 8815f197539c100e6efb8f20ddf5611d66ad1433) --- product.py | 1 + 1 file changed, 1 insertion(+) diff --git a/product.py b/product.py index 24555fe534..7195abe71c 100644 --- a/product.py +++ b/product.py @@ -662,6 +662,7 @@ class ProductQuantitiesByWarehouse(ModelSQL, ModelView): context = { 'stock_date_start': date_start, 'stock_date_end': date, + 'forecast': True, } with Transaction().set_context(**context): quantities[date] = Product.products_by_location( From d36272a676216f10f5f61b6c57fdbbe8774e4e80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sat, 6 Apr 2013 12:33:50 +0200 Subject: [PATCH 10/32] Catch OverflowError in get_quantity when appending timedelta If date is date.max then appending one day to it will raise an OverflowError. review761002 (transplanted from 01636875abb6aee9e9d390728f36a5efe476bc1f) --- product.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/product.py b/product.py index 7195abe71c..72d37a5061 100644 --- a/product.py +++ b/product.py @@ -668,7 +668,10 @@ class ProductQuantitiesByWarehouse(ModelSQL, ModelView): quantities[date] = Product.products_by_location( [warehouse_id], [product_id], with_childs=True, skip_zero=False)[(warehouse_id, product_id)] - date_start = date + datetime.timedelta(1) + try: + date_start = date + datetime.timedelta(1) + except OverflowError: + pass cumulate = 0 for date in dates: cumulate += quantities[date] From 42de3f397cb3b58aaf979d2839417ae02f7202e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 16 Apr 2013 15:31:10 +0200 Subject: [PATCH 11/32] Include NULL planned_date with datetime.date.max review790002 (transplanted from 5b73bf2ce14b5e4c94d71b5db0b3d1f11c339a9d) --- product.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/product.py b/product.py index 72d37a5061..0fb17532e7 100644 --- a/product.py +++ b/product.py @@ -284,9 +284,9 @@ class Product: '(' \ '(effective_date IS NULL) '\ 'AND '\ - '(planned_date <= %s) '\ + '(COALESCE(planned_date, %s) <= %s) '\ 'AND '\ - '(planned_date >= %s)'\ + '(COALESCE(planned_date, %s) >= %s)'\ ')'\ 'OR '\ '(' \ @@ -302,7 +302,8 @@ class Product: 'done', context.get('stock_assign') and 'assigned' or 'done', today, today, 'done', 'assigned', 'draft', - context['stock_date_end'], today, + datetime.date.max, context['stock_date_end'], + datetime.date.max, today, context['stock_date_end'], today, ] From 0e87cddcbd594f369f7112774f2b1ae1e34733d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 16 Apr 2013 15:30:21 +0200 Subject: [PATCH 12/32] Unit price should also be required for move to supplier review791002 (transplanted from 08c21c1eaac77bdfaf38f548b7ce303be863402e) --- move.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/move.py b/move.py index e14d229188..4d85f78f08 100644 --- a/move.py +++ b/move.py @@ -281,6 +281,10 @@ class Move(ModelSQL, ModelView): if (self.to_location and self.to_location.type == 'customer'): return True + if (self.from_location and self.to_location + and self.from_location.type == 'storage' + and self.to_location.type == 'supplier'): + return True return False @classmethod From b1544bce192921a178d19debe2e8416eef747994 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Thu, 2 May 2013 10:30:49 +0200 Subject: [PATCH 13/32] Prepare release 2.6.2 --- CHANGELOG | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG b/CHANGELOG index ceabd66622..18d1f0ae49 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +Version 2.6.2 - 2013-05-02 +* Bug fixes (see mercurial logs for details) + Version 2.6.1 - 2013-02-12 * Bug fixes (see mercurial logs for details) From 343318ea62214145e588496b0104b9147d11b698 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Thu, 2 May 2013 10:30:50 +0200 Subject: [PATCH 14/32] Added tag 2.6.2 for changeset 7f1e8b8a1bce --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 6113a7859f..1b0e520337 100644 --- a/.hgtags +++ b/.hgtags @@ -8,3 +8,4 @@ c2e3b9e568b73f262ebf0b69c2ca98f97cbb886e 2.0.0 6217a989c27b4780c99ae09ee8cd1bd99807f857 2.4.0 be073cc040e1ea0eabf77e09eaa8c8c97062e3ab 2.6.0 59f2d565d0423a55c74b5d68cf8e40713692aba7 2.6.1 +7f1e8b8a1bce4750684ed28b72b6436d6b0ed726 2.6.2 From 33d5de92e4cd1b49fc841d7d35f9c0608e10b110 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Thu, 2 May 2013 10:31:02 +0200 Subject: [PATCH 15/32] Increase version number --- tryton.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tryton.cfg b/tryton.cfg index f4ea47733f..0383151a78 100644 --- a/tryton.cfg +++ b/tryton.cfg @@ -1,5 +1,5 @@ [tryton] -version=2.6.2 +version=2.6.3 depends: company currency From 7f16f782d13e9fa2c544a87b60b0bfcc8a1cef82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 22 May 2013 19:18:43 +0200 Subject: [PATCH 16/32] Use root to search on period and search on closed periods products_by_location can be called by users without read access to period. And only closed period has cache. review875002 (transplanted from 09d5333339c1d345dae85e5f3180d8a240bf5848) --- product.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/product.py b/product.py index 0fb17532e7..2a3ddf116a 100644 --- a/product.py +++ b/product.py @@ -385,9 +385,11 @@ class Product: context['stock_date_start'], today, ]) else: - periods = Period.search([ - ('date', '<', context['stock_date_end']), - ], order=[('date', 'DESC')], limit=1) + with Transaction().set_user(0, set_context=True): + periods = Period.search([ + ('date', '<', context['stock_date_end']), + ('state', '=', 'closed'), + ], order=[('date', 'DESC')], limit=1) if periods: period, = periods state_date_clause += (' AND ' From def2f8613f9b6be82a122152b1cbf53e3024155d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sun, 9 Jun 2013 22:50:43 +0200 Subject: [PATCH 17/32] Prepare release 2.6.3 --- CHANGELOG | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG b/CHANGELOG index 18d1f0ae49..3a298ef713 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +Version 2.6.3 - 2013-06-09 +* Bug fixes (see mercurial logs for details) + Version 2.6.2 - 2013-05-02 * Bug fixes (see mercurial logs for details) From 04b42b1fe98ecfbaf8dbf79173857cee852dd0c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sun, 9 Jun 2013 22:50:43 +0200 Subject: [PATCH 18/32] Added tag 2.6.3 for changeset 4cc1c43b9fd4 --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 1b0e520337..13e795ffa2 100644 --- a/.hgtags +++ b/.hgtags @@ -9,3 +9,4 @@ c2e3b9e568b73f262ebf0b69c2ca98f97cbb886e 2.0.0 be073cc040e1ea0eabf77e09eaa8c8c97062e3ab 2.6.0 59f2d565d0423a55c74b5d68cf8e40713692aba7 2.6.1 7f1e8b8a1bce4750684ed28b72b6436d6b0ed726 2.6.2 +4cc1c43b9fd4e7af11bc81cd24b3f1c66438f6f9 2.6.3 From 395d53c7e65e90561bedf7d6538bbe68f31d8929 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sun, 9 Jun 2013 22:50:55 +0200 Subject: [PATCH 19/32] Increase version number --- tryton.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tryton.cfg b/tryton.cfg index 0383151a78..fb925e2ef4 100644 --- a/tryton.cfg +++ b/tryton.cfg @@ -1,5 +1,5 @@ [tryton] -version=2.6.3 +version=2.6.4 depends: company currency From 05c883022d1605d9ab9f14502bc2c3766ffcae85 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Thu, 6 Jun 2013 20:41:29 +0200 Subject: [PATCH 20/32] Fix date selection when using period in products_by_location effective_date and planned_date could be both NULL so they must be considered as date.max to be included. review897003 (transplanted from 880fcffdafa24b42dc163309b6b24eb3ad5528e4) --- product.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/product.py b/product.py index 2a3ddf116a..07d3fe349b 100644 --- a/product.py +++ b/product.py @@ -393,8 +393,8 @@ class Product: if periods: period, = periods state_date_clause += (' AND ' - '(COALESCE(effective_date, planned_date) > %s)') - state_date_vals.append(period.date) + '(COALESCE(effective_date, planned_date, %s) > %s)') + state_date_vals.extend([datetime.date.max, period.date]) period_vals[0] = period.id if with_childs: From cf9b8467a9ce9c3ec4e59d37cb02a23bda184ee6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Mon, 22 Jul 2013 11:57:12 +0200 Subject: [PATCH 21/32] Prepare release 2.6.4 --- CHANGELOG | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG b/CHANGELOG index 3a298ef713..2a0a47baaf 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +Version 2.6.4 - 2013-07-22 +* Bug fixes (see mercurial logs for details) + Version 2.6.3 - 2013-06-09 * Bug fixes (see mercurial logs for details) From 8a9baef785ecac6dd946e706730fced461436fef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Mon, 22 Jul 2013 11:57:13 +0200 Subject: [PATCH 22/32] Added tag 2.6.4 for changeset e7a41fd00879 --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 13e795ffa2..1a509a9eec 100644 --- a/.hgtags +++ b/.hgtags @@ -10,3 +10,4 @@ be073cc040e1ea0eabf77e09eaa8c8c97062e3ab 2.6.0 59f2d565d0423a55c74b5d68cf8e40713692aba7 2.6.1 7f1e8b8a1bce4750684ed28b72b6436d6b0ed726 2.6.2 4cc1c43b9fd4e7af11bc81cd24b3f1c66438f6f9 2.6.3 +e7a41fd00879571f1c836d527c3190e5ec61233e 2.6.4 From 1b628992cfc59b60eb325cc2ddd42fb2a45a06d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Mon, 22 Jul 2013 11:57:35 +0200 Subject: [PATCH 23/32] Increase version number --- tryton.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tryton.cfg b/tryton.cfg index fb925e2ef4..bc150ab13a 100644 --- a/tryton.cfg +++ b/tryton.cfg @@ -1,5 +1,5 @@ [tryton] -version=2.6.4 +version=2.6.5 depends: company currency From d5c0e1d9aed81e543dbb03cf1150afd7b35d835a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sun, 22 Sep 2013 18:16:40 +0200 Subject: [PATCH 24/32] Fix typo search -> browse in reports (transplanted from 5bb977f7294bf73a8b8414c941f97fc68bf97f93) --- shipment.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/shipment.py b/shipment.py index 52e63e117b..f2c5b1a5e9 100644 --- a/shipment.py +++ b/shipment.py @@ -2171,8 +2171,8 @@ class PickingList(CompanyReport): from_location_ids.add(move.from_location.id) to_location_ids.add(move.to_location.id) - from_locations = Location.search(list(from_location_ids)) - to_locations = Location.search(list(to_location_ids)) + from_locations = Location.browse(list(from_location_ids)) + to_locations = Location.browse(list(to_location_ids)) return { 'from_location_ids': [l.id for l in from_locations], @@ -2218,8 +2218,8 @@ class SupplierRestockingList(CompanyReport): from_location_ids.add(move.from_location.id) to_location_ids.add(move.to_location.id) - from_locations = Location.search(list(from_location_ids)) - to_locations = Location.search(list(to_location_ids)) + from_locations = Location.browse(list(from_location_ids)) + to_locations = Location.browse(list(to_location_ids)) return { 'from_location_ids': [l.id for l in from_locations], @@ -2265,8 +2265,8 @@ class CustomerReturnRestockingList(CompanyReport): from_location_ids.add(move.from_location.id) to_location_ids.add(move.to_location.id) - from_locations = Location.search(list(from_location_ids)) - to_locations = Location.search(list(to_location_ids)) + from_locations = Location.browse(list(from_location_ids)) + to_locations = Location.browse(list(to_location_ids)) return { 'from_location_ids': [l.id for l in from_locations], @@ -2312,8 +2312,8 @@ class InteralShipmentReport(CompanyReport): from_location_ids.add(move.from_location.id) to_location_ids.add(move.to_location.id) - from_locations = Location.search(list(from_location_ids)) - to_locations = Location.search(list(to_location_ids)) + from_locations = Location.browse(list(from_location_ids)) + to_locations = Location.browse(list(to_location_ids)) return { 'from_location_ids': [l.id for l in from_locations], From 05539264252a5b46d6891dcf1bb8540eb43fa9ba Mon Sep 17 00:00:00 2001 From: Guillem Barba Date: Mon, 30 Sep 2013 17:44:19 +0200 Subject: [PATCH 25/32] Fix domain concatenation between list and tuple issue3386 review1099002 (transplanted from b1a0217d8c1b506db8a29d3bad6bda2a7b6af250) --- move.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/move.py b/move.py index 4d85f78f08..d238a44f0c 100644 --- a/move.py +++ b/move.py @@ -308,7 +308,7 @@ class Move(ModelSQL, ModelView): @classmethod def search_rec_name(cls, name, clause): - return [('product',) + clause[1:]] + return [('product',) + tuple(clause[1:])] @classmethod def _update_product_cost_price(cls, product_id, quantity, uom, unit_price, From 045cb18a120c0030fca4ab76d78a5ea25c2810f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 4 Dec 2013 17:29:26 +0100 Subject: [PATCH 26/32] Prepare release 2.6.5 --- CHANGELOG | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG b/CHANGELOG index 2a0a47baaf..2a1ef8754c 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +Version 2.6.5 - 2013-12-04 +* Bug fixes (see mercurial logs for details) + Version 2.6.4 - 2013-07-22 * Bug fixes (see mercurial logs for details) From 6b20dcce4655de16a0cef46ed12ec4beee774781 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 4 Dec 2013 17:29:27 +0100 Subject: [PATCH 27/32] Added tag 2.6.5 for changeset e55fede58569 --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 1a509a9eec..638d232669 100644 --- a/.hgtags +++ b/.hgtags @@ -11,3 +11,4 @@ be073cc040e1ea0eabf77e09eaa8c8c97062e3ab 2.6.0 7f1e8b8a1bce4750684ed28b72b6436d6b0ed726 2.6.2 4cc1c43b9fd4e7af11bc81cd24b3f1c66438f6f9 2.6.3 e7a41fd00879571f1c836d527c3190e5ec61233e 2.6.4 +e55fede585699bc4fbfa392a61f11a09104cf040 2.6.5 From f31bb735e259ba8c8e4a1907dd98bf102772bf3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 4 Dec 2013 17:30:00 +0100 Subject: [PATCH 28/32] Increase version number --- tryton.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tryton.cfg b/tryton.cfg index bc150ab13a..daff6d6b9a 100644 --- a/tryton.cfg +++ b/tryton.cfg @@ -1,5 +1,5 @@ [tryton] -version=2.6.5 +version=2.6.6 depends: company currency From 79f8c59353a07befed20883020873c42fe570128 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Thu, 12 Dec 2013 13:50:05 +0100 Subject: [PATCH 29/32] Missing test on address before using it issue3531 review2021002 (transplanted from 904d8e35be3bbc43907782d469925e0a7175126c) --- shipment.py | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/shipment.py b/shipment.py index f2c5b1a5e9..6299aa013b 100644 --- a/shipment.py +++ b/shipment.py @@ -231,10 +231,10 @@ class ShipmentIn(Workflow, ModelSQL, ModelView): return Transaction().context.get('company') def on_change_supplier(self): - if not self.supplier: - return {'contact_address': None} - address = self.supplier.address_get() - return {'contact_address': address.id} + address = None + if self.supplier: + address = self.supplier.address_get() + return {'contact_address': address.id if address else None} def on_change_with_supplier_location(self, name=None): if self.supplier: @@ -947,10 +947,10 @@ class ShipmentOut(Workflow, ModelSQL, ModelView): return Transaction().context.get('company') def on_change_customer(self): - if not self.customer: - return {'delivery_address': None} - address = self.customer.address_get(type='delivery') - return {'delivery_address': address.id} + address = None + if self.customer: + address = self.customer.address_get(type='delivery') + return {'delivery_address': address.id if address else None} def on_change_with_customer_location(self, name=None): if self.customer: @@ -1446,11 +1446,11 @@ class ShipmentOutReturn(Workflow, ModelSQL, ModelView): return Transaction().context.get('company') def on_change_customer(self): - if not self.customer: - return {'delivery_address': None} - address = self.customer.address_get(type='delivery') + address = None + if self.customer: + address = self.customer.address_get(type='delivery') return { - 'delivery_address': address.id, + 'delivery_address': address.id if address else None, } def on_change_with_customer_location(self, name=None): From f03076a5643207f8079a182d8d599a24bbbe7f84 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sat, 18 Jan 2014 20:49:19 +0100 Subject: [PATCH 30/32] Prepare release 2.6.6 --- CHANGELOG | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG b/CHANGELOG index 2a1ef8754c..a41ea2682f 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +Version 2.6.6 - 2014-01-18 +* Bug fixes (see mercurial logs for details) + Version 2.6.5 - 2013-12-04 * Bug fixes (see mercurial logs for details) From 8d0262851dd7bf5e3c4e379a2277b2d04455a996 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sat, 18 Jan 2014 20:49:20 +0100 Subject: [PATCH 31/32] Added tag 2.6.6 for changeset f6b7f44b5c13 --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 638d232669..418b6a908d 100644 --- a/.hgtags +++ b/.hgtags @@ -12,3 +12,4 @@ be073cc040e1ea0eabf77e09eaa8c8c97062e3ab 2.6.0 4cc1c43b9fd4e7af11bc81cd24b3f1c66438f6f9 2.6.3 e7a41fd00879571f1c836d527c3190e5ec61233e 2.6.4 e55fede585699bc4fbfa392a61f11a09104cf040 2.6.5 +f6b7f44b5c138c1a881c41e1c93ddcb265003710 2.6.6 From 3522f07a4e5571fc08b5b3e21c6b025a5ff61f59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sat, 18 Jan 2014 20:49:39 +0100 Subject: [PATCH 32/32] Increase version number --- tryton.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tryton.cfg b/tryton.cfg index daff6d6b9a..7ed4d7ecb2 100644 --- a/tryton.cfg +++ b/tryton.cfg @@ -1,5 +1,5 @@ [tryton] -version=2.6.6 +version=2.6.7 depends: company currency