[tryton-debian-vcs] tryton-modules-stock-supply branch upstream-2.2 created. 18d6da94b553105a98064c9a0c9a1a7007201bf8

Mathias Behrle tryton-debian-vcs at alioth.debian.org
Wed Nov 27 17:12:08 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-stock-supply.git;a=commitdiff;h=18d6da94b553105a98064c9a0c9a1a7007201bf8
commit 18d6da94b553105a98064c9a0c9a1a7007201bf8
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Tue Jun 11 14:03:26 2013 +0200

    Adding upstream version 2.2.3.

diff --git a/CHANGELOG b/CHANGELOG
index bfbc3f5..fa2c165 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 2.2.3 - 2013-06-09
+* Bug fixes (see mercurial logs for details)
+
 Version 2.2.2 - 2012-09-02
 * Bug fixes (see mercurial logs for details)
 
diff --git a/COPYRIGHT b/COPYRIGHT
index 26f578f..da9ef80 100644
--- a/COPYRIGHT
+++ b/COPYRIGHT
@@ -1,6 +1,6 @@
-Copyright (C) 2008-2012 Cédric Krier.
+Copyright (C) 2008-2013 Cédric Krier.
 Copyright (C) 2008-2011 Bertrand Chenal.
-Copyright (C) 2008-2012 B2CK SPRL.
+Copyright (C) 2008-2013 B2CK SPRL.
 
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
diff --git a/PKG-INFO b/PKG-INFO
index 032ad64..67497ac 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
-Metadata-Version: 1.0
+Metadata-Version: 1.1
 Name: trytond_stock_supply
-Version: 2.2.2
+Version: 2.2.3
 Summary: Supply Management Module with:
     - Order point
     - Purchase Request
diff --git a/__tryton__.py b/__tryton__.py
index a0814dd..f09c2fc 100644
--- a/__tryton__.py
+++ b/__tryton__.py
@@ -7,7 +7,7 @@
     'name_es_CO': 'Gestión de pedidos de inventario',
     'name_es_ES': 'Gestión de suministro de existencias',
     'name_fr_FR': 'Gestion des approvisionnements de stock',
-    'version': '2.2.2',
+    'version': '2.2.3',
     'author': 'B2CK',
     'email': 'info at b2ck.com',
     'website': 'http://www.tryton.org/',
diff --git a/shipment.py b/shipment.py
index 89a73ee..0ec99d3 100644
--- a/shipment.py
+++ b/shipment.py
@@ -54,8 +54,8 @@ class ShipmentInternal(ModelSQL, ModelView):
         for op in order_points:
             qty = pbl.get((op.storage_location.id, op.product.id), 0)
             if qty < op.min_quantity:
-                key = (op.storage_location.id,
-                       op.provisioning_location.id,
+                key = (op.provisioning_location.id,
+                       op.storage_location.id,
                        op.product.id)
                 moves[key] = op.max_quantity - qty
 
@@ -68,8 +68,8 @@ class ShipmentInternal(ModelSQL, ModelView):
             ])
         for shipment in self.browse(shipment_ids):
             for move in shipment.moves:
-                key = (shipment.to_location.id,
-                       shipment.from_location.id,
+                key = (shipment.from_location.id,
+                       shipment.to_location.id,
                        move.product.id)
                 if key not in moves:
                     continue
diff --git a/trytond_stock_supply.egg-info/PKG-INFO b/trytond_stock_supply.egg-info/PKG-INFO
index 181f0f8..9b7d898 100644
--- a/trytond_stock_supply.egg-info/PKG-INFO
+++ b/trytond_stock_supply.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
-Metadata-Version: 1.0
+Metadata-Version: 1.1
 Name: trytond-stock-supply
-Version: 2.2.2
+Version: 2.2.3
 Summary: Supply Management Module with:
     - Order point
     - Purchase Request
commit 4c253d974581e3c241fd9ea01c231d3149c29533
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Wed Sep 12 15:45:20 2012 +0200

    Adding upstream version 2.2.2.

diff --git a/CHANGELOG b/CHANGELOG
index 6660507..bfbc3f5 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 2.2.2 - 2012-09-02
+* Bug fixes (see mercurial logs for details)
+
 Version 2.2.1 - 2012-05-07
 * Bug fixes (see mercurial logs for details)
 
diff --git a/PKG-INFO b/PKG-INFO
index 7324b2d..032ad64 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
-Metadata-Version: 1.1
+Metadata-Version: 1.0
 Name: trytond_stock_supply
-Version: 2.2.1
+Version: 2.2.2
 Summary: Supply Management Module with:
     - Order point
     - Purchase Request
diff --git a/__tryton__.py b/__tryton__.py
index 6f35cd9..a0814dd 100644
--- a/__tryton__.py
+++ b/__tryton__.py
@@ -7,7 +7,7 @@
     'name_es_CO': 'Gestión de pedidos de inventario',
     'name_es_ES': 'Gestión de suministro de existencias',
     'name_fr_FR': 'Gestion des approvisionnements de stock',
-    'version': '2.2.1',
+    'version': '2.2.2',
     'author': 'B2CK',
     'email': 'info at b2ck.com',
     'website': 'http://www.tryton.org/',
diff --git a/purchase_request.py b/purchase_request.py
index 717f758..8ac90f0 100644
--- a/purchase_request.py
+++ b/purchase_request.py
@@ -697,10 +697,10 @@ class CreatePurchase(Wizard):
         for tax in request.product.supplier_taxes_used:
             if request.party and request.party.supplier_tax_rule:
                 pattern = self._get_tax_rule_pattern(request)
-                tax_id = tax_rule_obj.apply(request.party.supplier_tax_rule, 
+                tax_ids = tax_rule_obj.apply(request.party.supplier_tax_rule,
                         tax, pattern)
-                if tax_id:
-                    taxes.append(tax_id)
+                if tax_ids:
+                    taxes.extend(tax_ids)
                 continue
             taxes.append(tax.id)
         line['taxes'] = [('add', taxes)]
diff --git a/trytond_stock_supply.egg-info/PKG-INFO b/trytond_stock_supply.egg-info/PKG-INFO
index cd1199f..181f0f8 100644
--- a/trytond_stock_supply.egg-info/PKG-INFO
+++ b/trytond_stock_supply.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
-Metadata-Version: 1.1
+Metadata-Version: 1.0
 Name: trytond-stock-supply
-Version: 2.2.1
+Version: 2.2.2
 Summary: Supply Management Module with:
     - Order point
     - Purchase Request
commit 29384294ee54b29d8c80398ff2357ef926e7b6b3
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Wed May 9 12:01:18 2012 +0200

    Adding upstream version 2.2.1.

diff --git a/CHANGELOG b/CHANGELOG
index 4816d83..6660507 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 2.2.1 - 2012-05-07
+* Bug fixes (see mercurial logs for details)
+
 Version 2.2.0 - 2011-10-25
 * Bug fixes (see mercurial logs for details)
 * Add wizard to create purchase requests
diff --git a/COPYRIGHT b/COPYRIGHT
index 3d2324b..26f578f 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.
 
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
diff --git a/PKG-INFO b/PKG-INFO
index 2112119..7324b2d 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
-Metadata-Version: 1.0
+Metadata-Version: 1.1
 Name: trytond_stock_supply
-Version: 2.2.0
+Version: 2.2.1
 Summary: Supply Management Module with:
     - Order point
     - Purchase Request
diff --git a/__tryton__.py b/__tryton__.py
index be9715a..6f35cd9 100644
--- a/__tryton__.py
+++ b/__tryton__.py
@@ -7,7 +7,7 @@
     'name_es_CO': 'Gestión de pedidos de inventario',
     'name_es_ES': 'Gestión de suministro de existencias',
     'name_fr_FR': 'Gestion des approvisionnements de stock',
-    'version': '2.2.0',
+    'version': '2.2.1',
     'author': 'B2CK',
     'email': 'info at b2ck.com',
     'website': 'http://www.tryton.org/',
diff --git a/purchase_request.py b/purchase_request.py
index b141387..717f758 100644
--- a/purchase_request.py
+++ b/purchase_request.py
@@ -2,6 +2,7 @@
 #this repository contains the full copyright notices and license terms.
 import datetime
 import operator
+from decimal import Decimal
 from trytond.model import ModelView, ModelSQL, fields
 from trytond.wizard import Wizard
 from trytond.pyson import If, In, Eval, Get
@@ -668,6 +669,7 @@ class CreatePurchase(Wizard):
         party_obj = pool.get('party.party')
         product_obj = pool.get('product.product')
         tax_rule_obj = pool.get('account.tax.rule')
+        line_obj = pool.get('purchase.line')
 
         line = {
             'product': request.product.id,
@@ -683,6 +685,8 @@ class CreatePurchase(Wizard):
                 currency=request.company.currency.id):
             product_price = product_obj.get_purchase_price(
                     [request.product.id], request.quantity)[request.product.id]
+            product_price = product_price.quantize(
+                Decimal(1) / 10 ** line_obj.unit_price.digits[1])
 
         if not product_price:
             self.raise_user_error('missing_price', (request.product.name,
diff --git a/trytond_stock_supply.egg-info/PKG-INFO b/trytond_stock_supply.egg-info/PKG-INFO
index b7f072a..cd1199f 100644
--- a/trytond_stock_supply.egg-info/PKG-INFO
+++ b/trytond_stock_supply.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
-Metadata-Version: 1.0
+Metadata-Version: 1.1
 Name: trytond-stock-supply
-Version: 2.2.0
+Version: 2.2.1
 Summary: Supply Management Module with:
     - Order point
     - Purchase Request
-- 
tryton-modules-stock-supply



More information about the tryton-debian-vcs mailing list