[MIG] stock_inventory_discrepancy: Migration to 11.0

This commit is contained in:
andreas
2018-04-20 16:31:36 +07:00
committed by hveficent
parent ce5c224fcb
commit 4356e72bc8
25 changed files with 246 additions and 150 deletions

View File

@@ -42,7 +42,7 @@ If you configured a "Maximum Discrepancy Rate Threshold".
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
:alt: Try me on Runbot
:target: https://runbot.odoo-community.org/runbot/153/10.0
:target: https://runbot.odoo-community.org/runbot/153/11.0
Bug Tracker
@@ -63,6 +63,7 @@ Contributors
------------
* Lois Rilo <lois.rilo@eficent.com>
* Andreas Dian Sukarno Putro <andreasdian777@gmail.com>
Maintainer

View File

@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from . import models

View File

@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# (http://www.eficent.com)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
@@ -7,7 +6,7 @@
"summary": "Adds the capability to show the discrepancy of every line in "
"an inventory and to block the inventory validation when the "
"discrepancy is over a user defined threshold.",
"version": "10.0.1.0.0",
"version": "11.0.1.0.0",
"author": "Eficent, "
"Odoo Community Association (OCA)",
"website": "https://github.com/OCA/stock-logistics-warehouse",

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# Lukáš Spurný <lukasspurny8@gmail.com>, 2018
msgid ""
@@ -11,11 +11,12 @@ msgstr ""
"POT-Creation-Date: 2018-02-27 11:37+0000\n"
"PO-Revision-Date: 2018-02-27 11:37+0000\n"
"Last-Translator: Lukáš Spurný <lukasspurny8@gmail.com>, 2018\n"
"Language-Team: Czech (Czech Republic) (https://www.transifex.com/oca/teams/23907/cs_CZ/)\n"
"Language-Team: Czech (Czech Republic) (https://www.transifex.com/oca/"
"teams/23907/cs_CZ/)\n"
"Language: cs_CZ\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: cs_CZ\n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
#. module: stock_inventory_discrepancy
@@ -66,8 +67,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +77,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +93,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# OCA Transbot <transbot@odoo-community.org>, 2017
msgid ""
@@ -12,10 +12,10 @@ msgstr ""
"PO-Revision-Date: 2017-11-30 03:53+0000\n"
"Last-Translator: OCA Transbot <transbot@odoo-community.org>, 2017\n"
"Language-Team: German (https://www.transifex.com/oca/teams/23907/de/)\n"
"Language: de\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: de\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: stock_inventory_discrepancy
@@ -66,8 +66,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +76,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +92,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# OCA Transbot <transbot@odoo-community.org>, 2017
msgid ""
@@ -12,10 +12,10 @@ msgstr ""
"PO-Revision-Date: 2017-11-30 03:53+0000\n"
"Last-Translator: OCA Transbot <transbot@odoo-community.org>, 2017\n"
"Language-Team: Spanish (https://www.transifex.com/oca/teams/23907/es/)\n"
"Language: es\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: es\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: stock_inventory_discrepancy
@@ -66,8 +66,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +76,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +92,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# OCA Transbot <transbot@odoo-community.org>, 2017
# Daniel <dani_dca@hotmail.com>, 2017
@@ -12,11 +12,12 @@ msgstr ""
"POT-Creation-Date: 2017-07-26 11:41+0000\n"
"PO-Revision-Date: 2017-07-26 11:41+0000\n"
"Last-Translator: Daniel <dani_dca@hotmail.com>, 2017\n"
"Language-Team: Spanish (Spain) (https://www.transifex.com/oca/teams/23907/es_ES/)\n"
"Language-Team: Spanish (Spain) (https://www.transifex.com/oca/teams/23907/"
"es_ES/)\n"
"Language: es_ES\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: es_ES\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: stock_inventory_discrepancy
@@ -67,8 +68,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -77,7 +78,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -93,8 +94,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# OCA Transbot <transbot@odoo-community.org>, 2017
msgid ""
@@ -12,10 +12,10 @@ msgstr ""
"PO-Revision-Date: 2017-11-30 03:53+0000\n"
"Last-Translator: OCA Transbot <transbot@odoo-community.org>, 2017\n"
"Language-Team: French (https://www.transifex.com/oca/teams/23907/fr/)\n"
"Language: fr\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: fr\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#. module: stock_inventory_discrepancy
@@ -66,8 +66,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +76,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +92,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# Mohamed HABOU <m.habou@agoradeveloppement.com>, 2017
msgid ""
@@ -11,11 +11,12 @@ msgstr ""
"POT-Creation-Date: 2017-02-18 04:05+0000\n"
"PO-Revision-Date: 2017-02-18 04:05+0000\n"
"Last-Translator: Mohamed HABOU <m.habou@agoradeveloppement.com>, 2017\n"
"Language-Team: French (France) (https://www.transifex.com/oca/teams/23907/fr_FR/)\n"
"Language-Team: French (France) (https://www.transifex.com/oca/teams/23907/"
"fr_FR/)\n"
"Language: fr_FR\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: fr_FR\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#. module: stock_inventory_discrepancy
@@ -66,8 +67,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +77,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +93,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# Bole <bole@dajmi5.com>, 2018
msgid ""
@@ -12,11 +12,12 @@ msgstr ""
"PO-Revision-Date: 2018-02-27 11:37+0000\n"
"Last-Translator: Bole <bole@dajmi5.com>, 2018\n"
"Language-Team: Croatian (https://www.transifex.com/oca/teams/23907/hr/)\n"
"Language: hr\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: hr\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,field_description:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_qty
@@ -66,8 +67,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +77,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +93,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# OCA Transbot <transbot@odoo-community.org>, 2017
# Paolo Valier <paolo.valier@hotmail.it>, 2017
@@ -13,10 +13,10 @@ msgstr ""
"PO-Revision-Date: 2017-02-18 04:05+0000\n"
"Last-Translator: Paolo Valier <paolo.valier@hotmail.it>, 2017\n"
"Language-Team: Italian (https://www.transifex.com/oca/teams/23907/it/)\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: it\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: stock_inventory_discrepancy
@@ -67,8 +67,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -77,7 +77,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -93,8 +93,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# OCA Transbot <transbot@odoo-community.org>, 2017
msgid ""
@@ -12,10 +12,10 @@ msgstr ""
"PO-Revision-Date: 2017-02-18 04:05+0000\n"
"Last-Translator: OCA Transbot <transbot@odoo-community.org>, 2017\n"
"Language-Team: Dutch (https://www.transifex.com/oca/teams/23907/nl/)\n"
"Language: nl\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: nl\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: stock_inventory_discrepancy
@@ -66,8 +66,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +76,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +92,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# Peter Hageman <hageman.p@gmail.com>, 2017
msgid ""
@@ -11,11 +11,12 @@ msgstr ""
"POT-Creation-Date: 2017-11-30 03:53+0000\n"
"PO-Revision-Date: 2017-11-30 03:53+0000\n"
"Last-Translator: Peter Hageman <hageman.p@gmail.com>, 2017\n"
"Language-Team: Dutch (Netherlands) (https://www.transifex.com/oca/teams/23907/nl_NL/)\n"
"Language-Team: Dutch (Netherlands) (https://www.transifex.com/oca/"
"teams/23907/nl_NL/)\n"
"Language: nl_NL\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: nl_NL\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: stock_inventory_discrepancy
@@ -66,8 +67,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +77,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +93,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# Paulo Ricardo <ti@shoppingescritorio.com.br>, 2017
# Felipe Lopes <ti@trojahntoppel.com.br>, 2017
@@ -12,11 +12,12 @@ msgstr ""
"POT-Creation-Date: 2017-02-18 04:05+0000\n"
"PO-Revision-Date: 2017-02-18 04:05+0000\n"
"Last-Translator: Felipe Lopes <ti@trojahntoppel.com.br>, 2017\n"
"Language-Team: Portuguese (Brazil) (https://www.transifex.com/oca/teams/23907/pt_BR/)\n"
"Language-Team: Portuguese (Brazil) (https://www.transifex.com/oca/"
"teams/23907/pt_BR/)\n"
"Language: pt_BR\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: pt_BR\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#. module: stock_inventory_discrepancy
@@ -67,8 +68,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -77,7 +78,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -93,8 +94,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# OCA Transbot <transbot@odoo-community.org>, 2017
msgid ""
@@ -12,11 +12,12 @@ msgstr ""
"PO-Revision-Date: 2017-11-30 03:53+0000\n"
"Last-Translator: OCA Transbot <transbot@odoo-community.org>, 2017\n"
"Language-Team: Slovenian (https://www.transifex.com/oca/teams/23907/sl/)\n"
"Language: sl\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: sl\n"
"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n%100==4 ? 2 : 3);\n"
"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n"
"%100==4 ? 2 : 3);\n"
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,field_description:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_qty
@@ -66,8 +67,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +77,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +93,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -0,0 +1,104 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 11.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: <>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,field_description:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_qty
msgid "Discrepancy"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,field_description:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid "Discrepancy percent (%)"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.ui.view,arch_db:stock_inventory_discrepancy.view_inventory_form
msgid "Force Validation"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model,name:stock_inventory_discrepancy.model_stock_inventory
msgid "Inventory"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model,name:stock_inventory_discrepancy.model_stock_inventory_line
msgid "Inventory Line"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model,name:stock_inventory_discrepancy.model_stock_location
msgid "Inventory Locations"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,field_description:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
#: model:ir.model.fields,field_description:stock_inventory_discrepancy.field_stock_warehouse_discrepancy_threshold
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_threshold
msgid "Maximum Discrepancy Rate Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_warehouse_discrepancy_threshold
msgid "Maximum Discrepancy Rate allowed for any product when doing an Inventory Adjustment. Threshold defined in involved Location has preference."
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid "Maximum Discrepancy Rate allowed for any product when doing an Inventory Adjustment. Thresholds defined in Locations have preference over Warehouse's ones."
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,field_description:stock_inventory_discrepancy.field_stock_inventory_over_discrepancy_line_count
msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid "The Qty Update is over the Discrepancy Threshold.\n"
" Please, contact a user with rights to perform this action."
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_qty
msgid "The difference between the actual qty counted and the theoretical quantity on hand."
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,field_description:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_threshold
msgid "Threshold (%)"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:res.groups,name:stock_inventory_discrepancy.group_stock_inventory_validation_always
msgid "Validate All inventory Adjustments"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:res.groups,name:stock_inventory_discrepancy.group_stock_inventory_validation
msgid "Validate Inventory Adjustments Under Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model,name:stock_inventory_discrepancy.model_stock_warehouse
msgid "Warehouse"
msgstr ""

View File

@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_inventory_discrepancy
#
#
# Translators:
# Ozge Altinisik <ozge@altinkaya.com.tr>, 2017
msgid ""
@@ -11,11 +11,12 @@ msgstr ""
"POT-Creation-Date: 2017-02-18 04:05+0000\n"
"PO-Revision-Date: 2017-02-18 04:05+0000\n"
"Last-Translator: Ozge Altinisik <ozge@altinkaya.com.tr>, 2017\n"
"Language-Team: Turkish (Turkey) (https://www.transifex.com/oca/teams/23907/tr_TR/)\n"
"Language-Team: Turkish (Turkey) (https://www.transifex.com/oca/teams/23907/"
"tr_TR/)\n"
"Language: tr_TR\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Language: tr_TR\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#. module: stock_inventory_discrepancy
@@ -66,8 +67,8 @@ msgstr ""
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_location_discrepancy_threshold
msgid ""
"Maximum Discrepancy Rate allowed for any product when doing an Inventory "
"Adjustment. Thresholds defined in Locations have preference over Warehouse's"
" ones."
"Adjustment. Thresholds defined in Locations have preference over Warehouse's "
"ones."
msgstr ""
#. module: stock_inventory_discrepancy
@@ -76,7 +77,7 @@ msgid "Number of Discrepancies Over Threshold"
msgstr ""
#. module: stock_inventory_discrepancy
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:55
#: code:addons/stock_inventory_discrepancy/models/stock_inventory.py:56
#, python-format
msgid ""
"The Qty Update is over the Discrepancy Threshold.\n"
@@ -92,8 +93,7 @@ msgstr ""
#. module: stock_inventory_discrepancy
#: model:ir.model.fields,help:stock_inventory_discrepancy.field_stock_inventory_line_discrepancy_percent
msgid ""
"The discrepancy expressed in percent with theoretical quantity as basis"
msgid "The discrepancy expressed in percent with theoretical quantity as basis"
msgstr ""
#. module: stock_inventory_discrepancy

View File

@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from . import stock_inventory

View File

@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# (http://www.eficent.com)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
@@ -17,14 +16,6 @@ class StockInventory(models.Model):
('pending', 'Pending to Approve'),
('done', 'Validated')]
@api.one
@api.depends('line_ids.product_qty', 'line_ids.theoretical_qty')
def _compute_over_discrepancy_line_count(self):
lines = self.line_ids
self.over_discrepancy_line_count = sum(
d.discrepancy_percent > d.discrepancy_threshold
for d in lines)
state = fields.Selection(
selection=INVENTORY_STATE_SELECTION,
string='Status', readonly=True, index=True, copy=False,
@@ -37,12 +28,22 @@ class StockInventory(models.Model):
"- Validated: Inventory Approved.")
over_discrepancy_line_count = fields.Integer(
string='Number of Discrepancies Over Threshold',
compute=_compute_over_discrepancy_line_count,
compute='_compute_over_discrepancy_line_count',
store=True)
@api.model
@api.multi
@api.depends('line_ids.product_qty', 'line_ids.theoretical_qty')
def _compute_over_discrepancy_line_count(self):
for inventory in self:
lines = inventory.line_ids.filtered(
lambda line: line.discrepancy_percent > line.
discrepancy_threshold
)
inventory.over_discrepancy_line_count = len(lines)
@api.multi
def action_over_discrepancies(self):
self.state = 'pending'
self.write({'state': 'pending'})
def _check_group_inventory_validation_always(self):
grp_inv_val = self.env.ref(
@@ -57,8 +58,8 @@ class StockInventory(models.Model):
'this action.')
)
@api.one
def action_done(self):
self.ensure_one()
if self.over_discrepancy_line_count and self.line_ids.filtered(
lambda t: t.discrepancy_threshold > 0.0):
if self.env.context.get('normal_view', False):

View File

@@ -1,44 +1,23 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# (http://www.eficent.com)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from odoo.addons import decimal_precision as dp
from odoo import api, fields, models
class StockInventoryLine(models.Model):
_inherit = 'stock.inventory.line'
@api.multi
def _compute_discrepancy(self):
for l in self:
l.discrepancy_qty = l.product_qty - l.theoretical_qty
if l.theoretical_qty:
l.discrepancy_percent = 100 * abs(
(l.product_qty - l.theoretical_qty) /
l.theoretical_qty)
elif not l.theoretical_qty and l.product_qty:
l.discrepancy_percent = 100.0
@api.multi
def _compute_discrepancy_threshold(self):
for l in self:
wh = l.location_id.get_warehouse()
if l.location_id.discrepancy_threshold > 0.0:
l.discrepancy_threshold = l.location_id.discrepancy_threshold
elif wh.discrepancy_threshold > 0.0:
l.discrepancy_threshold = wh.discrepancy_threshold
else:
l.discrepancy_threshold = False
discrepancy_qty = fields.Float(
string='Discrepancy',
compute=_compute_discrepancy,
compute='_compute_discrepancy',
help="The difference between the actual qty counted and the "
"theoretical quantity on hand.")
"theoretical quantity on hand.",
digits=dp.get_precision('Product Unit of Measure'), default=0)
discrepancy_percent = fields.Float(
string='Discrepancy percent (%)',
compute=_compute_discrepancy,
compute='_compute_discrepancy',
digits=(3, 2),
help="The discrepancy expressed in percent with theoretical quantity "
"as basis")
@@ -46,4 +25,28 @@ class StockInventoryLine(models.Model):
string='Threshold (%)',
digits=(3, 2),
help="Maximum Discrepancy Rate Threshold",
compute=_compute_discrepancy_threshold)
compute='_compute_discrepancy_threshold')
@api.multi
@api.depends('theoretical_qty', 'product_qty')
def _compute_discrepancy(self):
for line in self:
line.discrepancy_qty = line.product_qty - line.theoretical_qty
if line.theoretical_qty:
line.discrepancy_percent = 100 * abs(
(line.product_qty - line.theoretical_qty) /
line.theoretical_qty)
elif not line.theoretical_qty and line.product_qty:
line.discrepancy_percent = 100.0
@api.multi
def _compute_discrepancy_threshold(self):
for line in self:
whs = line.location_id.get_warehouse()
if line.location_id.discrepancy_threshold > 0.0:
line.discrepancy_threshold = line.location_id.\
discrepancy_threshold
elif whs.discrepancy_threshold > 0.0:
line.discrepancy_threshold = whs.discrepancy_threshold
else:
line.discrepancy_threshold = False

View File

@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# (http://www.eficent.com)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).

View File

@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# (http://www.eficent.com)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).

View File

@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from . import test_inventory_discrepancy

View File

@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
# (http://www.eficent.com)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).

View File

@@ -40,8 +40,7 @@
<field name="discrepancy_threshold"/>
</xpath>
<xpath expr="//field[@name='line_ids']/tree" position="attributes">
<attribute name="decoration-danger">theoretical_qty &lt; 0 or
discrepancy_percent &gt; discrepancy_threshold</attribute>
<attribute name="decoration-danger">theoretical_qty &lt; 0 or discrepancy_percent &gt; discrepancy_threshold</attribute>
</xpath>
</field>
</record>