[tryton-debian-vcs] tryton-modules-stock-lot branch upstream updated. upstream/3.4.1-1-gf0b7462

Mathias Behrle tryton-debian-vcs at alioth.debian.org
Thu Apr 23 16:07:07 UTC 2015


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

commit f0b74625012d479980b69ec48be6162fcdd3a043
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Thu Apr 23 17:00:08 2015 +0200

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

diff --git a/CHANGELOG b/CHANGELOG
index b4d2932..7e27a30 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,6 +1,6 @@
-Version 3.4.1 - 2015-02-18
+Version 3.6.0 - 2015-04-20
 * Bug fixes (see mercurial logs for details)
-
+* Add support for PyPy
 Version 3.4.0 - 2014-10-20
 * Bug fixes (see mercurial logs for details)
 
diff --git a/PKG-INFO b/PKG-INFO
index 0f02a0e..5225c24 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,12 +1,12 @@
 Metadata-Version: 1.1
 Name: trytond_stock_lot
-Version: 3.4.1
+Version: 3.6.0
 Summary: Tryton module for lot of products
 Home-page: http://www.tryton.org/
 Author: Tryton
 Author-email: issue_tracker at tryton.org
 License: GPL-3
-Download-URL: http://downloads.tryton.org/3.4/
+Download-URL: http://downloads.tryton.org/3.6/
 Description: trytond_stock_lot
         =================
         
@@ -65,4 +65,6 @@ Classifier: Natural Language :: Slovenian
 Classifier: Natural Language :: Spanish
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python :: 2.7
+Classifier: Programming Language :: Python :: Implementation :: CPython
+Classifier: Programming Language :: Python :: Implementation :: PyPy
 Classifier: Topic :: Office/Business
diff --git a/__init__.py b/__init__.py
index e9898f7..60647e8 100644
--- a/__init__.py
+++ b/__init__.py
@@ -1,5 +1,5 @@
-#This file is part of Tryton.  The COPYRIGHT file at the top level of this
-#repository contains the full copyright notices and license terms.
+# This file is part of Tryton.  The COPYRIGHT file at the top level of
+# this repository contains the full copyright notices and license terms.
 
 from trytond.pool import Pool
 from .stock import *
diff --git a/locale/ca_ES.po b/locale/ca_ES.po
index 4c3272e..64b5923 100644
--- a/locale/ca_ES.po
+++ b/locale/ca_ES.po
@@ -68,7 +68,7 @@ msgstr "Número"
 
 msgctxt "field:stock.lot,product:"
 msgid "Product"
-msgstr "Productes"
+msgstr "Producte"
 
 msgctxt "field:stock.lot,quantity:"
 msgid "Quantity"
@@ -156,7 +156,7 @@ msgstr "Període"
 
 msgctxt "field:stock.period.cache.lot,product:"
 msgid "Product"
-msgstr "Productes"
+msgstr "Producte"
 
 msgctxt "field:stock.period.cache.lot,rec_name:"
 msgid "Name"
diff --git a/locale/de_DE.po b/locale/de_DE.po
index bbfde43..f723792 100644
--- a/locale/de_DE.po
+++ b/locale/de_DE.po
@@ -152,7 +152,7 @@ msgstr "Charge"
 
 msgctxt "field:stock.period.cache.lot,period:"
 msgid "Period"
-msgstr "Periode"
+msgstr "Lagerperiode"
 
 msgctxt "field:stock.period.cache.lot,product:"
 msgid "Product"
@@ -240,8 +240,8 @@ msgstr "Chargen"
 
 msgctxt "view:stock.period.cache.lot:"
 msgid "Period Lot Cache"
-msgstr "Cache Periode Charge"
+msgstr "Lagerperiode Charge Cache"
 
 msgctxt "view:stock.period.cache.lot:"
 msgid "Period Lot Caches"
-msgstr "Caches Perioden Chargen"
+msgstr "Lagerperiode Charge Caches"
diff --git a/locale/es_AR.po b/locale/es_AR.po
index 4a47830..3304a3d 100644
--- a/locale/es_AR.po
+++ b/locale/es_AR.po
@@ -156,7 +156,7 @@ msgstr "Período"
 
 msgctxt "field:stock.period.cache.lot,product:"
 msgid "Product"
-msgstr "Productos"
+msgstr "Producto"
 
 msgctxt "field:stock.period.cache.lot,rec_name:"
 msgid "Name"
diff --git a/locale/es_ES.po b/locale/es_ES.po
index 624f900..6c766d0 100644
--- a/locale/es_ES.po
+++ b/locale/es_ES.po
@@ -156,7 +156,7 @@ msgstr "Período"
 
 msgctxt "field:stock.period.cache.lot,product:"
 msgid "Product"
-msgstr "Productos"
+msgstr "Producto"
 
 msgctxt "field:stock.period.cache.lot,rec_name:"
 msgid "Name"
diff --git a/locale/sl_SI.po b/locale/sl_SI.po
index 3e43b35..08a4897 100644
--- a/locale/sl_SI.po
+++ b/locale/sl_SI.po
@@ -32,7 +32,7 @@ msgstr "Predloga"
 
 msgctxt "field:product.template-stock.lot.type,type:"
 msgid "Type"
-msgstr "Vrsta"
+msgstr "Tip"
 
 msgctxt "field:product.template-stock.lot.type,write_date:"
 msgid "Write Date"
diff --git a/product.py b/product.py
index d1bf2b7..3061e6d 100644
--- a/product.py
+++ b/product.py
@@ -1,5 +1,5 @@
-#This file is part of Tryton.  The COPYRIGHT file at the top level of
-#this repository contains the full copyright notices and license terms.
+# This file is part of Tryton.  The COPYRIGHT file at the top level of
+# this repository contains the full copyright notices and license terms.
 from trytond.model import ModelSQL, fields
 from trytond.pyson import Eval
 from trytond.pool import PoolMeta
diff --git a/setup.py b/setup.py
index c85a9d4..be21b96 100644
--- a/setup.py
+++ b/setup.py
@@ -1,6 +1,6 @@
 #!/usr/bin/env python
-#This file is part of Tryton.  The COPYRIGHT file at the top level of
-#this repository contains the full copyright notices and license terms.
+# This file is part of Tryton.  The COPYRIGHT file at the top level of
+# this repository contains the full copyright notices and license terms.
 
 from setuptools import setup
 import re
@@ -92,6 +92,8 @@ setup(name=name,
         'Natural Language :: Spanish',
         'Operating System :: OS Independent',
         'Programming Language :: Python :: 2.7',
+        'Programming Language :: Python :: Implementation :: CPython',
+        'Programming Language :: Python :: Implementation :: PyPy',
         'Topic :: Office/Business',
         ],
     license='GPL-3',
diff --git a/stock.py b/stock.py
index 782ffac..5bf5d1e 100644
--- a/stock.py
+++ b/stock.py
@@ -1,8 +1,8 @@
-#This file is part of Tryton.  The COPYRIGHT file at the top level of
-#this repository contains the full copyright notices and license terms.
+# This file is part of Tryton.  The COPYRIGHT file at the top level of
+# this repository contains the full copyright notices and license terms.
 from collections import defaultdict
 
-from trytond.model import ModelView, ModelSQL, Workflow, fields
+from trytond.model import ModelView, ModelSQL, fields
 from trytond.pyson import Eval
 from trytond.pool import Pool, PoolMeta
 from trytond.transaction import Transaction
@@ -96,11 +96,12 @@ class ShipmentOut:
     __name__ = 'stock.shipment.out'
 
     @classmethod
-    def _sync_inventory_to_outgoing(cls, shipments):
+    def _sync_inventory_to_outgoing(cls, shipments, create=True, write=True):
         pool = Pool()
         Uom = pool.get('product.uom')
         Move = pool.get('stock.move')
-        super(ShipmentOut, cls)._sync_inventory_to_outgoing(shipments)
+        super(ShipmentOut, cls)._sync_inventory_to_outgoing(
+            shipments, create=create, write=write)
         for shipment in shipments:
             outgoing_by_product = {}
             for move in shipment.outgoing_moves:
diff --git a/stock.xml b/stock.xml
index 78c6609..5c144b3 100644
--- a/stock.xml
+++ b/stock.xml
@@ -51,7 +51,8 @@ this repository contains the full copyright notices and license terms. -->
         <record model="ir.action.act_window" id="act_move_form_relate_lot">
             <field name="name">Moves</field>
             <field name="res_model">stock.move</field>
-            <field name="domain">[('lot', 'in', Eval('active_ids'))]</field>
+            <field name="domain"
+                eval="[('lot', 'in', Eval('active_ids'))]" pyson="1"/>
             <field name="order">[('effective_date', 'DESC'), ('planned_date', 'DESC')]</field>
         </record>
         <record model="ir.action.keyword"
diff --git a/tests/__init__.py b/tests/__init__.py
index cf849d9..5bc1a62 100644
--- a/tests/__init__.py
+++ b/tests/__init__.py
@@ -1,5 +1,5 @@
-#This file is part of Tryton.  The COPYRIGHT file at the top level of
-#this repository contains the full copyright notices and license terms.
+# This file is part of Tryton.  The COPYRIGHT file at the top level of
+# this repository contains the full copyright notices and license terms.
 
 from .test_stock_lot import suite
 
diff --git a/tests/scenario_stock_lot_shipment_out.rst b/tests/scenario_stock_lot_shipment_out.rst
index a5d2251..678bc7f 100644
--- a/tests/scenario_stock_lot_shipment_out.rst
+++ b/tests/scenario_stock_lot_shipment_out.rst
@@ -2,16 +2,14 @@
 Stock Lot Shipment Out Scenario
 ===============================
 
-=============
-General Setup
-=============
-
 Imports::
 
     >>> import datetime
     >>> from dateutil.relativedelta import relativedelta
     >>> from decimal import Decimal
     >>> from proteus import config, Model, Wizard
+    >>> from trytond.modules.company.tests.tools import create_company, \
+    ...     get_company
     >>> today = datetime.date.today()
 
 Create database::
@@ -22,35 +20,14 @@ Create database::
 Install stock_lot Module::
 
     >>> Module = Model.get('ir.module.module')
-    >>> modules = Module.find([('name', '=', 'stock_lot')])
-    >>> Module.install([x.id for x in modules], config.context)
+    >>> module, = Module.find([('name', '=', 'stock_lot')])
+    >>> module.click('install')
     >>> Wizard('ir.module.module.install_upgrade').execute('upgrade')
 
 Create company::
 
-    >>> Currency = Model.get('currency.currency')
-    >>> CurrencyRate = Model.get('currency.currency.rate')
-    >>> Company = Model.get('company.company')
-    >>> Party = Model.get('party.party')
-    >>> company_config = Wizard('company.company.config')
-    >>> company_config.execute('company')
-    >>> company = company_config.form
-    >>> party = Party(name='Dunder Mifflin')
-    >>> party.save()
-    >>> company.party = party
-    >>> currencies = Currency.find([('code', '=', 'USD')])
-    >>> if not currencies:
-    ...     currency = Currency(name='U.S. Dollar', symbol='$', code='USD',
-    ...         rounding=Decimal('0.01'), mon_grouping='[3, 3, 0]',
-    ...         mon_decimal_point='.', mon_thousands_sep=',')
-    ...     currency.save()
-    ...     CurrencyRate(date=today + relativedelta(month=1, day=1),
-    ...         rate=Decimal('1.0'), currency=currency).save()
-    ... else:
-    ...     currency, = currencies
-    >>> company.currency = currency
-    >>> company_config.execute('add')
-    >>> company, = Company.find()
+    >>> _ = create_company()
+    >>> company = get_company()
 
 Reload the context::
 
@@ -110,7 +87,7 @@ Add two shipment lines of same product::
     >>> move.to_location = customer_loc
     >>> move.company = company
     >>> move.unit_price = Decimal('1')
-    >>> move.currency = currency
+    >>> move.currency = company.currency
     >>> move = StockMove()
     >>> shipment_out.outgoing_moves.append(move)
     >>> move.product = product
@@ -120,13 +97,12 @@ Add two shipment lines of same product::
     >>> move.to_location = customer_loc
     >>> move.company = company
     >>> move.unit_price = Decimal('1')
-    >>> move.currency = currency
+    >>> move.currency = company.currency
     >>> shipment_out.save()
 
 Set the shipment state to waiting::
 
-    >>> ShipmentOut.wait([shipment_out.id], config.context)
-    >>> shipment_out.reload()
+    >>> shipment_out.click('wait')
     >>> len(shipment_out.outgoing_moves)
     2
     >>> len(shipment_out.inventory_moves)
@@ -136,11 +112,9 @@ Assign the shipment with 2 lines of 7 products::
 
     >>> for move in shipment_out.inventory_moves:
     ...     move.quantity = 7
-    >>> shipment_out.save()
-    >>> ShipmentOut.assign_force([shipment_out.id], config.context)
-    >>> shipment_out.reload()
-    >>> shipment_out.state == 'assigned'
-    True
+    >>> shipment_out.click('assign_force')
+    >>> shipment_out.state
+    u'assigned'
 
 Set 2 lots::
 
@@ -153,10 +127,9 @@ Set 2 lots::
 
 Pack the shipment::
 
-    >>> ShipmentOut.pack([shipment_out.id], config.context)
-    >>> shipment_out.reload()
-    >>> shipment_out.state == 'packed'
-    True
+    >>> shipment_out.click('pack')
+    >>> shipment_out.state
+    u'packed'
     >>> len(shipment_out.outgoing_moves)
     3
     >>> sorted([m.quantity for m in shipment_out.outgoing_moves])
diff --git a/tests/test_stock_lot.py b/tests/test_stock_lot.py
index 05d882f..b490d83 100644
--- a/tests/test_stock_lot.py
+++ b/tests/test_stock_lot.py
@@ -1,5 +1,5 @@
-#This file is part of Tryton.  The COPYRIGHT file at the top level of
-#this repository contains the full copyright notices and license terms.
+# This file is part of Tryton.  The COPYRIGHT file at the top level of
+# this repository contains the full copyright notices and license terms.
 import unittest
 import doctest
 import datetime
@@ -7,17 +7,18 @@ from dateutil.relativedelta import relativedelta
 from decimal import Decimal
 
 import trytond.tests.test_tryton
-from trytond.tests.test_tryton import POOL, DB_NAME, USER, CONTEXT, test_view,\
-    test_depends
+from trytond.tests.test_tryton import ModuleTestCase
+from trytond.tests.test_tryton import POOL, DB_NAME, USER, CONTEXT
 from trytond.tests.test_tryton import doctest_setup, doctest_teardown
 from trytond.transaction import Transaction
 
 
-class StockLotTestCase(unittest.TestCase):
+class StockLotTestCase(ModuleTestCase):
     'Test Stock Lot module'
+    module = 'stock_lot'
 
     def setUp(self):
-        trytond.tests.test_tryton.install_module('stock_lot')
+        super(StockLotTestCase, self).setUp()
         self.template = POOL.get('product.template')
         self.product = POOL.get('product.product')
         self.uom = POOL.get('product.uom')
@@ -29,14 +30,6 @@ class StockLotTestCase(unittest.TestCase):
         self.period = POOL.get('stock.period')
         self.cache = POOL.get('stock.period.cache')
 
-    def test0005views(self):
-        'Test views'
-        test_view('stock_lot')
-
-    def test0006depends(self):
-        'Test depends'
-        test_depends()
-
     def test0010products_by_location(self):
         'Test products_by_location'
         with Transaction().start(DB_NAME, USER, context=CONTEXT):
diff --git a/tryton.cfg b/tryton.cfg
index c298804..bf34306 100644
--- a/tryton.cfg
+++ b/tryton.cfg
@@ -1,5 +1,5 @@
 [tryton]
-version=3.4.1
+version=3.6.0
 depends:
     ir
     product
diff --git a/trytond_stock_lot.egg-info/PKG-INFO b/trytond_stock_lot.egg-info/PKG-INFO
index 62919b6..cad9192 100644
--- a/trytond_stock_lot.egg-info/PKG-INFO
+++ b/trytond_stock_lot.egg-info/PKG-INFO
@@ -1,12 +1,12 @@
 Metadata-Version: 1.1
 Name: trytond-stock-lot
-Version: 3.4.1
+Version: 3.6.0
 Summary: Tryton module for lot of products
 Home-page: http://www.tryton.org/
 Author: Tryton
 Author-email: issue_tracker at tryton.org
 License: GPL-3
-Download-URL: http://downloads.tryton.org/3.4/
+Download-URL: http://downloads.tryton.org/3.6/
 Description: trytond_stock_lot
         =================
         
@@ -65,4 +65,6 @@ Classifier: Natural Language :: Slovenian
 Classifier: Natural Language :: Spanish
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python :: 2.7
+Classifier: Programming Language :: Python :: Implementation :: CPython
+Classifier: Programming Language :: Python :: Implementation :: PyPy
 Classifier: Topic :: Office/Business
diff --git a/trytond_stock_lot.egg-info/requires.txt b/trytond_stock_lot.egg-info/requires.txt
index 158bea8..97f70d9 100644
--- a/trytond_stock_lot.egg-info/requires.txt
+++ b/trytond_stock_lot.egg-info/requires.txt
@@ -1,3 +1,3 @@
-trytond_product >= 3.4, < 3.5
-trytond_stock >= 3.4, < 3.5
-trytond >= 3.4, < 3.5
\ No newline at end of file
+trytond_product >= 3.6, < 3.7
+trytond_stock >= 3.6, < 3.7
+trytond >= 3.6, < 3.7
\ No newline at end of file
diff --git a/view/template_form.xml b/view/template_form.xml
index 47429a5..aac79ad 100644
--- a/view/template_form.xml
+++ b/view/template_form.xml
@@ -3,8 +3,7 @@
 this repository contains the full copyright notices and license terms. -->
 <data>
     <xpath expr="/form/notebook/page[@id='general']" position="after">
-        <page string="Lots" id="lots"
-            states="{'invisible': ~Eval('type').in_(['goods', 'assets'])}">
+        <page string="Lots" name="lot_required">
             <label name="lot_required"/>
             <field name="lot_required" widget="multiselection" yexpand="0"/>
         </page>
-- 
tryton-modules-stock-lot



More information about the tryton-debian-vcs mailing list