[tryton-debian-vcs] tryton-modules-stock branch upstream-3.0 updated. upstream/3.0.5-1-g7727659

Mathias Behrle tryton-debian-vcs at alioth.debian.org
Wed Feb 25 00:45:51 UTC 2015


The following commit has been merged in the upstream-3.0 branch:
https://alioth.debian.org/plugins/scmgit/cgi-bin/gitweb.cgi/?p=tryton/tryton-modules-stock.git;a=commitdiff;h=upstream/3.0.5-1-g7727659

commit 7727659ba31b7b45777131fba02c6b8889c17021
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Tue Feb 24 19:54:50 2015 +0100

    Adding upstream version 3.0.6.
    
    Signed-off-by: Mathias Behrle <mathiasb at m9s.biz>

diff --git a/CHANGELOG b/CHANGELOG
index fc4b5d6..2948bd3 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 3.0.6 - 2015-02-19
+* Bug fixes (see mercurial logs for details)
+
 Version 3.0.5 - 2014-09-29
 * Bug fixes (see mercurial logs for details)
 
diff --git a/COPYRIGHT b/COPYRIGHT
index 06390fa..3a91df4 100644
--- a/COPYRIGHT
+++ b/COPYRIGHT
@@ -1,7 +1,7 @@
 Copyright (C) 2012 Openlabs Technologies & Consulting (P) LTD.
-Copyright (C) 2008-2014 Cédric Krier.
+Copyright (C) 2008-2015 Cédric Krier.
 Copyright (C) 2008-2013 Bertrand Chenal.
-Copyright (C) 2008-2014 B2CK SPRL.
+Copyright (C) 2008-2015 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 d4bd60b..cdd3ecd 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: trytond_stock
-Version: 3.0.5
+Version: 3.0.6
 Summary: Tryton module for stock and inventory
 Home-page: http://www.tryton.org/
 Author: Tryton
diff --git a/location.py b/location.py
index 8724139..1f1c1bc 100644
--- a/location.py
+++ b/location.py
@@ -205,7 +205,9 @@ class Location(ModelSQL, ModelView):
             return dict((l.id, None) for l in locations)
         cost_values, context = {}, {}
         if 'stock_date_end' in trans_context:
-            context['_datetime'] = trans_context['stock_date_end']
+            # Use the last cost_price of the day
+            context['_datetime'] = datetime.datetime.combine(
+                trans_context['stock_date_end'], datetime.time.max)
         with Transaction().set_context(context):
             product = Product(product_id)
             for location in locations:
diff --git a/product.py b/product.py
index 691f4c3..4e1341a 100644
--- a/product.py
+++ b/product.py
@@ -103,7 +103,9 @@ class Product(object, StockMixin):
         context = {}
         trans_context = Transaction().context
         if trans_context.get('stock_date_end'):
-            context['_datetime'] = trans_context['stock_date_end']
+            # Use the last cost_price of the day
+            context['_datetime'] = datetime.datetime.combine(
+                trans_context['stock_date_end'], datetime.time.max)
         with Transaction().set_context(context):
             for product in products:
                 # The date could be before the product creation
diff --git a/tryton.cfg b/tryton.cfg
index 239aed1..e567e47 100644
--- a/tryton.cfg
+++ b/tryton.cfg
@@ -1,5 +1,5 @@
 [tryton]
-version=3.0.5
+version=3.0.6
 depends:
     company
     currency
diff --git a/trytond_stock.egg-info/PKG-INFO b/trytond_stock.egg-info/PKG-INFO
index 5444099..96ed733 100644
--- a/trytond_stock.egg-info/PKG-INFO
+++ b/trytond_stock.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: trytond-stock
-Version: 3.0.5
+Version: 3.0.6
 Summary: Tryton module for stock and inventory
 Home-page: http://www.tryton.org/
 Author: Tryton
-- 
tryton-modules-stock



More information about the tryton-debian-vcs mailing list