From da9b2090254d1290265db5a026a84d33772ad283 Mon Sep 17 00:00:00 2001
From: Jasmin Solanki
Date: Mon, 11 Apr 2022 10:43:03 +0530
Subject: [PATCH 001/207] [ADD] purchase_tag
---
purchase_tag/README.rst | 78 ++++
purchase_tag/__init__.py | 3 +
purchase_tag/__manifest__.py | 21 +
purchase_tag/i18n/purchase_tag.pot | 91 +++++
purchase_tag/models/__init__.py | 2 +
purchase_tag/models/purchase_order.py | 17 +
purchase_tag/models/purchase_tag.py | 22 ++
purchase_tag/readme/CONTRIBUTORS.rst | 1 +
purchase_tag/readme/DESCRIPTION.rst | 1 +
purchase_tag/readme/USAGE.rst | 1 +
purchase_tag/security/ir.model.access.csv | 3 +
purchase_tag/static/description/icon.png | Bin 0 -> 9455 bytes
purchase_tag/static/description/index.html | 424 +++++++++++++++++++++
purchase_tag/views/purchase_tag_view.xml | 59 +++
purchase_tag/views/purchase_view.xml | 53 +++
15 files changed, 776 insertions(+)
create mode 100644 purchase_tag/README.rst
create mode 100644 purchase_tag/__init__.py
create mode 100644 purchase_tag/__manifest__.py
create mode 100644 purchase_tag/i18n/purchase_tag.pot
create mode 100644 purchase_tag/models/__init__.py
create mode 100644 purchase_tag/models/purchase_order.py
create mode 100644 purchase_tag/models/purchase_tag.py
create mode 100644 purchase_tag/readme/CONTRIBUTORS.rst
create mode 100644 purchase_tag/readme/DESCRIPTION.rst
create mode 100644 purchase_tag/readme/USAGE.rst
create mode 100644 purchase_tag/security/ir.model.access.csv
create mode 100644 purchase_tag/static/description/icon.png
create mode 100644 purchase_tag/static/description/index.html
create mode 100644 purchase_tag/views/purchase_tag_view.xml
create mode 100644 purchase_tag/views/purchase_view.xml
diff --git a/purchase_tag/README.rst b/purchase_tag/README.rst
new file mode 100644
index 00000000000..c4885925c35
--- /dev/null
+++ b/purchase_tag/README.rst
@@ -0,0 +1,78 @@
+=============
+Purchase Tags
+=============
+
+.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+ !! This file is generated by oca-gen-addon-readme !!
+ !! changes will be overwritten. !!
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
+ :target: https://odoo-community.org/page/development-status
+ :alt: Beta
+.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
+ :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
+ :alt: License: AGPL-3
+.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpurchase--workflow-lightgray.png?logo=github
+ :target: https://github.com/OCA/purchase-workflow/tree/14.0/purchase_tag
+ :alt: OCA/purchase-workflow
+.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
+ :target: https://translation.odoo-community.org/projects/purchase-workflow-14-0/purchase-workflow-14-0-purchase_tag
+ :alt: Translate me on Weblate
+.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
+ :target: https://runbot.odoo-community.org/runbot/142/14.0
+ :alt: Try me on Runbot
+
+|badge1| |badge2| |badge3| |badge4| |badge5|
+
+This module allows to add multiple tags to purchase orders
+
+**Table of contents**
+
+.. contents::
+ :local:
+
+Usage
+=====
+
+To use this module, you need to go to Purchase Orders and select tags.
+
+Bug Tracker
+===========
+
+Bugs are tracked on `GitHub Issues `_.
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed
+`feedback `_.
+
+Do not contact contributors directly about support or help with technical issues.
+
+Credits
+=======
+
+Authors
+~~~~~~~
+
+* ForgeFlow
+
+Contributors
+~~~~~~~~~~~~
+
+* Jasmin Solanki
+
+Maintainers
+~~~~~~~~~~~
+
+This module is maintained by the OCA.
+
+.. image:: https://odoo-community.org/logo.png
+ :alt: Odoo Community Association
+ :target: https://odoo-community.org
+
+OCA, or the Odoo Community Association, is a nonprofit organization whose
+mission is to support the collaborative development of Odoo features and
+promote its widespread use.
+
+This module is part of the `OCA/purchase-workflow `_ project on GitHub.
+
+You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/purchase_tag/__init__.py b/purchase_tag/__init__.py
new file mode 100644
index 00000000000..4b76c7b2d5c
--- /dev/null
+++ b/purchase_tag/__init__.py
@@ -0,0 +1,3 @@
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from . import models
diff --git a/purchase_tag/__manifest__.py b/purchase_tag/__manifest__.py
new file mode 100644
index 00000000000..b4769b08e6c
--- /dev/null
+++ b/purchase_tag/__manifest__.py
@@ -0,0 +1,21 @@
+# Copyright 2022 ForgeFlow S.L.
+# (http://www.forgeflow.com)
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+{
+ "name": "Purchase Tags",
+ "summary": "Allows to add multiple tags to purchase orders",
+ "version": "14.0.1.0.0",
+ "author": "ForgeFlow, Odoo Community Association (OCA)",
+ "website": "https://github.com/OCA/purchase-workflow",
+ "category": "Purchases",
+ "depends": ["purchase"],
+ "data": [
+ "security/ir.model.access.csv",
+ "views/purchase_view.xml",
+ "views/purchase_tag_view.xml",
+ ],
+ "license": "AGPL-3",
+ "installable": True,
+ "application": False,
+}
diff --git a/purchase_tag/i18n/purchase_tag.pot b/purchase_tag/i18n/purchase_tag.pot
new file mode 100644
index 00000000000..c11457721aa
--- /dev/null
+++ b/purchase_tag/i18n/purchase_tag.pot
@@ -0,0 +1,91 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_tag
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 14.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: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__color
+msgid "Color"
+msgstr ""
+
+#. module: purchase_tag
+#: model_terms:ir.actions.act_window,help:purchase_tag.purchase_tag_action
+msgid "Create new tags for your purchase orders"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__create_uid
+msgid "Created by"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__create_date
+msgid "Created on"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__display_name
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__display_name
+msgid "Display Name"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__id
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__id
+msgid "ID"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order____last_update
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag____last_update
+msgid "Last Modified on"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__write_uid
+msgid "Last Updated by"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__write_date
+msgid "Last Updated on"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model,name:purchase_tag.model_purchase_order
+msgid "Purchase Order"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model,name:purchase_tag.model_purchase_tag
+msgid "Purchase Tag"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__name
+msgid "Tag Name"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.model.constraint,message:purchase_tag.constraint_purchase_tag_tag_name_uniq
+msgid "Tag name already exists !"
+msgstr ""
+
+#. module: purchase_tag
+#: model:ir.actions.act_window,name:purchase_tag.purchase_tag_action
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__tag_ids
+#: model:ir.ui.menu,name:purchase_tag.menu_purchase_tag_config
+#: model_terms:ir.ui.view,arch_db:purchase_tag.purchase_tag_view_form
+#: model_terms:ir.ui.view,arch_db:purchase_tag.purchase_tag_view_tree
+msgid "Tags"
+msgstr ""
diff --git a/purchase_tag/models/__init__.py b/purchase_tag/models/__init__.py
new file mode 100644
index 00000000000..d54d894c559
--- /dev/null
+++ b/purchase_tag/models/__init__.py
@@ -0,0 +1,2 @@
+from . import purchase_tag
+from . import purchase_order
diff --git a/purchase_tag/models/purchase_order.py b/purchase_tag/models/purchase_order.py
new file mode 100644
index 00000000000..5267d137cc4
--- /dev/null
+++ b/purchase_tag/models/purchase_order.py
@@ -0,0 +1,17 @@
+# Copyright 2022 ForgeFlow S.L.
+# (http://www.forgeflow.com)
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from odoo import fields, models
+
+
+class PurchaseOrder(models.Model):
+ _inherit = "purchase.order"
+
+ tag_ids = fields.Many2many(
+ comodel_name="purchase.tag",
+ relation="purchase_order_tag_rel",
+ column1="purchase_order_id",
+ column2="tag_id",
+ string="Tags",
+ )
diff --git a/purchase_tag/models/purchase_tag.py b/purchase_tag/models/purchase_tag.py
new file mode 100644
index 00000000000..2edd5f685b6
--- /dev/null
+++ b/purchase_tag/models/purchase_tag.py
@@ -0,0 +1,22 @@
+# Copyright 2022 ForgeFlow S.L.
+# (http://www.forgeflow.com)
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from random import randint
+
+from odoo import fields, models
+
+
+class PurchaseTag(models.Model):
+ _name = "purchase.tag"
+ _description = "Purchase Tag"
+
+ def _get_default_color(self):
+ return randint(1, 11)
+
+ name = fields.Char("Tag Name", required=True, translate=True)
+ color = fields.Integer("Color", default=_get_default_color)
+
+ _sql_constraints = [
+ ("tag_name_uniq", "unique (name)", "Tag name already exists !"),
+ ]
diff --git a/purchase_tag/readme/CONTRIBUTORS.rst b/purchase_tag/readme/CONTRIBUTORS.rst
new file mode 100644
index 00000000000..205106e557d
--- /dev/null
+++ b/purchase_tag/readme/CONTRIBUTORS.rst
@@ -0,0 +1 @@
+* Jasmin Solanki
diff --git a/purchase_tag/readme/DESCRIPTION.rst b/purchase_tag/readme/DESCRIPTION.rst
new file mode 100644
index 00000000000..feb507c6000
--- /dev/null
+++ b/purchase_tag/readme/DESCRIPTION.rst
@@ -0,0 +1 @@
+This module allows to add multiple tags to purchase orders
diff --git a/purchase_tag/readme/USAGE.rst b/purchase_tag/readme/USAGE.rst
new file mode 100644
index 00000000000..7e54d63369c
--- /dev/null
+++ b/purchase_tag/readme/USAGE.rst
@@ -0,0 +1 @@
+To use this module, you need to go to Purchase Orders and select tags.
diff --git a/purchase_tag/security/ir.model.access.csv b/purchase_tag/security/ir.model.access.csv
new file mode 100644
index 00000000000..8ad7fcd8e8a
--- /dev/null
+++ b/purchase_tag/security/ir.model.access.csv
@@ -0,0 +1,3 @@
+id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
+access_purchase_tag,purchase_tag,model_purchase_tag,base.group_user,1,0,0,0
+access_purchase_tag_manager,purchase_tag_manager,model_purchase_tag,purchase.group_purchase_manager,1,1,1,1
diff --git a/purchase_tag/static/description/icon.png b/purchase_tag/static/description/icon.png
new file mode 100644
index 0000000000000000000000000000000000000000..3a0328b516c4980e8e44cdb63fd945757ddd132d
GIT binary patch
literal 9455
zcmW++2RxMjAAjx~&dlBk9S+%}OXg)AGE&Cb*&}d0jUxM@u(PQx^-s)697TX`ehR4?GS^qbkof1cslKgkU)h65qZ9Oc=ml_0temigYLJfnz{IDzUf>bGs4N!v3=Z3jMq&A#7%rM5eQ#dc?k~!
zVpnB`o+K7|Al`Q_U;eD$B
zfJtP*jH`siUq~{KE)`jP2|#TUEFGRryE2`i0**z#*^6~AI|YzIWy$Cu#CSLW3q=GA
z6`?GZymC;dCPk~rBS%eCb`5OLr;RUZ;D`}um=H)BfVIq%7VhiMr)_#G0N#zrNH|__
zc+blN2U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I$4
z!DpKX$OKLWarN7nv@!uIA+~RNO)l$$w}p(;b>mx8pwYvu;dD_unryX_NhT8*Tj>BTrTTL&!?O+%Rv;b?B??gSzdp?6Uug9{
zd@V08Z$BdI?fpoCS$)t4mg4rT8Q_I}h`0d-vYZ^|dOB*Q^S|xqTV*vIg?@fVFSmMpaw0qtTRbx}
z({Pg?#{2`sc9)M5N$*N|4;^t$+QP?#mov
zGVC@I*lBVrOU-%2y!7%)fAKjpEFsgQc4{amtiHb95KQEwvf<(3T<9-Zm$xIew#P22
zc2Ix|App^>v6(3L_MCU0d3W##AB0M~3D00EWoKZqsJYT(#@w$Y_H7G22M~ApVFTRHMI_3be)Lkn#0F*V8Pq
zc}`Cjy$bE;FJ6H7p=0y#R>`}-m4(0F>%@P|?7fx{=R^uFdISRnZ2W_xQhD{YuR3t<
z{6yxu=4~JkeA;|(J6_nv#>Nvs&FuLA&PW^he@t(UwFFE8)|a!R{`E`K`i^ZnyE4$k
z;(749Ix|oi$c3QbEJ3b~D_kQsPz~fIUKym($a_7dJ?o+40*OLl^{=&oq$<#Q(yyrp
z{J-FAniyAw9tPbe&IhQ|a`DqFTVQGQ&Gq3!C2==4x{6EJwiPZ8zub-iXoUtkJiG{}
zPaR&}_fn8_z~(=;5lD-aPWD3z8PZS@AaUiomF!G8I}Mf>e~0g#BelA-5#`cj;O5>N
Xviia!U7SGha1wx#SCgwmn*{w2TRX*I
literal 0
HcmV?d00001
diff --git a/purchase_tag/static/description/index.html b/purchase_tag/static/description/index.html
new file mode 100644
index 00000000000..9cba381af2c
--- /dev/null
+++ b/purchase_tag/static/description/index.html
@@ -0,0 +1,424 @@
+
+
+
+
+
+
+Purchase Tags
+
+
+
+
+
+
diff --git a/purchase_tag/views/purchase_tag_view.xml b/purchase_tag/views/purchase_tag_view.xml
new file mode 100644
index 00000000000..b7f0a09b8d9
--- /dev/null
+++ b/purchase_tag/views/purchase_tag_view.xml
@@ -0,0 +1,59 @@
+
+
+
+
+
+
+ purchase.tag.view.form
+ purchase.tag
+
+
+
+
+
+
+ purchase.tag.view.tree
+ purchase.tag
+
+
+
+
+
+
+
+
+
+ Tags
+ purchase.tag
+
+
+
+ Create new tags for your purchase orders
+
+
+
+
+
+
diff --git a/purchase_tag/views/purchase_view.xml b/purchase_tag/views/purchase_view.xml
new file mode 100644
index 00000000000..ab6d2ebde18
--- /dev/null
+++ b/purchase_tag/views/purchase_view.xml
@@ -0,0 +1,53 @@
+
+
+
+
+
+
+ purchase.order.form
+ purchase.order
+
+
+
+
+
+
+
+
+
+ purchase.order.tree
+ purchase.order
+
+
+
+
+
+
+
+
+
+ purchase.order.tree
+ purchase.order
+
+
+
+
+
+
+
+
+
From 7d7ef845dd29e52e70a7f5ca0394ef8db4c82012 Mon Sep 17 00:00:00 2001
From: Emeric Panisset
Date: Fri, 28 Oct 2022 15:08:37 +0200
Subject: [PATCH 002/207] [MIG] purchase_tag: Migration to 15.0
---
purchase_tag/README.rst | 10 +++++-----
purchase_tag/__manifest__.py | 2 +-
purchase_tag/i18n/purchase_tag.pot | 6 +-----
purchase_tag/models/purchase_tag.py | 2 +-
purchase_tag/static/description/index.html | 6 +++---
purchase_tag/views/purchase_tag_view.xml | 2 +-
6 files changed, 12 insertions(+), 16 deletions(-)
diff --git a/purchase_tag/README.rst b/purchase_tag/README.rst
index c4885925c35..068d5fbe5fd 100644
--- a/purchase_tag/README.rst
+++ b/purchase_tag/README.rst
@@ -14,13 +14,13 @@ Purchase Tags
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpurchase--workflow-lightgray.png?logo=github
- :target: https://github.com/OCA/purchase-workflow/tree/14.0/purchase_tag
+ :target: https://github.com/OCA/purchase-workflow/tree/15.0/purchase_tag
:alt: OCA/purchase-workflow
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
- :target: https://translation.odoo-community.org/projects/purchase-workflow-14-0/purchase-workflow-14-0-purchase_tag
+ :target: https://translation.odoo-community.org/projects/purchase-workflow-15-0/purchase-workflow-15-0-purchase_tag
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/142/14.0
+ :target: https://runbot.odoo-community.org/runbot/142/15.0
:alt: Try me on Runbot
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -43,7 +43,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-`feedback `_.
+`feedback `_.
Do not contact contributors directly about support or help with technical issues.
@@ -73,6 +73,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-This module is part of the `OCA/purchase-workflow `_ project on GitHub.
+This module is part of the `OCA/purchase-workflow `_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/purchase_tag/__manifest__.py b/purchase_tag/__manifest__.py
index b4769b08e6c..230b997b280 100644
--- a/purchase_tag/__manifest__.py
+++ b/purchase_tag/__manifest__.py
@@ -5,7 +5,7 @@
{
"name": "Purchase Tags",
"summary": "Allows to add multiple tags to purchase orders",
- "version": "14.0.1.0.0",
+ "version": "15.0.1.0.0",
"author": "ForgeFlow, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/purchase-workflow",
"category": "Purchases",
diff --git a/purchase_tag/i18n/purchase_tag.pot b/purchase_tag/i18n/purchase_tag.pot
index c11457721aa..964c99c1dac 100644
--- a/purchase_tag/i18n/purchase_tag.pot
+++ b/purchase_tag/i18n/purchase_tag.pot
@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 14.0\n"
+"Project-Id-Version: Odoo Server 15.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -34,19 +34,16 @@ msgid "Created on"
msgstr ""
#. module: purchase_tag
-#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__display_name
#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__display_name
msgid "Display Name"
msgstr ""
#. module: purchase_tag
-#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__id
#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__id
msgid "ID"
msgstr ""
#. module: purchase_tag
-#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order____last_update
#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag____last_update
msgid "Last Modified on"
msgstr ""
@@ -86,6 +83,5 @@ msgstr ""
#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__tag_ids
#: model:ir.ui.menu,name:purchase_tag.menu_purchase_tag_config
#: model_terms:ir.ui.view,arch_db:purchase_tag.purchase_tag_view_form
-#: model_terms:ir.ui.view,arch_db:purchase_tag.purchase_tag_view_tree
msgid "Tags"
msgstr ""
diff --git a/purchase_tag/models/purchase_tag.py b/purchase_tag/models/purchase_tag.py
index 2edd5f685b6..04f04867c92 100644
--- a/purchase_tag/models/purchase_tag.py
+++ b/purchase_tag/models/purchase_tag.py
@@ -15,7 +15,7 @@ def _get_default_color(self):
return randint(1, 11)
name = fields.Char("Tag Name", required=True, translate=True)
- color = fields.Integer("Color", default=_get_default_color)
+ color = fields.Integer(default=_get_default_color)
_sql_constraints = [
("tag_name_uniq", "unique (name)", "Tag name already exists !"),
diff --git a/purchase_tag/static/description/index.html b/purchase_tag/static/description/index.html
index 9cba381af2c..560fc91f033 100644
--- a/purchase_tag/static/description/index.html
+++ b/purchase_tag/static/description/index.html
@@ -367,7 +367,7 @@ Purchase Tags
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
-
+
This module allows to add multiple tags to purchase orders
Table of contents
@@ -391,7 +391,7 @@
Bugs are tracked on GitHub Issues .
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-feedback .
+
feedback .
Do not contact contributors directly about support or help with technical issues.
@@ -415,7 +415,7 @@
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-
This module is part of the OCA/purchase-workflow project on GitHub.
+
This module is part of the OCA/purchase-workflow project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
diff --git a/purchase_tag/views/purchase_tag_view.xml b/purchase_tag/views/purchase_tag_view.xml
index b7f0a09b8d9..dfcc7a81112 100644
--- a/purchase_tag/views/purchase_tag_view.xml
+++ b/purchase_tag/views/purchase_tag_view.xml
@@ -31,7 +31,7 @@
purchase.tag.view.tree
purchase.tag
-
+
From 2ccdabf49ca2417167679a95d9c0bc12454344a2 Mon Sep 17 00:00:00 2001
From: Alex Guardado
Date: Mon, 5 Jun 2023 13:47:50 +0200
Subject: [PATCH 003/207] [MIG] purchase_tag: Migration to 16.0
---
purchase_tag/README.rst | 10 +++++-----
purchase_tag/__manifest__.py | 2 +-
purchase_tag/i18n/purchase_tag.pot | 2 +-
purchase_tag/static/description/index.html | 6 +++---
4 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/purchase_tag/README.rst b/purchase_tag/README.rst
index 068d5fbe5fd..eda7abcae2a 100644
--- a/purchase_tag/README.rst
+++ b/purchase_tag/README.rst
@@ -14,13 +14,13 @@ Purchase Tags
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpurchase--workflow-lightgray.png?logo=github
- :target: https://github.com/OCA/purchase-workflow/tree/15.0/purchase_tag
+ :target: https://github.com/OCA/purchase-workflow/tree/16.0/purchase_tag
:alt: OCA/purchase-workflow
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
- :target: https://translation.odoo-community.org/projects/purchase-workflow-15-0/purchase-workflow-15-0-purchase_tag
+ :target: https://translation.odoo-community.org/projects/purchase-workflow-16-0/purchase-workflow-16-0-purchase_tag
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/142/15.0
+ :target: https://runbot.odoo-community.org/runbot/142/16.0
:alt: Try me on Runbot
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -43,7 +43,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-`feedback `_.
+`feedback `_.
Do not contact contributors directly about support or help with technical issues.
@@ -73,6 +73,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-This module is part of the `OCA/purchase-workflow `_ project on GitHub.
+This module is part of the `OCA/purchase-workflow `_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/purchase_tag/__manifest__.py b/purchase_tag/__manifest__.py
index 230b997b280..0c2e4be7f5e 100644
--- a/purchase_tag/__manifest__.py
+++ b/purchase_tag/__manifest__.py
@@ -5,7 +5,7 @@
{
"name": "Purchase Tags",
"summary": "Allows to add multiple tags to purchase orders",
- "version": "15.0.1.0.0",
+ "version": "16.0.1.0.0",
"author": "ForgeFlow, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/purchase-workflow",
"category": "Purchases",
diff --git a/purchase_tag/i18n/purchase_tag.pot b/purchase_tag/i18n/purchase_tag.pot
index 964c99c1dac..c8e90d6ef98 100644
--- a/purchase_tag/i18n/purchase_tag.pot
+++ b/purchase_tag/i18n/purchase_tag.pot
@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 15.0\n"
+"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
diff --git a/purchase_tag/static/description/index.html b/purchase_tag/static/description/index.html
index 560fc91f033..bb82a162cf5 100644
--- a/purchase_tag/static/description/index.html
+++ b/purchase_tag/static/description/index.html
@@ -367,7 +367,7 @@ Purchase Tags
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
-
+
This module allows to add multiple tags to purchase orders
Table of contents
@@ -391,7 +391,7 @@
Bugs are tracked on GitHub Issues .
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-feedback .
+
feedback .
Do not contact contributors directly about support or help with technical issues.
@@ -415,7 +415,7 @@
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-
This module is part of the OCA/purchase-workflow project on GitHub.
+
This module is part of the OCA/purchase-workflow project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
From 0cfcd160ff2f9c018a8461678f72dfc56d7806b7 Mon Sep 17 00:00:00 2001
From: Ivorra78
Date: Mon, 21 Aug 2023 16:04:40 +0000
Subject: [PATCH 004/207] Added translation using Weblate (Spanish)
---
purchase_tag/README.rst | 15 ++--
purchase_tag/i18n/es.po | 90 ++++++++++++++++++++++
purchase_tag/static/description/index.html | 38 ++++-----
3 files changed, 119 insertions(+), 24 deletions(-)
create mode 100644 purchase_tag/i18n/es.po
diff --git a/purchase_tag/README.rst b/purchase_tag/README.rst
index eda7abcae2a..9dcc18944e7 100644
--- a/purchase_tag/README.rst
+++ b/purchase_tag/README.rst
@@ -2,10 +2,13 @@
Purchase Tags
=============
-.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+..
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+ !! source digest: sha256:5a4077180ca35330dc5f9467e43ce635eb0733c8f4b8114917aca5b784833a4a
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
@@ -19,11 +22,11 @@ Purchase Tags
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/purchase-workflow-16-0/purchase-workflow-16-0-purchase_tag
:alt: Translate me on Weblate
-.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/142/16.0
- :alt: Try me on Runbot
+.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
+ :target: https://runboat.odoo-community.org/builds?repo=OCA/purchase-workflow&target_branch=16.0
+ :alt: Try me on Runboat
-|badge1| |badge2| |badge3| |badge4| |badge5|
+|badge1| |badge2| |badge3| |badge4| |badge5|
This module allows to add multiple tags to purchase orders
@@ -42,7 +45,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
-If you spotted it first, help us smashing it by providing a detailed and welcomed
+If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback `_.
Do not contact contributors directly about support or help with technical issues.
diff --git a/purchase_tag/i18n/es.po b/purchase_tag/i18n/es.po
new file mode 100644
index 00000000000..9217e2dbb43
--- /dev/null
+++ b/purchase_tag/i18n/es.po
@@ -0,0 +1,90 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_tag
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 16.0\n"
+"Report-Msgid-Bugs-To: \n"
+"PO-Revision-Date: 2023-09-03 13:40+0000\n"
+"Last-Translator: Ivorra78 \n"
+"Language-Team: none\n"
+"Language: es\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=n != 1;\n"
+"X-Generator: Weblate 4.17\n"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__color
+msgid "Color"
+msgstr "Color"
+
+#. module: purchase_tag
+#: model_terms:ir.actions.act_window,help:purchase_tag.purchase_tag_action
+msgid "Create new tags for your purchase orders"
+msgstr "Crea nuevas etiquetas para tus órdenes de compra"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__create_uid
+msgid "Created by"
+msgstr "Creado por"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__create_date
+msgid "Created on"
+msgstr "Creado el"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__display_name
+msgid "Display Name"
+msgstr "Mostrar Nombre"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__id
+msgid "ID"
+msgstr "ID (identificación)"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag____last_update
+msgid "Last Modified on"
+msgstr "Última Modificación el"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__write_uid
+msgid "Last Updated by"
+msgstr "Actualizado por última vez por"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__write_date
+msgid "Last Updated on"
+msgstr "Última Actualización el"
+
+#. module: purchase_tag
+#: model:ir.model,name:purchase_tag.model_purchase_order
+msgid "Purchase Order"
+msgstr "Orden de compra"
+
+#. module: purchase_tag
+#: model:ir.model,name:purchase_tag.model_purchase_tag
+msgid "Purchase Tag"
+msgstr "Etiqueta de compra"
+
+#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__name
+msgid "Tag Name"
+msgstr "Nombre de etiqueta"
+
+#. module: purchase_tag
+#: model:ir.model.constraint,message:purchase_tag.constraint_purchase_tag_tag_name_uniq
+msgid "Tag name already exists !"
+msgstr "¡El nombre de etiqueta ya existe!"
+
+#. module: purchase_tag
+#: model:ir.actions.act_window,name:purchase_tag.purchase_tag_action
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__tag_ids
+#: model:ir.ui.menu,name:purchase_tag.menu_purchase_tag_config
+#: model_terms:ir.ui.view,arch_db:purchase_tag.purchase_tag_view_form
+msgid "Tags"
+msgstr "Etiquetas"
diff --git a/purchase_tag/static/description/index.html b/purchase_tag/static/description/index.html
index bb82a162cf5..63a828a3393 100644
--- a/purchase_tag/static/description/index.html
+++ b/purchase_tag/static/description/index.html
@@ -1,20 +1,20 @@
-
+
-
+
Purchase Tags
-
From 91182e293531666992df97ba97855f16db1c4ee6 Mon Sep 17 00:00:00 2001
From: oca-ci
Date: Tue, 21 Apr 2026 10:10:48 +0000
Subject: [PATCH 020/207] [UPD] Update purchase_tag.pot
---
purchase_tag/i18n/purchase_tag.pot | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/purchase_tag/i18n/purchase_tag.pot b/purchase_tag/i18n/purchase_tag.pot
index e51b8c7bf12..dcc25eeeb4d 100644
--- a/purchase_tag/i18n/purchase_tag.pot
+++ b/purchase_tag/i18n/purchase_tag.pot
@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 18.0\n"
+"Project-Id-Version: Odoo Server 19.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -39,11 +39,13 @@ msgid "Created on"
msgstr ""
#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__display_name
#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__display_name
msgid "Display Name"
msgstr ""
#. module: purchase_tag
+#: model:ir.model.fields,field_description:purchase_tag.field_purchase_order__id
#: model:ir.model.fields,field_description:purchase_tag.field_purchase_tag__id
msgid "ID"
msgstr ""
From 76e3f39ffa8b027a533b8f88f025f8a9007d700a Mon Sep 17 00:00:00 2001
From: OCA-git-bot
Date: Tue, 21 Apr 2026 10:13:39 +0000
Subject: [PATCH 021/207] [BOT] post-merge updates
---
README.md | 1 +
purchase_tag/README.rst | 2 +-
purchase_tag/static/description/index.html | 2 +-
setup/_metapackage/pyproject.toml | 3 ++-
4 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 6547653d704..5b44a6296da 100644
--- a/README.md
+++ b/README.md
@@ -37,6 +37,7 @@ addon | version | maintainers | summary
[purchase_partner_incoterm](purchase_partner_incoterm/) | 19.0.1.0.0 | | Add a an incoterm field for supplier and use it on purchase order
[purchase_request](purchase_request/) | 19.0.1.0.1 | | Use this module to have notification of requirements of materials and/or external services and keep track of such requirements.
[purchase_stock_price_unit_sync](purchase_stock_price_unit_sync/) | 19.0.1.0.0 | | Update cost price in stock moves already done
+[purchase_tag](purchase_tag/) | 19.0.1.0.0 | | Allows to add multiple tags to purchase orders
[//]: # (end addons)
diff --git a/purchase_tag/README.rst b/purchase_tag/README.rst
index 38472ea3935..dfbe0500355 100644
--- a/purchase_tag/README.rst
+++ b/purchase_tag/README.rst
@@ -11,7 +11,7 @@ Purchase Tags
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- !! source digest: sha256:94e58d12401c413cdb838f0cb90dea8711658fc48dc05a9f03dd376ba93af078
+ !! source digest: sha256:7e1a17aab6e4f4d094c6e036630efa0d60d026bf901bf2279dec9e0e58c0041c
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
diff --git a/purchase_tag/static/description/index.html b/purchase_tag/static/description/index.html
index 03cac9ba4eb..ca7fea47cf8 100644
--- a/purchase_tag/static/description/index.html
+++ b/purchase_tag/static/description/index.html
@@ -372,7 +372,7 @@ Purchase Tags
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-!! source digest: sha256:94e58d12401c413cdb838f0cb90dea8711658fc48dc05a9f03dd376ba93af078
+!! source digest: sha256:7e1a17aab6e4f4d094c6e036630efa0d60d026bf901bf2279dec9e0e58c0041c
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
This module allows to add multiple tags to purchase orders
diff --git a/setup/_metapackage/pyproject.toml b/setup/_metapackage/pyproject.toml
index eea2049c981..1b9c2c3acbf 100644
--- a/setup/_metapackage/pyproject.toml
+++ b/setup/_metapackage/pyproject.toml
@@ -1,6 +1,6 @@
[project]
name = "odoo-addons-oca-purchase-workflow"
-version = "19.0.20260417.0"
+version = "19.0.20260421.0"
dependencies = [
"odoo-addon-partner_supplierinfo_smartbutton==19.0.*",
"odoo-addon-procurement_purchase_no_grouping==19.0.*",
@@ -18,6 +18,7 @@ dependencies = [
"odoo-addon-purchase_partner_incoterm==19.0.*",
"odoo-addon-purchase_request==19.0.*",
"odoo-addon-purchase_stock_price_unit_sync==19.0.*",
+ "odoo-addon-purchase_tag==19.0.*",
]
classifiers=[
"Programming Language :: Python",
From 96621edfa77ceea1c944ed5664bb6466722cc58d Mon Sep 17 00:00:00 2001
From: mymage
Date: Tue, 21 Apr 2026 08:47:26 +0000
Subject: [PATCH 022/207] Translated using Weblate (Italian)
Currently translated at 100.0% (20 of 20 strings)
Translation: purchase-workflow-19.0/purchase-workflow-19.0-purchase_order_weight_volume
Translate-URL: https://translation.odoo-community.org/projects/purchase-workflow-19-0/purchase-workflow-19-0-purchase_order_weight_volume/it/
---
purchase_order_weight_volume/i18n/it.po | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/purchase_order_weight_volume/i18n/it.po b/purchase_order_weight_volume/i18n/it.po
index 6e4d4cfa390..9122333dd6d 100644
--- a/purchase_order_weight_volume/i18n/it.po
+++ b/purchase_order_weight_volume/i18n/it.po
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \n"
-"PO-Revision-Date: 2023-12-20 15:38+0000\n"
+"PO-Revision-Date: 2026-04-21 10:49+0000\n"
"Last-Translator: mymage \n"
"Language-Team: none\n"
"Language: it\n"
@@ -14,7 +14,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
-"X-Generator: Weblate 4.17\n"
+"X-Generator: Weblate 5.15.2\n"
#. module: purchase_order_weight_volume
#: model_terms:ir.ui.view,arch_db:purchase_order_weight_volume.report_purchaseorder_document
@@ -51,7 +51,7 @@ msgstr "Aziende"
#: model:ir.model.fields,field_description:purchase_order_weight_volume.field_res_company__display_name
#: model:ir.model.fields,field_description:purchase_order_weight_volume.field_res_config_settings__display_name
msgid "Display Name"
-msgstr "Nome da visualizzare"
+msgstr "Nome visualizzato"
#. module: purchase_order_weight_volume
#: model:ir.model.fields,field_description:purchase_order_weight_volume.field_purchase_order__display_order_volume_in_po
From fdd1cdf4a9c812f182b3294f6305a46d60586e76 Mon Sep 17 00:00:00 2001
From: Mateu Griful
Date: Tue, 13 Jul 2021 15:46:42 +0200
Subject: [PATCH 023/207] [ADD] purchase_advance_payment
---
purchase_advance_payment/__init__.py | 2 +
purchase_advance_payment/__manifest__.py | 19 ++
purchase_advance_payment/models/__init__.py | 2 +
purchase_advance_payment/models/payment.py | 16 ++
.../models/purchase_order.py | 86 +++++++
.../readme/CONTRIBUTORS.rst | 2 +
.../readme/DESCRIPTION.rst | 3 +
purchase_advance_payment/readme/USAGE.rst | 8 +
.../security/ir.model.access.csv | 4 +
purchase_advance_payment/tests/__init__.py | 1 +
.../tests/test_purchase_advance_payment.py | 218 ++++++++++++++++++
.../views/purchase_view.xml | 96 ++++++++
purchase_advance_payment/wizard/__init__.py | 1 +
.../wizard/purchase_advance_payment_wizard.py | 128 ++++++++++
.../purchase_advance_payment_wizard_view.xml | 53 +++++
15 files changed, 639 insertions(+)
create mode 100644 purchase_advance_payment/__init__.py
create mode 100644 purchase_advance_payment/__manifest__.py
create mode 100644 purchase_advance_payment/models/__init__.py
create mode 100644 purchase_advance_payment/models/payment.py
create mode 100644 purchase_advance_payment/models/purchase_order.py
create mode 100644 purchase_advance_payment/readme/CONTRIBUTORS.rst
create mode 100644 purchase_advance_payment/readme/DESCRIPTION.rst
create mode 100644 purchase_advance_payment/readme/USAGE.rst
create mode 100644 purchase_advance_payment/security/ir.model.access.csv
create mode 100644 purchase_advance_payment/tests/__init__.py
create mode 100644 purchase_advance_payment/tests/test_purchase_advance_payment.py
create mode 100644 purchase_advance_payment/views/purchase_view.xml
create mode 100644 purchase_advance_payment/wizard/__init__.py
create mode 100644 purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
create mode 100644 purchase_advance_payment/wizard/purchase_advance_payment_wizard_view.xml
diff --git a/purchase_advance_payment/__init__.py b/purchase_advance_payment/__init__.py
new file mode 100644
index 00000000000..9b4296142f4
--- /dev/null
+++ b/purchase_advance_payment/__init__.py
@@ -0,0 +1,2 @@
+from . import models
+from . import wizard
diff --git a/purchase_advance_payment/__manifest__.py b/purchase_advance_payment/__manifest__.py
new file mode 100644
index 00000000000..01e76a79c09
--- /dev/null
+++ b/purchase_advance_payment/__manifest__.py
@@ -0,0 +1,19 @@
+# Copyright (C) 2021 ForgeFlow S.L.
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
+
+{
+ "name": "Purchase Advance Payment",
+ "version": "14.0.1.0.0",
+ "author": "Forgeflow, Odoo Community Association (OCA)",
+ "website": "https://github.com/OCA/purchase-workflow",
+ "category": "Purchase",
+ "license": "AGPL-3",
+ "summary": "Allow to add advance payments on purchase orders",
+ "depends": ["purchase"],
+ "data": [
+ "wizard/purchase_advance_payment_wizard_view.xml",
+ "views/purchase_view.xml",
+ "security/ir.model.access.csv",
+ ],
+ "installable": True,
+}
diff --git a/purchase_advance_payment/models/__init__.py b/purchase_advance_payment/models/__init__.py
new file mode 100644
index 00000000000..2a7a713d96d
--- /dev/null
+++ b/purchase_advance_payment/models/__init__.py
@@ -0,0 +1,2 @@
+from . import payment
+from . import purchase_order
diff --git a/purchase_advance_payment/models/payment.py b/purchase_advance_payment/models/payment.py
new file mode 100644
index 00000000000..3b6473ed6af
--- /dev/null
+++ b/purchase_advance_payment/models/payment.py
@@ -0,0 +1,16 @@
+# Copyright (C) 2021 ForgeFlow S.L.
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
+
+from odoo import fields, models
+
+
+class AccountPayment(models.Model):
+
+ _inherit = "account.payment"
+
+ purchase_id = fields.Many2one(
+ "purchase.order",
+ "Purchase",
+ readonly=True,
+ states={"draft": [("readonly", False)]},
+ )
diff --git a/purchase_advance_payment/models/purchase_order.py b/purchase_advance_payment/models/purchase_order.py
new file mode 100644
index 00000000000..e4f025d669e
--- /dev/null
+++ b/purchase_advance_payment/models/purchase_order.py
@@ -0,0 +1,86 @@
+# Copyright (C) 2021 ForgeFlow S.L.
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
+
+from odoo import api, fields, models
+from odoo.tools import float_compare
+
+
+class PurchaseOrder(models.Model):
+
+ _inherit = "purchase.order"
+
+ account_payment_ids = fields.One2many(
+ "account.payment", "purchase_id", string="Pay purchase advanced", readonly=True
+ )
+ amount_residual = fields.Float(
+ "Residual amount",
+ readonly=True,
+ compute="_compute_purchase_advance_payment",
+ store=True,
+ )
+ payment_line_ids = fields.Many2many(
+ "account.move.line",
+ string="Payment move lines",
+ compute="_compute_purchase_advance_payment",
+ store=True,
+ )
+ advance_payment_status = fields.Selection(
+ selection=[
+ ("not_paid", "Not Paid"),
+ ("paid", "Paid"),
+ ("partial", "Partially Paid"),
+ ],
+ string="Advance Payment Status",
+ store=True,
+ readonly=True,
+ copy=False,
+ tracking=True,
+ compute="_compute_purchase_advance_payment",
+ )
+
+ @api.depends(
+ "currency_id",
+ "company_id",
+ "amount_total",
+ "account_payment_ids",
+ "account_payment_ids.state",
+ "account_payment_ids.move_id",
+ "account_payment_ids.move_id.line_ids",
+ "account_payment_ids.move_id.line_ids.date",
+ "account_payment_ids.move_id.line_ids.debit",
+ "account_payment_ids.move_id.line_ids.credit",
+ "account_payment_ids.move_id.line_ids.currency_id",
+ "account_payment_ids.move_id.line_ids.amount_currency",
+ )
+ def _compute_purchase_advance_payment(self):
+ for order in self:
+ mls = order.account_payment_ids.mapped("move_id.line_ids").filtered(
+ lambda x: x.account_id.internal_type == "payable"
+ and x.parent_state == "posted"
+ )
+ advance_amount = 0.0
+ for line in mls:
+ line_currency = line.currency_id or line.company_id.currency_id
+ line_amount = line.amount_currency if line.currency_id else line.balance
+ if line_currency != order.currency_id:
+ advance_amount += line.currency_id._convert(
+ line_amount,
+ order.currency_id,
+ order.company_id,
+ line.date or fields.Date.today(),
+ )
+ else:
+ advance_amount += line_amount
+ amount_residual = order.amount_total - advance_amount
+ payment_state = "not_paid"
+ if mls:
+ has_due_amount = float_compare(
+ amount_residual, 0.0, precision_rounding=order.currency_id.rounding
+ )
+ if has_due_amount <= 0:
+ payment_state = "paid"
+ elif has_due_amount > 0:
+ payment_state = "partial"
+ order.payment_line_ids = mls
+ order.amount_residual = amount_residual
+ order.advance_payment_status = payment_state
diff --git a/purchase_advance_payment/readme/CONTRIBUTORS.rst b/purchase_advance_payment/readme/CONTRIBUTORS.rst
new file mode 100644
index 00000000000..087dd29233f
--- /dev/null
+++ b/purchase_advance_payment/readme/CONTRIBUTORS.rst
@@ -0,0 +1,2 @@
+* Mateu Griful
+* Lois Rilo
diff --git a/purchase_advance_payment/readme/DESCRIPTION.rst b/purchase_advance_payment/readme/DESCRIPTION.rst
new file mode 100644
index 00000000000..2509a323453
--- /dev/null
+++ b/purchase_advance_payment/readme/DESCRIPTION.rst
@@ -0,0 +1,3 @@
+The module allows to add advance payments on purchase orders and Request
+for Quotation. The advance payments are allowed even before confirmation
+and before starting the billing process.
diff --git a/purchase_advance_payment/readme/USAGE.rst b/purchase_advance_payment/readme/USAGE.rst
new file mode 100644
index 00000000000..df9904e8b23
--- /dev/null
+++ b/purchase_advance_payment/readme/USAGE.rst
@@ -0,0 +1,8 @@
+To use this module, you need to:
+
+* Go to a purchase order.
+* Click on "Pay Purchase Advance".
+* Select the Journal and specify the amount of the advanced payment.
+* "Make Advance Payment".
+
+When generating the invoice, the system displays the advanced payments, select those you want to add to the invoice.
diff --git a/purchase_advance_payment/security/ir.model.access.csv b/purchase_advance_payment/security/ir.model.access.csv
new file mode 100644
index 00000000000..a432eb67dbf
--- /dev/null
+++ b/purchase_advance_payment/security/ir.model.access.csv
@@ -0,0 +1,4 @@
+id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
+access_account_payment_purchase_advance,account.payment purchase_advance,account.model_account_payment,purchase.group_purchase_user,1,1,1,0
+access_account_payment_method_purchase_advance,account.payment.method purchase_advance,account.model_account_payment_method,purchase.group_purchase_user,1,0,0,0
+access_account_voucher_wizard_purchase_advance,access_account_voucher_wizard_purchase_advance,model_account_voucher_wizard_purchase,purchase.group_purchase_user,1,1,1,0
diff --git a/purchase_advance_payment/tests/__init__.py b/purchase_advance_payment/tests/__init__.py
new file mode 100644
index 00000000000..beeea01aff5
--- /dev/null
+++ b/purchase_advance_payment/tests/__init__.py
@@ -0,0 +1 @@
+from . import test_purchase_advance_payment
diff --git a/purchase_advance_payment/tests/test_purchase_advance_payment.py b/purchase_advance_payment/tests/test_purchase_advance_payment.py
new file mode 100644
index 00000000000..665a9cf21de
--- /dev/null
+++ b/purchase_advance_payment/tests/test_purchase_advance_payment.py
@@ -0,0 +1,218 @@
+# Copyright (C) 2021 ForgeFlow S.L.
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
+
+
+from odoo.exceptions import ValidationError
+from odoo.tests import common
+
+
+class TestPurchaseAdvancePayment(common.SavepointCase):
+ @classmethod
+ def setUpClass(cls):
+ super().setUpClass()
+
+ # Partners
+ cls.res_partner_1 = cls.env["res.partner"].create({"name": "Wood Corner"})
+ cls.res_partner_address_1 = cls.env["res.partner"].create(
+ {"name": "Willie Burke", "parent_id": cls.res_partner_1.id}
+ )
+ cls.res_partner_2 = cls.env["res.partner"].create({"name": "Partner 12"})
+
+ # Products
+ cls.product_1 = cls.env["product.product"].create(
+ {"name": "Desk Combination", "type": "consu", "purchase_method": "purchase"}
+ )
+ cls.product_2 = cls.env["product.product"].create(
+ {"name": "Conference Chair", "type": "consu", "purchase_method": "purchase"}
+ )
+ cls.product_3 = cls.env["product.product"].create(
+ {
+ "name": "Repair Services",
+ "type": "service",
+ "purchase_method": "purchase",
+ }
+ )
+
+ cls.tax = cls.env["account.tax"].create(
+ {
+ "name": "Tax 20",
+ "type_tax_use": "purchase",
+ "amount": 20,
+ }
+ )
+
+ # purchase Order
+ cls.purchase_order_1 = cls.env["purchase.order"].create(
+ {"partner_id": cls.res_partner_1.id}
+ )
+ cls.order_line_1 = cls.env["purchase.order.line"].create(
+ {
+ "order_id": cls.purchase_order_1.id,
+ "product_id": cls.product_1.id,
+ "product_uom": cls.product_1.uom_id.id,
+ "product_qty": 10.0,
+ "price_unit": 100.0,
+ "taxes_id": cls.tax,
+ }
+ )
+ cls.order_line_2 = cls.env["purchase.order.line"].create(
+ {
+ "order_id": cls.purchase_order_1.id,
+ "product_id": cls.product_2.id,
+ "product_uom": cls.product_2.uom_id.id,
+ "product_qty": 25.0,
+ "price_unit": 40.0,
+ "taxes_id": cls.tax,
+ }
+ )
+ cls.order_line_3 = cls.env["purchase.order.line"].create(
+ {
+ "order_id": cls.purchase_order_1.id,
+ "product_id": cls.product_3.id,
+ "product_uom": cls.product_3.uom_id.id,
+ "product_qty": 20.0,
+ "price_unit": 50.0,
+ "taxes_id": cls.tax,
+ }
+ )
+
+ cls.currency_euro = cls.env["res.currency"].search([("name", "=", "EUR")])
+ cls.currency_usd = cls.env["res.currency"].search([("name", "=", "USD")])
+ cls.currency_rate = cls.env["res.currency.rate"].create(
+ {
+ "rate": 1.20,
+ "currency_id": cls.currency_usd.id,
+ }
+ )
+
+ cls.journal_eur_bank = cls.env["account.journal"].create(
+ {
+ "name": "Journal Euro Bank",
+ "type": "bank",
+ "code": "111",
+ "currency_id": cls.currency_euro.id,
+ }
+ )
+
+ cls.journal_usd_bank = cls.env["account.journal"].create(
+ {
+ "name": "Journal USD Bank",
+ "type": "bank",
+ "code": "222",
+ "currency_id": cls.currency_usd.id,
+ }
+ )
+ cls.journal_eur_cash = cls.env["account.journal"].create(
+ {
+ "name": "Journal Euro Cash",
+ "type": "cash",
+ "code": "333",
+ "currency_id": cls.currency_euro.id,
+ }
+ )
+
+ cls.journal_usd_cash = cls.env["account.journal"].create(
+ {
+ "name": "Journal USD Cash",
+ "type": "cash",
+ "code": "444",
+ "currency_id": cls.currency_usd.id,
+ }
+ )
+
+ def test_purchase_advance_payment(self):
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ 3600,
+ )
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ self.purchase_order_1.amount_total,
+ "Amounts should match",
+ )
+
+ context_payment = {
+ "active_ids": [self.purchase_order_1.id],
+ "active_id": self.purchase_order_1.id,
+ }
+
+ # Check residual > advance payment and the comparison takes
+ # into account the currency. 3001*1.2 > 3600
+ with self.assertRaises(ValidationError):
+ advance_payment_0 = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(context_payment)
+ .create(
+ {
+ "journal_id": self.journal_eur_bank.id,
+ "amount_advance": 3001,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment_0.make_advance_payment()
+
+ # Create Advance Payment 1 - EUR - bank
+ advance_payment_1 = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(context_payment)
+ .create(
+ {
+ "journal_id": self.journal_eur_bank.id,
+ "amount_advance": 100,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment_1.make_advance_payment()
+
+ self.assertEqual(self.purchase_order_1.amount_residual, 3480)
+
+ # Create Advance Payment 2 - USD - cash
+ advance_payment_2 = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(context_payment)
+ .create(
+ {
+ "journal_id": self.journal_usd_cash.id,
+ "amount_advance": 200,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment_2.make_advance_payment()
+
+ self.assertEqual(self.purchase_order_1.amount_residual, 3280)
+
+ # Confirm Purchase Order
+ self.purchase_order_1.button_confirm()
+
+ # Create Advance Payment 3 - EUR - cash
+ advance_payment_3 = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(context_payment)
+ .create(
+ {
+ "journal_id": self.journal_eur_cash.id,
+ "amount_advance": 250,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment_3.make_advance_payment()
+ self.assertEqual(self.purchase_order_1.amount_residual, 2980)
+
+ # Create Advance Payment 4 - USD - bank
+ advance_payment_4 = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(context_payment)
+ .create(
+ {
+ "journal_id": self.journal_usd_bank.id,
+ "amount_advance": 400,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment_4.make_advance_payment()
+ self.assertEqual(self.purchase_order_1.amount_residual, 2580)
diff --git a/purchase_advance_payment/views/purchase_view.xml b/purchase_advance_payment/views/purchase_view.xml
new file mode 100644
index 00000000000..44d8e6e9fb8
--- /dev/null
+++ b/purchase_advance_payment/views/purchase_view.xml
@@ -0,0 +1,96 @@
+
+
+
+ purchase.order.form
+ purchase.order
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ purchase.order.view.tree
+ purchase.order
+
+
+
+
+
+
+
+
+
+
+
+
+ purchase.order.inherit.purchase.order.tree
+ purchase.order
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/purchase_advance_payment/wizard/__init__.py b/purchase_advance_payment/wizard/__init__.py
new file mode 100644
index 00000000000..875157a0fda
--- /dev/null
+++ b/purchase_advance_payment/wizard/__init__.py
@@ -0,0 +1 @@
+from . import purchase_advance_payment_wizard
diff --git a/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py b/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
new file mode 100644
index 00000000000..0ef7fdc4fbd
--- /dev/null
+++ b/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
@@ -0,0 +1,128 @@
+# Copyright (C) 2021 ForgeFlow S.L.
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
+
+from odoo import _, api, exceptions, fields, models
+from odoo.tools import float_compare
+
+
+class AccountVoucherWizardPurchase(models.TransientModel):
+
+ _name = "account.voucher.wizard.purchase"
+ _description = "Account Voucher Wizard Purchase"
+
+ order_id = fields.Many2one("purchase.order", required=True)
+ journal_id = fields.Many2one(
+ "account.journal",
+ "Journal",
+ required=True,
+ domain=[("type", "in", ("bank", "cash"))],
+ )
+ journal_currency_id = fields.Many2one(
+ "res.currency",
+ "Journal Currency",
+ store=True,
+ readonly=False,
+ compute="_compute_get_journal_currency",
+ )
+ currency_id = fields.Many2one("res.currency", "Currency", readonly=True)
+ amount_total = fields.Monetary("Amount total", readonly=True)
+ amount_advance = fields.Monetary(
+ "Amount advanced", required=True, currency_field="journal_currency_id"
+ )
+ date = fields.Date("Date", required=True, default=fields.Date.context_today)
+ currency_amount = fields.Monetary(
+ "Curr. amount", readonly=True, currency_field="currency_id"
+ )
+ payment_ref = fields.Char("Ref.")
+
+ @api.depends("journal_id")
+ def _compute_get_journal_currency(self):
+ for wzd in self:
+ wzd.journal_currency_id = (
+ wzd.journal_id.currency_id.id or self.env.user.company_id.currency_id.id
+ )
+
+ @api.constrains("amount_advance")
+ def check_amount(self):
+ if self.amount_advance <= 0:
+ raise exceptions.ValidationError(_("Amount of advance must be positive."))
+ if self.env.context.get("active_id", False):
+ self.onchange_date()
+ if (
+ float_compare(
+ self.currency_amount,
+ self.order_id.amount_residual,
+ precision_digits=2,
+ )
+ > 0
+ ):
+ raise exceptions.ValidationError(
+ _("Amount of advance is greater than residual amount on purchase")
+ )
+
+ @api.model
+ def default_get(self, fields_list):
+ res = super().default_get(fields_list)
+ purchase_ids = self.env.context.get("active_ids", [])
+ if not purchase_ids:
+ return res
+ purchase_id = fields.first(purchase_ids)
+ purchase = self.env["purchase.order"].browse(purchase_id)
+ if "amount_total" in fields_list:
+ res.update(
+ {
+ "order_id": purchase.id,
+ "amount_total": purchase.amount_residual,
+ "currency_id": purchase.currency_id.id,
+ }
+ )
+
+ return res
+
+ @api.onchange("journal_id", "date", "amount_advance")
+ def onchange_date(self):
+ if self.journal_currency_id != self.currency_id:
+ amount_advance = self.journal_currency_id._convert(
+ self.amount_advance,
+ self.currency_id,
+ self.order_id.company_id,
+ self.date or fields.Date.today(),
+ )
+ else:
+ amount_advance = self.amount_advance
+ self.currency_amount = amount_advance
+
+ def _prepare_payment_vals(self, purchase):
+ partner_id = purchase.partner_id.id
+ return {
+ "date": self.date,
+ "amount": self.amount_advance,
+ "payment_type": "outbound",
+ "partner_type": "supplier",
+ "ref": self.payment_ref or purchase.name,
+ "journal_id": self.journal_id.id,
+ "currency_id": self.journal_currency_id.id,
+ "partner_id": partner_id,
+ "payment_method_id": self.env.ref(
+ "account.account_payment_method_manual_out"
+ ).id,
+ }
+
+ def make_advance_payment(self):
+ """Create customer paylines and validates the payment"""
+ self.ensure_one()
+ payment_obj = self.env["account.payment"]
+ purchase_obj = self.env["purchase.order"]
+
+ purchase_ids = self.env.context.get("active_ids", [])
+ if purchase_ids:
+ purchase_id = fields.first(purchase_ids)
+ purchase = purchase_obj.browse(purchase_id)
+ payment_vals = self._prepare_payment_vals(purchase)
+ payment = payment_obj.create(payment_vals)
+ purchase.account_payment_ids |= payment
+ payment.action_post()
+
+ return {
+ "type": "ir.actions.act_window_close",
+ }
diff --git a/purchase_advance_payment/wizard/purchase_advance_payment_wizard_view.xml b/purchase_advance_payment/wizard/purchase_advance_payment_wizard_view.xml
new file mode 100644
index 00000000000..41c4d5b3f45
--- /dev/null
+++ b/purchase_advance_payment/wizard/purchase_advance_payment_wizard_view.xml
@@ -0,0 +1,53 @@
+
+
+
+ Advance Payment
+ account.voucher.wizard.purchase
+ form
+
+
+
+
+
+ Advance Payment
+ ir.actions.act_window
+ account.voucher.wizard.purchase
+ form
+ new
+
+
From d2680d4592c356a3cea620cb83b191a359645da6 Mon Sep 17 00:00:00 2001
From: Lois Rilo
Date: Wed, 3 Nov 2021 15:11:49 +0100
Subject: [PATCH 024/207] [IMP] purchase_advance_payment: consider payments in
PO bills to compute residual.
---
purchase_advance_payment/README.rst | 88 ++++
.../i18n/purchase_advance_payment.pot | 221 +++++++++
.../models/purchase_order.py | 13 +-
.../static/description/index.html | 434 ++++++++++++++++++
.../tests/test_purchase_advance_payment.py | 52 ++-
.../views/purchase_view.xml | 2 +-
6 files changed, 806 insertions(+), 4 deletions(-)
create mode 100644 purchase_advance_payment/README.rst
create mode 100644 purchase_advance_payment/i18n/purchase_advance_payment.pot
create mode 100644 purchase_advance_payment/static/description/index.html
diff --git a/purchase_advance_payment/README.rst b/purchase_advance_payment/README.rst
new file mode 100644
index 00000000000..dc3ab94c339
--- /dev/null
+++ b/purchase_advance_payment/README.rst
@@ -0,0 +1,88 @@
+========================
+Purchase Advance Payment
+========================
+
+.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+ !! This file is generated by oca-gen-addon-readme !!
+ !! changes will be overwritten. !!
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
+ :target: https://odoo-community.org/page/development-status
+ :alt: Beta
+.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
+ :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
+ :alt: License: AGPL-3
+.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpurchase--workflow-lightgray.png?logo=github
+ :target: https://github.com/OCA/purchase-workflow/tree/14.0/purchase_advance_payment
+ :alt: OCA/purchase-workflow
+.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
+ :target: https://translation.odoo-community.org/projects/purchase-workflow-14-0/purchase-workflow-14-0-purchase_advance_payment
+ :alt: Translate me on Weblate
+.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
+ :target: https://runbot.odoo-community.org/runbot/142/14.0
+ :alt: Try me on Runbot
+
+|badge1| |badge2| |badge3| |badge4| |badge5|
+
+The module allows to add advance payments on purchase orders and Request
+for Quotation. The advance payments are allowed even before confirmation
+and before starting the billing process.
+
+**Table of contents**
+
+.. contents::
+ :local:
+
+Usage
+=====
+
+To use this module, you need to:
+
+* Go to a purchase order.
+* Click on "Pay Purchase Advance".
+* Select the Journal and specify the amount of the advanced payment.
+* "Make Advance Payment".
+
+When generating the invoice, the system displays the advanced payments, select those you want to add to the invoice.
+
+Bug Tracker
+===========
+
+Bugs are tracked on `GitHub Issues `_.
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed
+`feedback `_.
+
+Do not contact contributors directly about support or help with technical issues.
+
+Credits
+=======
+
+Authors
+~~~~~~~
+
+* Forgeflow
+
+Contributors
+~~~~~~~~~~~~
+
+* Mateu Griful
+* Lois Rilo
+
+Maintainers
+~~~~~~~~~~~
+
+This module is maintained by the OCA.
+
+.. image:: https://odoo-community.org/logo.png
+ :alt: Odoo Community Association
+ :target: https://odoo-community.org
+
+OCA, or the Odoo Community Association, is a nonprofit organization whose
+mission is to support the collaborative development of Odoo features and
+promote its widespread use.
+
+This module is part of the `OCA/purchase-workflow `_ project on GitHub.
+
+You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/purchase_advance_payment/i18n/purchase_advance_payment.pot b/purchase_advance_payment/i18n/purchase_advance_payment.pot
new file mode 100644
index 00000000000..38c7beadd7d
--- /dev/null
+++ b/purchase_advance_payment/i18n/purchase_advance_payment.pot
@@ -0,0 +1,221 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_advance_payment
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 14.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: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_voucher_wizard_purchase
+msgid "Account Voucher Wizard Purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.actions.act_window,name:purchase_advance_payment.action_view_account_voucher_wizard
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Advance Payment"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__advance_payment_status
+msgid "Advance Payment Status"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_kpis_tree
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_view_tree
+msgid "Amount Residual"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_advance
+msgid "Amount advanced"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Amount in Order Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+#, python-format
+msgid "Amount of advance is greater than residual amount on purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+#, python-format
+msgid "Amount of advance must be positive."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
+msgid "Amount total"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Cancel"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_uid
+msgid "Created by"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_date
+msgid "Created on"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_amount
+msgid "Curr. amount"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_id
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__date
+msgid "Date"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__display_name
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__display_name
+msgid "Display Name"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__id
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__id
+msgid "ID"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_id
+msgid "Journal"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_currency_id
+msgid "Journal Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment____last_update
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase____last_update
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order____last_update
+msgid "Last Modified on"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_uid
+msgid "Last Updated by"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_date
+msgid "Last Updated on"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Make advance payment"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__not_paid
+msgid "Not Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Operation"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
+msgid "Order"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Due Amount"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__paid
+msgid "Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__partial
+msgid "Partially Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__account_payment_ids
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Pay purchase advanced"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Payment Method"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Payment advances"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__payment_line_ids
+msgid "Payment move lines"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_payment
+msgid "Payments"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__purchase_id
+msgid "Purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+msgid "Purchase Order"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__payment_ref
+msgid "Ref."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__amount_residual
+msgid "Residual amount"
+msgstr ""
diff --git a/purchase_advance_payment/models/purchase_order.py b/purchase_advance_payment/models/purchase_order.py
index e4f025d669e..b6b5791668a 100644
--- a/purchase_advance_payment/models/purchase_order.py
+++ b/purchase_advance_payment/models/purchase_order.py
@@ -51,6 +51,9 @@ class PurchaseOrder(models.Model):
"account_payment_ids.move_id.line_ids.credit",
"account_payment_ids.move_id.line_ids.currency_id",
"account_payment_ids.move_id.line_ids.amount_currency",
+ "order_line.invoice_lines.move_id",
+ "order_line.invoice_lines.move_id.amount_total",
+ "order_line.invoice_lines.move_id.amount_residual",
)
def _compute_purchase_advance_payment(self):
for order in self:
@@ -71,9 +74,15 @@ def _compute_purchase_advance_payment(self):
)
else:
advance_amount += line_amount
- amount_residual = order.amount_total - advance_amount
+ # Consider payments in related invoices.
+ invoice_not_paid_amount = 0.0
+ for inv in order.invoice_ids:
+ invoice_not_paid_amount += inv.amount_total - inv.amount_residual
+ amount_residual = (
+ order.amount_total - advance_amount - invoice_not_paid_amount
+ )
payment_state = "not_paid"
- if mls:
+ if mls or order.invoice_ids:
has_due_amount = float_compare(
amount_residual, 0.0, precision_rounding=order.currency_id.rounding
)
diff --git a/purchase_advance_payment/static/description/index.html b/purchase_advance_payment/static/description/index.html
new file mode 100644
index 00000000000..bc37d1434d4
--- /dev/null
+++ b/purchase_advance_payment/static/description/index.html
@@ -0,0 +1,434 @@
+
+
+
+
+
+
+Purchase Advance Payment
+
+
+
+
+
Purchase Advance Payment
+
+
+
+
The module allows to add advance payments on purchase orders and Request
+for Quotation. The advance payments are allowed even before confirmation
+and before starting the billing process.
+
Table of contents
+
+
+
+
To use this module, you need to:
+
+Go to a purchase order.
+Click on “Pay Purchase Advance”.
+Select the Journal and specify the amount of the advanced payment.
+“Make Advance Payment”.
+
+
When generating the invoice, the system displays the advanced payments, select those you want to add to the invoice.
+
+
+
+
Bugs are tracked on GitHub Issues .
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed
+feedback .
+
Do not contact contributors directly about support or help with technical issues.
+
+
+
+
+
+
+
+
This module is maintained by the OCA.
+
+
OCA, or the Odoo Community Association, is a nonprofit organization whose
+mission is to support the collaborative development of Odoo features and
+promote its widespread use.
+
This module is part of the OCA/purchase-workflow project on GitHub.
+
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
+
+
+
+
+
diff --git a/purchase_advance_payment/tests/test_purchase_advance_payment.py b/purchase_advance_payment/tests/test_purchase_advance_payment.py
index 665a9cf21de..017d71a3807 100644
--- a/purchase_advance_payment/tests/test_purchase_advance_payment.py
+++ b/purchase_advance_payment/tests/test_purchase_advance_payment.py
@@ -2,6 +2,7 @@
# License AGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
+from odoo import fields
from odoo.exceptions import ValidationError
from odoo.tests import common
@@ -120,7 +121,7 @@ def setUpClass(cls):
}
)
- def test_purchase_advance_payment(self):
+ def test_01_purchase_advance_payment(self):
self.assertEqual(
self.purchase_order_1.amount_residual,
3600,
@@ -216,3 +217,52 @@ def test_purchase_advance_payment(self):
)
advance_payment_4.make_advance_payment()
self.assertEqual(self.purchase_order_1.amount_residual, 2580)
+
+ def test_02_residual_amount_with_bill(self):
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ 3600,
+ )
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ self.purchase_order_1.amount_total,
+ )
+ # Create Advance Payment 1 - EUR - bank
+ context_payment = {
+ "active_ids": [self.purchase_order_1.id],
+ "active_id": self.purchase_order_1.id,
+ }
+ # Create Advance Payment 2 - USD - cash
+ advance_payment_2 = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(context_payment)
+ .create(
+ {
+ "journal_id": self.journal_usd_cash.id,
+ "amount_advance": 200,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment_2.make_advance_payment()
+ self.assertEqual(self.purchase_order_1.amount_residual, 3400)
+ # generate bill, pay bill, check amount residual.
+ self.purchase_order_1.button_confirm()
+ self.assertEqual(self.purchase_order_1.invoice_status, "to invoice")
+ self.purchase_order_1.action_create_invoice()
+ self.assertEqual(self.purchase_order_1.invoice_status, "invoiced")
+ self.assertEqual(self.purchase_order_1.amount_residual, 3400)
+ invoice = self.purchase_order_1.invoice_ids
+ invoice.invoice_date = fields.Date.today()
+ invoice.action_post()
+ active_ids = invoice.ids
+ self.env["account.payment.register"].with_context(
+ active_model="account.move", active_ids=active_ids
+ ).create(
+ {
+ "amount": 1200.0,
+ "group_payment": True,
+ "payment_difference_handling": "open",
+ }
+ )._create_payments()
+ self.assertEqual(self.purchase_order_1.amount_residual, 2200)
diff --git a/purchase_advance_payment/views/purchase_view.xml b/purchase_advance_payment/views/purchase_view.xml
index 44d8e6e9fb8..95d54657920 100644
--- a/purchase_advance_payment/views/purchase_view.xml
+++ b/purchase_advance_payment/views/purchase_view.xml
@@ -11,7 +11,7 @@
string="Pay purchase advanced"
type="action"
groups="account.group_account_invoice"
- attrs="{'invisible': ['|',('state', 'in', ['done','cancel']),('invoice_status', 'in', ['invoiced'])]}"
+ attrs="{'invisible': ['|',('state', 'in', ['done','cancel']),('amount_residual', '=', 0)]}"
/>
From 77b1267ee51bf9216e2560df5626526f93089ab8 Mon Sep 17 00:00:00 2001
From: OCA-git-bot
Date: Thu, 4 Nov 2021 16:21:07 +0000
Subject: [PATCH 025/207] [ADD] icon.png
---
.../static/description/icon.png | Bin 0 -> 9455 bytes
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100644 purchase_advance_payment/static/description/icon.png
diff --git a/purchase_advance_payment/static/description/icon.png b/purchase_advance_payment/static/description/icon.png
new file mode 100644
index 0000000000000000000000000000000000000000..3a0328b516c4980e8e44cdb63fd945757ddd132d
GIT binary patch
literal 9455
zcmW++2RxMjAAjx~&dlBk9S+%}OXg)AGE&Cb*&}d0jUxM@u(PQx^-s)697TX`ehR4?GS^qbkof1cslKgkU)h65qZ9Oc=ml_0temigYLJfnz{IDzUf>bGs4N!v3=Z3jMq&A#7%rM5eQ#dc?k~!
zVpnB`o+K7|Al`Q_U;eD$B
zfJtP*jH`siUq~{KE)`jP2|#TUEFGRryE2`i0**z#*^6~AI|YzIWy$Cu#CSLW3q=GA
z6`?GZymC;dCPk~rBS%eCb`5OLr;RUZ;D`}um=H)BfVIq%7VhiMr)_#G0N#zrNH|__
zc+blN2UAB0=617@>_u;MPHN;P;N#YoE=)R#i$k_`UAA>WWCcEVMh~L_
z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u;dD_unryX_NhT8*Tj>BTrTTL&!?O+%Rv;b?B??gSzdp?6Uug9{
zd@V08Z$BdI?fpoCS$)t4mg4rT8Q_I}h`0d-vYZ^|dOB*Q^S|xqTV*vIg?@fVFSmMpaw0qtTRbx}
z({Pg?#{2`sc9)M5N$*N|4;^t$+QP?#mov
zGVC@I*lBVrOU-%2y!7%)fAKjpEFsgQc4{amtiHb95KQEwvf<(3T<9-Zm$xIew#P22
zc2Ix|App^>v6(3L_MCU0d3W##AB0M~3D00EWoKZqsJYT(#@w$Y_H7G22M~ApVFTRHMI_3be)Lkn#0F*V8Pq
zc}`Cjy$bE;FJ6H7p=0y#R>`}-m4(0F>%@P|?7fx{=R^uFdISRnZ2W_xQhD{YuR3t<
z{6yxu=4~JkeA;|(J6_nv#>Nvs&FuLA&PW^he@t(UwFFE8)|a!R{`E`K`i^ZnyE4$k
z;(749Ix|oi$c3QbEJ3b~D_kQsPz~fIUKym($a_7dJ?o+40*OLl^{=&oq$<#Q(yyrp
z{J-FAniyAw9tPbe&IhQ|a`DqFTVQGQ&Gq3!C2==4x{6EJwiPZ8zub-iXoUtkJiG{}
zPaR&}_fn8_z~(=;5lD-aPWD3z8PZS@AaUiomF!G8I}Mf>e~0g#BelA-5#`cj;O5>N
Xviia!U7SGha1wx#SCgwmn*{w2TRX*I
literal 0
HcmV?d00001
From 46cb6a210c881dddccacb2217a2025d83bc0b6e9 Mon Sep 17 00:00:00 2001
From: Khalid Hazam
Date: Wed, 29 Dec 2021 16:10:36 +0000
Subject: [PATCH 026/207] Added translation using Weblate (French)
---
purchase_advance_payment/i18n/fr.po | 222 ++++++++++++++++++++++++++++
1 file changed, 222 insertions(+)
create mode 100644 purchase_advance_payment/i18n/fr.po
diff --git a/purchase_advance_payment/i18n/fr.po b/purchase_advance_payment/i18n/fr.po
new file mode 100644
index 00000000000..0392173c55b
--- /dev/null
+++ b/purchase_advance_payment/i18n/fr.po
@@ -0,0 +1,222 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_advance_payment
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 14.0\n"
+"Report-Msgid-Bugs-To: \n"
+"Last-Translator: Automatically generated\n"
+"Language-Team: none\n"
+"Language: fr\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=n > 1;\n"
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_voucher_wizard_purchase
+msgid "Account Voucher Wizard Purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.actions.act_window,name:purchase_advance_payment.action_view_account_voucher_wizard
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Advance Payment"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__advance_payment_status
+msgid "Advance Payment Status"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_kpis_tree
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_view_tree
+msgid "Amount Residual"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_advance
+msgid "Amount advanced"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Amount in Order Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+#, python-format
+msgid "Amount of advance is greater than residual amount on purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+#, python-format
+msgid "Amount of advance must be positive."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
+msgid "Amount total"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Cancel"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_uid
+msgid "Created by"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_date
+msgid "Created on"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_amount
+msgid "Curr. amount"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_id
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__date
+msgid "Date"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__display_name
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__display_name
+msgid "Display Name"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__id
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__id
+msgid "ID"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_id
+msgid "Journal"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_currency_id
+msgid "Journal Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment____last_update
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase____last_update
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order____last_update
+msgid "Last Modified on"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_uid
+msgid "Last Updated by"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_date
+msgid "Last Updated on"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Make advance payment"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__not_paid
+msgid "Not Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Operation"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
+msgid "Order"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Due Amount"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__paid
+msgid "Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__partial
+msgid "Partially Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__account_payment_ids
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Pay purchase advanced"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Payment Method"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Payment advances"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__payment_line_ids
+msgid "Payment move lines"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_payment
+msgid "Payments"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__purchase_id
+msgid "Purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+msgid "Purchase Order"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__payment_ref
+msgid "Ref."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__amount_residual
+msgid "Residual amount"
+msgstr ""
From fbf15847ab788530a64142bb59bcd3920369b9b8 Mon Sep 17 00:00:00 2001
From: Lois Rilo
Date: Tue, 4 Jan 2022 16:36:00 +0100
Subject: [PATCH 027/207] [FIX] purchase_advance_payment: do not count twice
reconciled pre-payments in PO residual amount.
---
.../models/purchase_order.py | 17 ++--
.../tests/test_purchase_advance_payment.py | 96 +++++++++++++++++++
2 files changed, 107 insertions(+), 6 deletions(-)
diff --git a/purchase_advance_payment/models/purchase_order.py b/purchase_advance_payment/models/purchase_order.py
index b6b5791668a..789f567c0c4 100644
--- a/purchase_advance_payment/models/purchase_order.py
+++ b/purchase_advance_payment/models/purchase_order.py
@@ -64,7 +64,14 @@ def _compute_purchase_advance_payment(self):
advance_amount = 0.0
for line in mls:
line_currency = line.currency_id or line.company_id.currency_id
- line_amount = line.amount_currency if line.currency_id else line.balance
+ # Exclude reconciled pre-payments amount because once reconciled
+ # the pre-payment will reduce bill residual amount like any
+ # other payment.
+ line_amount = (
+ line.amount_residual_currency
+ if line.currency_id
+ else line.amount_residual
+ )
if line_currency != order.currency_id:
advance_amount += line.currency_id._convert(
line_amount,
@@ -75,12 +82,10 @@ def _compute_purchase_advance_payment(self):
else:
advance_amount += line_amount
# Consider payments in related invoices.
- invoice_not_paid_amount = 0.0
+ invoice_paid_amount = 0.0
for inv in order.invoice_ids:
- invoice_not_paid_amount += inv.amount_total - inv.amount_residual
- amount_residual = (
- order.amount_total - advance_amount - invoice_not_paid_amount
- )
+ invoice_paid_amount += inv.amount_total - inv.amount_residual
+ amount_residual = order.amount_total - advance_amount - invoice_paid_amount
payment_state = "not_paid"
if mls or order.invoice_ids:
has_due_amount = float_compare(
diff --git a/purchase_advance_payment/tests/test_purchase_advance_payment.py b/purchase_advance_payment/tests/test_purchase_advance_payment.py
index 017d71a3807..16fd626fb9e 100644
--- a/purchase_advance_payment/tests/test_purchase_advance_payment.py
+++ b/purchase_advance_payment/tests/test_purchase_advance_payment.py
@@ -245,6 +245,8 @@ def test_02_residual_amount_with_bill(self):
)
)
advance_payment_2.make_advance_payment()
+ pre_payment = self.purchase_order_1.account_payment_ids
+ self.assertEqual(len(pre_payment), 1)
self.assertEqual(self.purchase_order_1.amount_residual, 3400)
# generate bill, pay bill, check amount residual.
self.purchase_order_1.button_confirm()
@@ -266,3 +268,97 @@ def test_02_residual_amount_with_bill(self):
}
)._create_payments()
self.assertEqual(self.purchase_order_1.amount_residual, 2200)
+
+ # Reconciling the pre-payment should not affect amount_residual in PO.
+ (
+ liquidity_lines,
+ counterpart_lines,
+ writeoff_lines,
+ ) = pre_payment._seek_for_lines()
+ (
+ counterpart_lines
+ + invoice.line_ids.filtered(
+ lambda line: line.account_internal_type == "payable"
+ )
+ ).reconcile()
+ self.purchase_order_1.invalidate_cache()
+ self.assertEqual(self.purchase_order_1.amount_residual, 2200)
+
+ def test_03_residual_amount_big_pre_payment(self):
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ 3600,
+ )
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ self.purchase_order_1.amount_total,
+ )
+ # Create Advance Payment 1 - EUR - bank
+ context_payment = {
+ "active_ids": [self.purchase_order_1.id],
+ "active_id": self.purchase_order_1.id,
+ }
+ # Create Advance Payment 2 - USD - cash
+ advance_payment_2 = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(context_payment)
+ .create(
+ {
+ "journal_id": self.journal_usd_cash.id,
+ "amount_advance": 2000,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment_2.make_advance_payment()
+ pre_payment = self.purchase_order_1.account_payment_ids
+ self.assertEqual(len(pre_payment), 1)
+ self.assertEqual(self.purchase_order_1.amount_residual, 1600)
+ # generate a partial bill, reconcile with pre payment, check amount residual.
+ self.purchase_order_1.button_confirm()
+ self.assertEqual(self.purchase_order_1.invoice_status, "to invoice")
+ # Adjust billing method to then do a partial bill with a total amount
+ # smaller than the pre-payment.
+ self.product_1.purchase_method = "receive"
+ self.order_line_1.qty_received = 10.0
+ self.assertEqual(self.order_line_1.qty_to_invoice, 10.0)
+ self.product_2.purchase_method = "receive"
+ self.order_line_2.qty_received = 0.0
+ self.assertEqual(self.order_line_2.qty_to_invoice, 0.0)
+ self.product_3.purchase_method = "receive"
+ self.order_line_3.qty_received = 0.0
+ self.assertEqual(self.order_line_3.qty_to_invoice, 0.0)
+ self.purchase_order_1.action_create_invoice()
+ self.assertEqual(self.purchase_order_1.invoice_status, "invoiced")
+ self.assertEqual(self.purchase_order_1.amount_residual, 1600)
+ invoice = self.purchase_order_1.invoice_ids
+ invoice.invoice_date = fields.Date.today()
+ invoice.action_post()
+ self.assertEqual(invoice.amount_residual, 1200)
+ active_ids = invoice.ids
+ self.env["account.payment.register"].with_context(
+ active_model="account.move", active_ids=active_ids
+ ).create(
+ {
+ "amount": 300.0,
+ "group_payment": True,
+ "payment_difference_handling": "open",
+ }
+ )._create_payments()
+ self.assertEqual(invoice.amount_residual, 900)
+ self.assertEqual(self.purchase_order_1.amount_residual, 1300)
+
+ # Partially reconciling the pre-payment should not affect amount_residual in PO.
+ (
+ liquidity_lines,
+ counterpart_lines,
+ writeoff_lines,
+ ) = pre_payment._seek_for_lines()
+ (
+ counterpart_lines
+ + invoice.line_ids.filtered(
+ lambda line: line.account_internal_type == "payable"
+ )
+ ).reconcile()
+ self.purchase_order_1.invalidate_cache()
+ self.assertEqual(self.purchase_order_1.amount_residual, 1300)
From 25cc6acf26e984ee66fd8b84ac8e99ed6e933acd Mon Sep 17 00:00:00 2001
From: Jasmin Solanki
Date: Tue, 18 Jan 2022 16:52:18 +0530
Subject: [PATCH 028/207] [MIG] purchase_advance_payment: Migration to 15.0
---
purchase_advance_payment/README.rst | 10 +++----
purchase_advance_payment/__manifest__.py | 2 +-
.../i18n/purchase_advance_payment.pot | 18 +++++--------
.../models/purchase_order.py | 1 -
.../static/description/index.html | 6 ++---
.../tests/test_purchase_advance_payment.py | 27 ++++++++++++-------
.../views/purchase_view.xml | 2 +-
.../wizard/purchase_advance_payment_wizard.py | 25 +++++++++--------
8 files changed, 46 insertions(+), 45 deletions(-)
diff --git a/purchase_advance_payment/README.rst b/purchase_advance_payment/README.rst
index dc3ab94c339..ebfd928c518 100644
--- a/purchase_advance_payment/README.rst
+++ b/purchase_advance_payment/README.rst
@@ -14,13 +14,13 @@ Purchase Advance Payment
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpurchase--workflow-lightgray.png?logo=github
- :target: https://github.com/OCA/purchase-workflow/tree/14.0/purchase_advance_payment
+ :target: https://github.com/OCA/purchase-workflow/tree/15.0/purchase_advance_payment
:alt: OCA/purchase-workflow
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
- :target: https://translation.odoo-community.org/projects/purchase-workflow-14-0/purchase-workflow-14-0-purchase_advance_payment
+ :target: https://translation.odoo-community.org/projects/purchase-workflow-15-0/purchase-workflow-15-0-purchase_advance_payment
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/142/14.0
+ :target: https://runbot.odoo-community.org/runbot/142/15.0
:alt: Try me on Runbot
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -52,7 +52,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-`feedback `_.
+`feedback `_.
Do not contact contributors directly about support or help with technical issues.
@@ -83,6 +83,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-This module is part of the `OCA/purchase-workflow `_ project on GitHub.
+This module is part of the `OCA/purchase-workflow `_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/purchase_advance_payment/__manifest__.py b/purchase_advance_payment/__manifest__.py
index 01e76a79c09..6e63bd4177c 100644
--- a/purchase_advance_payment/__manifest__.py
+++ b/purchase_advance_payment/__manifest__.py
@@ -3,7 +3,7 @@
{
"name": "Purchase Advance Payment",
- "version": "14.0.1.0.0",
+ "version": "15.0.1.0.0",
"author": "Forgeflow, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/purchase-workflow",
"category": "Purchase",
diff --git a/purchase_advance_payment/i18n/purchase_advance_payment.pot b/purchase_advance_payment/i18n/purchase_advance_payment.pot
index 38c7beadd7d..7cd03dd46b3 100644
--- a/purchase_advance_payment/i18n/purchase_advance_payment.pot
+++ b/purchase_advance_payment/i18n/purchase_advance_payment.pot
@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 14.0\n"
+"Project-Id-Version: Odoo Server 15.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -35,6 +35,11 @@ msgstr ""
msgid "Amount Residual"
msgstr ""
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
+msgid "Amount Total"
+msgstr ""
+
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_advance
msgid "Amount advanced"
@@ -57,11 +62,6 @@ msgstr ""
msgid "Amount of advance must be positive."
msgstr ""
-#. module: purchase_advance_payment
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
-msgid "Amount total"
-msgstr ""
-
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
msgid "Cancel"
@@ -94,16 +94,12 @@ msgid "Date"
msgstr ""
#. module: purchase_advance_payment
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__display_name
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__display_name
msgid "Display Name"
msgstr ""
#. module: purchase_advance_payment
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__id
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__id
msgid "ID"
msgstr ""
@@ -118,9 +114,7 @@ msgid "Journal Currency"
msgstr ""
#. module: purchase_advance_payment
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment____last_update
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase____last_update
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order____last_update
msgid "Last Modified on"
msgstr ""
diff --git a/purchase_advance_payment/models/purchase_order.py b/purchase_advance_payment/models/purchase_order.py
index 789f567c0c4..0f58b465c28 100644
--- a/purchase_advance_payment/models/purchase_order.py
+++ b/purchase_advance_payment/models/purchase_order.py
@@ -30,7 +30,6 @@ class PurchaseOrder(models.Model):
("paid", "Paid"),
("partial", "Partially Paid"),
],
- string="Advance Payment Status",
store=True,
readonly=True,
copy=False,
diff --git a/purchase_advance_payment/static/description/index.html b/purchase_advance_payment/static/description/index.html
index bc37d1434d4..5c70bf46113 100644
--- a/purchase_advance_payment/static/description/index.html
+++ b/purchase_advance_payment/static/description/index.html
@@ -367,7 +367,7 @@ Purchase Advance Payment
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
-
+
The module allows to add advance payments on purchase orders and Request
for Quotation. The advance payments are allowed even before confirmation
and before starting the billing process.
@@ -400,7 +400,7 @@
Bugs are tracked on GitHub Issues .
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-feedback .
+feedback .
Do not contact contributors directly about support or help with technical issues.
@@ -425,7 +425,7 @@
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-
This module is part of the OCA/purchase-workflow project on GitHub.
+
This module is part of the OCA/purchase-workflow project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
diff --git a/purchase_advance_payment/tests/test_purchase_advance_payment.py b/purchase_advance_payment/tests/test_purchase_advance_payment.py
index 16fd626fb9e..4b66610c48b 100644
--- a/purchase_advance_payment/tests/test_purchase_advance_payment.py
+++ b/purchase_advance_payment/tests/test_purchase_advance_payment.py
@@ -7,7 +7,7 @@
from odoo.tests import common
-class TestPurchaseAdvancePayment(common.SavepointCase):
+class TestPurchaseAdvancePayment(common.TransactionCase):
@classmethod
def setUpClass(cls):
super().setUpClass()
@@ -77,7 +77,16 @@ def setUpClass(cls):
}
)
- cls.currency_euro = cls.env["res.currency"].search([("name", "=", "EUR")])
+ cls.active_euro = False
+ cls.currency_euro = (
+ cls.env["res.currency"]
+ .with_context(active_test=False)
+ .search([("name", "=", "EUR")])
+ )
+ # active euro currency if inactive for test
+ if not cls.currency_euro.active:
+ cls.currency_euro.active = True
+ cls.active_euro = True
cls.currency_usd = cls.env["res.currency"].search([("name", "=", "USD")])
cls.currency_rate = cls.env["res.currency.rate"].create(
{
@@ -142,7 +151,7 @@ def test_01_purchase_advance_payment(self):
with self.assertRaises(ValidationError):
advance_payment_0 = (
self.env["account.voucher.wizard.purchase"]
- .with_context(context_payment)
+ .with_context(**context_payment)
.create(
{
"journal_id": self.journal_eur_bank.id,
@@ -156,7 +165,7 @@ def test_01_purchase_advance_payment(self):
# Create Advance Payment 1 - EUR - bank
advance_payment_1 = (
self.env["account.voucher.wizard.purchase"]
- .with_context(context_payment)
+ .with_context(**context_payment)
.create(
{
"journal_id": self.journal_eur_bank.id,
@@ -172,7 +181,7 @@ def test_01_purchase_advance_payment(self):
# Create Advance Payment 2 - USD - cash
advance_payment_2 = (
self.env["account.voucher.wizard.purchase"]
- .with_context(context_payment)
+ .with_context(**context_payment)
.create(
{
"journal_id": self.journal_usd_cash.id,
@@ -191,7 +200,7 @@ def test_01_purchase_advance_payment(self):
# Create Advance Payment 3 - EUR - cash
advance_payment_3 = (
self.env["account.voucher.wizard.purchase"]
- .with_context(context_payment)
+ .with_context(**context_payment)
.create(
{
"journal_id": self.journal_eur_cash.id,
@@ -206,7 +215,7 @@ def test_01_purchase_advance_payment(self):
# Create Advance Payment 4 - USD - bank
advance_payment_4 = (
self.env["account.voucher.wizard.purchase"]
- .with_context(context_payment)
+ .with_context(**context_payment)
.create(
{
"journal_id": self.journal_usd_bank.id,
@@ -235,7 +244,7 @@ def test_02_residual_amount_with_bill(self):
# Create Advance Payment 2 - USD - cash
advance_payment_2 = (
self.env["account.voucher.wizard.purchase"]
- .with_context(context_payment)
+ .with_context(**context_payment)
.create(
{
"journal_id": self.journal_usd_cash.id,
@@ -301,7 +310,7 @@ def test_03_residual_amount_big_pre_payment(self):
# Create Advance Payment 2 - USD - cash
advance_payment_2 = (
self.env["account.voucher.wizard.purchase"]
- .with_context(context_payment)
+ .with_context(**context_payment)
.create(
{
"journal_id": self.journal_usd_cash.id,
diff --git a/purchase_advance_payment/views/purchase_view.xml b/purchase_advance_payment/views/purchase_view.xml
index 95d54657920..0bd22ba850e 100644
--- a/purchase_advance_payment/views/purchase_view.xml
+++ b/purchase_advance_payment/views/purchase_view.xml
@@ -24,7 +24,7 @@
/>
-
+
diff --git a/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py b/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
index 0ef7fdc4fbd..80f62dc8bbb 100644
--- a/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
+++ b/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
@@ -2,11 +2,9 @@
# License AGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
from odoo import _, api, exceptions, fields, models
-from odoo.tools import float_compare
class AccountVoucherWizardPurchase(models.TransientModel):
-
_name = "account.voucher.wizard.purchase"
_description = "Account Voucher Wizard Purchase"
@@ -25,13 +23,17 @@ class AccountVoucherWizardPurchase(models.TransientModel):
compute="_compute_get_journal_currency",
)
currency_id = fields.Many2one("res.currency", "Currency", readonly=True)
- amount_total = fields.Monetary("Amount total", readonly=True)
+ amount_total = fields.Monetary(readonly=True)
amount_advance = fields.Monetary(
"Amount advanced", required=True, currency_field="journal_currency_id"
)
- date = fields.Date("Date", required=True, default=fields.Date.context_today)
+ date = fields.Date(required=True, default=fields.Date.context_today)
currency_amount = fields.Monetary(
- "Curr. amount", readonly=True, currency_field="currency_id"
+ "Curr. amount",
+ readonly=True,
+ currency_field="currency_id",
+ compute="_compute_currency_amount",
+ store=True,
)
payment_ref = fields.Char("Ref.")
@@ -44,15 +46,12 @@ def _compute_get_journal_currency(self):
@api.constrains("amount_advance")
def check_amount(self):
- if self.amount_advance <= 0:
+ if self.journal_currency_id.compare_amounts(self.amount_advance, 0.0) <= 0:
raise exceptions.ValidationError(_("Amount of advance must be positive."))
if self.env.context.get("active_id", False):
- self.onchange_date()
if (
- float_compare(
- self.currency_amount,
- self.order_id.amount_residual,
- precision_digits=2,
+ self.currency_id.compare_amounts(
+ self.currency_amount, self.order_id.amount_residual
)
> 0
):
@@ -79,8 +78,8 @@ def default_get(self, fields_list):
return res
- @api.onchange("journal_id", "date", "amount_advance")
- def onchange_date(self):
+ @api.depends("journal_id", "date", "amount_advance")
+ def _compute_currency_amount(self):
if self.journal_currency_id != self.currency_id:
amount_advance = self.journal_currency_id._convert(
self.amount_advance,
From 11e97685fff60cf21d9f262c7f8fed842c6137ec Mon Sep 17 00:00:00 2001
From: sonhd91
Date: Thu, 5 Jan 2023 13:43:01 +0700
Subject: [PATCH 029/207] [16.0][MIG] purchase_advance_payment: Migrate to
version 16.0
---
purchase_advance_payment/README.rst | 18 ++-
purchase_advance_payment/__manifest__.py | 2 +-
purchase_advance_payment/i18n/fr.po | 18 +--
.../i18n/purchase_advance_payment.pot | 4 +-
.../models/purchase_order.py | 2 +-
.../readme/CONTRIBUTORS.rst | 3 +
purchase_advance_payment/readme/CREDITS.rst | 1 +
.../static/description/index.html | 28 +++-
.../tests/test_purchase_advance_payment.py | 143 +++++++++++++++---
.../views/purchase_view.xml | 2 +-
10 files changed, 169 insertions(+), 52 deletions(-)
create mode 100644 purchase_advance_payment/readme/CREDITS.rst
diff --git a/purchase_advance_payment/README.rst b/purchase_advance_payment/README.rst
index ebfd928c518..4e589857b37 100644
--- a/purchase_advance_payment/README.rst
+++ b/purchase_advance_payment/README.rst
@@ -14,13 +14,13 @@ Purchase Advance Payment
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpurchase--workflow-lightgray.png?logo=github
- :target: https://github.com/OCA/purchase-workflow/tree/15.0/purchase_advance_payment
+ :target: https://github.com/OCA/purchase-workflow/tree/16.0/purchase_advance_payment
:alt: OCA/purchase-workflow
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
- :target: https://translation.odoo-community.org/projects/purchase-workflow-15-0/purchase-workflow-15-0-purchase_advance_payment
+ :target: https://translation.odoo-community.org/projects/purchase-workflow-16-0/purchase-workflow-16-0-purchase_advance_payment
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/142/15.0
+ :target: https://runbot.odoo-community.org/runbot/142/16.0
:alt: Try me on Runbot
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -52,7 +52,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-`feedback `_.
+`feedback `_.
Do not contact contributors directly about support or help with technical issues.
@@ -69,6 +69,14 @@ Contributors
* Mateu Griful
* Lois Rilo
+* `Trobz `_:
+
+ * Son Ho
+
+Other credits
+~~~~~~~~~~~~~
+
+The migration of this module from 15.0 to 16.0 was financially supported by Camptocamp
Maintainers
~~~~~~~~~~~
@@ -83,6 +91,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-This module is part of the `OCA/purchase-workflow `_ project on GitHub.
+This module is part of the `OCA/purchase-workflow `_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/purchase_advance_payment/__manifest__.py b/purchase_advance_payment/__manifest__.py
index 6e63bd4177c..0821aa4fb22 100644
--- a/purchase_advance_payment/__manifest__.py
+++ b/purchase_advance_payment/__manifest__.py
@@ -3,7 +3,7 @@
{
"name": "Purchase Advance Payment",
- "version": "15.0.1.0.0",
+ "version": "16.0.1.0.0",
"author": "Forgeflow, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/purchase-workflow",
"category": "Purchase",
diff --git a/purchase_advance_payment/i18n/fr.po b/purchase_advance_payment/i18n/fr.po
index 0392173c55b..837ff265e93 100644
--- a/purchase_advance_payment/i18n/fr.po
+++ b/purchase_advance_payment/i18n/fr.po
@@ -36,6 +36,11 @@ msgstr ""
msgid "Amount Residual"
msgstr ""
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
+msgid "Amount Total"
+msgstr ""
+
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_advance
msgid "Amount advanced"
@@ -47,22 +52,19 @@ msgid "Amount in Order Currency"
msgstr ""
#. module: purchase_advance_payment
+#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
#, python-format
msgid "Amount of advance is greater than residual amount on purchase"
msgstr ""
#. module: purchase_advance_payment
+#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
#, python-format
msgid "Amount of advance must be positive."
msgstr ""
-#. module: purchase_advance_payment
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
-msgid "Amount total"
-msgstr ""
-
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
msgid "Cancel"
@@ -95,16 +97,12 @@ msgid "Date"
msgstr ""
#. module: purchase_advance_payment
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__display_name
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__display_name
msgid "Display Name"
msgstr ""
#. module: purchase_advance_payment
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__id
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__id
msgid "ID"
msgstr ""
@@ -119,9 +117,7 @@ msgid "Journal Currency"
msgstr ""
#. module: purchase_advance_payment
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment____last_update
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase____last_update
-#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order____last_update
msgid "Last Modified on"
msgstr ""
diff --git a/purchase_advance_payment/i18n/purchase_advance_payment.pot b/purchase_advance_payment/i18n/purchase_advance_payment.pot
index 7cd03dd46b3..b8b69c32c05 100644
--- a/purchase_advance_payment/i18n/purchase_advance_payment.pot
+++ b/purchase_advance_payment/i18n/purchase_advance_payment.pot
@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 15.0\n"
+"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -51,12 +51,14 @@ msgid "Amount in Order Currency"
msgstr ""
#. module: purchase_advance_payment
+#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
#, python-format
msgid "Amount of advance is greater than residual amount on purchase"
msgstr ""
#. module: purchase_advance_payment
+#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
#, python-format
msgid "Amount of advance must be positive."
diff --git a/purchase_advance_payment/models/purchase_order.py b/purchase_advance_payment/models/purchase_order.py
index 0f58b465c28..398e0661246 100644
--- a/purchase_advance_payment/models/purchase_order.py
+++ b/purchase_advance_payment/models/purchase_order.py
@@ -57,7 +57,7 @@ class PurchaseOrder(models.Model):
def _compute_purchase_advance_payment(self):
for order in self:
mls = order.account_payment_ids.mapped("move_id.line_ids").filtered(
- lambda x: x.account_id.internal_type == "payable"
+ lambda x: x.account_id.account_type == "liability_payable"
and x.parent_state == "posted"
)
advance_amount = 0.0
diff --git a/purchase_advance_payment/readme/CONTRIBUTORS.rst b/purchase_advance_payment/readme/CONTRIBUTORS.rst
index 087dd29233f..8077f0385e3 100644
--- a/purchase_advance_payment/readme/CONTRIBUTORS.rst
+++ b/purchase_advance_payment/readme/CONTRIBUTORS.rst
@@ -1,2 +1,5 @@
* Mateu Griful
* Lois Rilo
+* `Trobz `_:
+
+ * Son Ho
diff --git a/purchase_advance_payment/readme/CREDITS.rst b/purchase_advance_payment/readme/CREDITS.rst
new file mode 100644
index 00000000000..70bc307ad0b
--- /dev/null
+++ b/purchase_advance_payment/readme/CREDITS.rst
@@ -0,0 +1 @@
+The migration of this module from 15.0 to 16.0 was financially supported by Camptocamp
diff --git a/purchase_advance_payment/static/description/index.html b/purchase_advance_payment/static/description/index.html
index 5c70bf46113..b0f5f98337f 100644
--- a/purchase_advance_payment/static/description/index.html
+++ b/purchase_advance_payment/static/description/index.html
@@ -367,7 +367,7 @@ Purchase Advance Payment
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
-
+
The module allows to add advance payments on purchase orders and Request
for Quotation. The advance payments are allowed even before confirmation
and before starting the billing process.
@@ -379,7 +379,8 @@ Purchase Advance Payment
Credits
@@ -400,7 +401,7 @@
Bugs are tracked on GitHub Issues .
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-feedback .
+feedback .
Do not contact contributors directly about support or help with technical issues.
+
+
+
The migration of this module from 15.0 to 16.0 was financially supported by Camptocamp
-
+
This module is maintained by the OCA.
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-
This module is part of the OCA/purchase-workflow project on GitHub.
+
This module is part of the OCA/purchase-workflow project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
diff --git a/purchase_advance_payment/tests/test_purchase_advance_payment.py b/purchase_advance_payment/tests/test_purchase_advance_payment.py
index 4b66610c48b..6c04b9e393e 100644
--- a/purchase_advance_payment/tests/test_purchase_advance_payment.py
+++ b/purchase_advance_payment/tests/test_purchase_advance_payment.py
@@ -11,6 +11,7 @@ class TestPurchaseAdvancePayment(common.TransactionCase):
@classmethod
def setUpClass(cls):
super().setUpClass()
+ cls.env = cls.env(context=dict(cls.env.context, tracking_disable=True))
# Partners
cls.res_partner_1 = cls.env["res.partner"].create({"name": "Wood Corner"})
@@ -46,6 +47,21 @@ def setUpClass(cls):
cls.purchase_order_1 = cls.env["purchase.order"].create(
{"partner_id": cls.res_partner_1.id}
)
+ cls.purchase_order_2 = cls.env["purchase.order"].create(
+ {"partner_id": cls.res_partner_2.id}
+ )
+
+ cls.order_line_2_1 = cls.env["purchase.order.line"].create(
+ {
+ "order_id": cls.purchase_order_2.id,
+ "product_id": cls.product_1.id,
+ "product_uom": cls.product_1.uom_id.id,
+ "product_qty": 10.0,
+ "price_unit": 100.0,
+ "taxes_id": cls.tax,
+ }
+ )
+
cls.order_line_1 = cls.env["purchase.order.line"].create(
{
"order_id": cls.purchase_order_1.id,
@@ -130,15 +146,40 @@ def setUpClass(cls):
}
)
- def test_01_purchase_advance_payment(self):
+ def test_00_with_context_payment(self):
+ context_payment_2 = {
+ "active_ids": [self.purchase_order_2.id],
+ "active_id": self.purchase_order_2.id,
+ }
+ advance_payment_with_context = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(**context_payment_2)
+ .create(
+ {
+ "journal_id": self.journal_eur_bank.id,
+ "amount_advance": 10,
+ }
+ )
+ )
+ self.assertEqual(advance_payment_with_context.order_id, self.purchase_order_2)
+
+ advance_payment_without_context = self.env[
+ "account.voucher.wizard.purchase"
+ ].create(
+ {
+ "journal_id": self.journal_eur_bank.id,
+ "amount_advance": 20,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
self.assertEqual(
- self.purchase_order_1.amount_residual,
- 3600,
+ advance_payment_without_context.order_id, self.purchase_order_1
)
+
+ def test_01_purchase_advance_payment(self):
self.assertEqual(
self.purchase_order_1.amount_residual,
- self.purchase_order_1.amount_total,
- "Amounts should match",
+ 3600,
)
context_payment = {
@@ -146,22 +187,6 @@ def test_01_purchase_advance_payment(self):
"active_id": self.purchase_order_1.id,
}
- # Check residual > advance payment and the comparison takes
- # into account the currency. 3001*1.2 > 3600
- with self.assertRaises(ValidationError):
- advance_payment_0 = (
- self.env["account.voucher.wizard.purchase"]
- .with_context(**context_payment)
- .create(
- {
- "journal_id": self.journal_eur_bank.id,
- "amount_advance": 3001,
- "order_id": self.purchase_order_1.id,
- }
- )
- )
- advance_payment_0.make_advance_payment()
-
# Create Advance Payment 1 - EUR - bank
advance_payment_1 = (
self.env["account.voucher.wizard.purchase"]
@@ -287,10 +312,10 @@ def test_02_residual_amount_with_bill(self):
(
counterpart_lines
+ invoice.line_ids.filtered(
- lambda line: line.account_internal_type == "payable"
+ lambda line: line.account_type == "liability_payable"
)
).reconcile()
- self.purchase_order_1.invalidate_cache()
+ self.purchase_order_1.env.invalidate_all()
self.assertEqual(self.purchase_order_1.amount_residual, 2200)
def test_03_residual_amount_big_pre_payment(self):
@@ -366,8 +391,76 @@ def test_03_residual_amount_big_pre_payment(self):
(
counterpart_lines
+ invoice.line_ids.filtered(
- lambda line: line.account_internal_type == "payable"
+ lambda line: line.account_type == "liability_payable"
)
).reconcile()
- self.purchase_order_1.invalidate_cache()
+ self.purchase_order_1.env.invalidate_all()
self.assertEqual(self.purchase_order_1.amount_residual, 1300)
+
+ def test_04_residual_amount_with_no_amount_left(self):
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ 3600,
+ )
+ context_payment = {
+ "active_ids": [self.purchase_order_1.id],
+ "active_id": self.purchase_order_1.id,
+ }
+ # Create Advance Payment with the same residual amount
+ advance_payment = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(**context_payment)
+ .create(
+ {
+ "journal_id": self.journal_usd_cash.id,
+ "amount_advance": 3600,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment.make_advance_payment()
+ self.assertEqual(self.purchase_order_1.amount_residual, 0)
+ self.assertEqual(self.purchase_order_1.advance_payment_status, "paid")
+
+ def test_05_check_residual_amount_warning(self):
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ 3600,
+ )
+ self.assertEqual(
+ self.purchase_order_1.amount_residual,
+ self.purchase_order_1.amount_total,
+ "Amounts should match",
+ )
+
+ context_payment = {
+ "active_ids": [self.purchase_order_1.id],
+ "active_id": self.purchase_order_1.id,
+ }
+
+ # Check residual > advance payment and the comparison takes
+ # into account the currency. 3001*1.2 > 3600
+ mes = "Amount of advance is greater than residual amount on purchase"
+ with self.assertRaisesRegex(ValidationError, mes):
+ advance_payment_0 = (
+ self.env["account.voucher.wizard.purchase"]
+ .with_context(**context_payment)
+ .create(
+ {
+ "journal_id": self.journal_eur_bank.id,
+ "amount_advance": 3001,
+ "order_id": self.purchase_order_1.id,
+ }
+ )
+ )
+ advance_payment_0.make_advance_payment()
+ # Check positive advance payment
+ mes2 = "Amount of advance must be positive."
+ with self.assertRaisesRegex(ValidationError, mes2):
+ self.env["account.voucher.wizard.purchase"].create(
+ {
+ "journal_id": self.journal_eur_bank.id,
+ "amount_advance": -300,
+ "order_id": self.purchase_order_2.id,
+ }
+ )
diff --git a/purchase_advance_payment/views/purchase_view.xml b/purchase_advance_payment/views/purchase_view.xml
index 0bd22ba850e..1c26a200198 100644
--- a/purchase_advance_payment/views/purchase_view.xml
+++ b/purchase_advance_payment/views/purchase_view.xml
@@ -24,7 +24,7 @@
/>
-
+
From b6f0e990ae88b5da25dad8d8e2295c7b8a261ad7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?gelo=20joga=20Rodr=C3=ADguez?=
Date: Tue, 18 Apr 2023 07:56:42 +0000
Subject: [PATCH 030/207] Added translation using Weblate (Spanish)
---
purchase_advance_payment/i18n/es.po | 220 ++++++++++++++++++++++++++++
1 file changed, 220 insertions(+)
create mode 100644 purchase_advance_payment/i18n/es.po
diff --git a/purchase_advance_payment/i18n/es.po b/purchase_advance_payment/i18n/es.po
new file mode 100644
index 00000000000..6fc5ff90c64
--- /dev/null
+++ b/purchase_advance_payment/i18n/es.po
@@ -0,0 +1,220 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_advance_payment
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 16.0\n"
+"Report-Msgid-Bugs-To: \n"
+"PO-Revision-Date: 2023-07-20 10:15+0000\n"
+"Last-Translator: Ivorra78 \n"
+"Language-Team: none\n"
+"Language: es\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=n != 1;\n"
+"X-Generator: Weblate 4.17\n"
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_voucher_wizard_purchase
+msgid "Account Voucher Wizard Purchase"
+msgstr "Asistente de compra de vales de cuenta"
+
+#. module: purchase_advance_payment
+#: model:ir.actions.act_window,name:purchase_advance_payment.action_view_account_voucher_wizard
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Advance Payment"
+msgstr "Pago por Adelantado"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__advance_payment_status
+msgid "Advance Payment Status"
+msgstr "Estado del pago anticipado"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_kpis_tree
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_view_tree
+msgid "Amount Residual"
+msgstr "Importe residual"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
+msgid "Amount Total"
+msgstr "Importe total"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_advance
+msgid "Amount advanced"
+msgstr "Importe anticipado"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Amount in Order Currency"
+msgstr "Importe en la moneda del pedido"
+
+#. module: purchase_advance_payment
+#. odoo-python
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+#, python-format
+msgid "Amount of advance is greater than residual amount on purchase"
+msgstr "El importe anticipado es mayor que el importe pendiente del pedido"
+
+#. module: purchase_advance_payment
+#. odoo-python
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+#, python-format
+msgid "Amount of advance must be positive."
+msgstr "El importe del anticipo debe ser positivo."
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Cancel"
+msgstr "Cancelar"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_uid
+msgid "Created by"
+msgstr "Creado por"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_date
+msgid "Created on"
+msgstr "Creado el"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_amount
+msgid "Curr. amount"
+msgstr "Importe en divisa"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_id
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Currency"
+msgstr "Moneda"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__date
+msgid "Date"
+msgstr "Fecha"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
+msgid "Display Name"
+msgstr "Nombre mostrado"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
+msgid "ID"
+msgstr "ID"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_id
+msgid "Journal"
+msgstr "Diario"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_currency_id
+msgid "Journal Currency"
+msgstr "Moneda del diario"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase____last_update
+msgid "Last Modified on"
+msgstr "última modificación el"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_uid
+msgid "Last Updated by"
+msgstr "última modificación por"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_date
+msgid "Last Updated on"
+msgstr "Última actualización el"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Make advance payment"
+msgstr "Realizar anticipo"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__not_paid
+msgid "Not Paid"
+msgstr "No pagado"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Operation"
+msgstr "Operación"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
+msgid "Order"
+msgstr "Pedido"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Currency"
+msgstr "Moneda del pedido"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Due Amount"
+msgstr "Importe pendiente del pedido"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__paid
+msgid "Paid"
+msgstr "Pagado"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__partial
+msgid "Partially Paid"
+msgstr "Pagado parcialmente"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__account_payment_ids
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Pay purchase advanced"
+msgstr "Pagar anticipo de compra"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Payment Method"
+msgstr "Método de pago"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Payment advances"
+msgstr "Anticipos"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__payment_line_ids
+msgid "Payment move lines"
+msgstr "Líneas de asiento de pago"
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_payment
+msgid "Payments"
+msgstr "Pagos"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__purchase_id
+msgid "Purchase"
+msgstr "Compra"
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+msgid "Purchase Order"
+msgstr "Pedido de compra"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__payment_ref
+msgid "Ref."
+msgstr "Ref."
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__amount_residual
+msgid "Residual amount"
+msgstr "Importe pendiente"
From b3db64559504d6c610fb381ebf879d936bd16182 Mon Sep 17 00:00:00 2001
From: Adriano Prado
Date: Fri, 25 Aug 2023 20:40:33 +0000
Subject: [PATCH 031/207] Added translation using Weblate (Portuguese (Brazil))
---
purchase_advance_payment/README.rst | 15 +-
purchase_advance_payment/i18n/pt_BR.po | 220 ++++++++++++++++++
.../static/description/index.html | 42 ++--
3 files changed, 251 insertions(+), 26 deletions(-)
create mode 100644 purchase_advance_payment/i18n/pt_BR.po
diff --git a/purchase_advance_payment/README.rst b/purchase_advance_payment/README.rst
index 4e589857b37..6054dfcd581 100644
--- a/purchase_advance_payment/README.rst
+++ b/purchase_advance_payment/README.rst
@@ -2,10 +2,13 @@
Purchase Advance Payment
========================
-.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+..
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+ !! source digest: sha256:c8c4c2c055f100b2245f4176a379aa4c1d6ea3e28c815fd9faa0ec6e109f71b7
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
@@ -19,11 +22,11 @@ Purchase Advance Payment
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/purchase-workflow-16-0/purchase-workflow-16-0-purchase_advance_payment
:alt: Translate me on Weblate
-.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/142/16.0
- :alt: Try me on Runbot
+.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
+ :target: https://runboat.odoo-community.org/builds?repo=OCA/purchase-workflow&target_branch=16.0
+ :alt: Try me on Runboat
-|badge1| |badge2| |badge3| |badge4| |badge5|
+|badge1| |badge2| |badge3| |badge4| |badge5|
The module allows to add advance payments on purchase orders and Request
for Quotation. The advance payments are allowed even before confirmation
@@ -51,7 +54,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
-If you spotted it first, help us smashing it by providing a detailed and welcomed
+If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback `_.
Do not contact contributors directly about support or help with technical issues.
diff --git a/purchase_advance_payment/i18n/pt_BR.po b/purchase_advance_payment/i18n/pt_BR.po
new file mode 100644
index 00000000000..e4bb6813051
--- /dev/null
+++ b/purchase_advance_payment/i18n/pt_BR.po
@@ -0,0 +1,220 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_advance_payment
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 16.0\n"
+"Report-Msgid-Bugs-To: \n"
+"PO-Revision-Date: 2023-11-01 11:38+0000\n"
+"Last-Translator: Adriano Prado \n"
+"Language-Team: none\n"
+"Language: pt_BR\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=n > 1;\n"
+"X-Generator: Weblate 4.17\n"
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_voucher_wizard_purchase
+msgid "Account Voucher Wizard Purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.actions.act_window,name:purchase_advance_payment.action_view_account_voucher_wizard
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Advance Payment"
+msgstr "Pagamento Antecipado"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__advance_payment_status
+msgid "Advance Payment Status"
+msgstr "Situação Pagamento Antecipado"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_kpis_tree
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_view_tree
+msgid "Amount Residual"
+msgstr "Valor Residual"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
+msgid "Amount Total"
+msgstr "Valor Total"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_advance
+msgid "Amount advanced"
+msgstr "Valor Antecipado"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Amount in Order Currency"
+msgstr "Valor na Moeda do Pedido"
+
+#. module: purchase_advance_payment
+#. odoo-python
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+#, python-format
+msgid "Amount of advance is greater than residual amount on purchase"
+msgstr "O valor do adiantamento é maior que o valor residual na compra"
+
+#. module: purchase_advance_payment
+#. odoo-python
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+#, python-format
+msgid "Amount of advance must be positive."
+msgstr "O valor do adiantamento deve ser positivo."
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Cancel"
+msgstr "Cancelar"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_uid
+msgid "Created by"
+msgstr "Criado por"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_date
+msgid "Created on"
+msgstr "Criado em"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_amount
+msgid "Curr. amount"
+msgstr "Valor moeda"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_id
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Currency"
+msgstr "Moeda"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__date
+msgid "Date"
+msgstr "Data"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
+msgid "Display Name"
+msgstr "Nome Exibição"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
+msgid "ID"
+msgstr "ID"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_id
+msgid "Journal"
+msgstr "Diário"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_currency_id
+msgid "Journal Currency"
+msgstr "Moeda Díario"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase____last_update
+msgid "Last Modified on"
+msgstr "Última Modificação em"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_uid
+msgid "Last Updated by"
+msgstr "Última Atualização por"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_date
+msgid "Last Updated on"
+msgstr "Última Atualização em"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Make advance payment"
+msgstr "Faça o Pagamento Antecipado"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__not_paid
+msgid "Not Paid"
+msgstr "Não Pago"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Operation"
+msgstr "Operação"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
+msgid "Order"
+msgstr "Pedido"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Currency"
+msgstr "Moeda Pedido"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Due Amount"
+msgstr "Valor Devido do Pedido"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__paid
+msgid "Paid"
+msgstr "Pago"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__partial
+msgid "Partially Paid"
+msgstr "Parcialmente Pago"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__account_payment_ids
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Pay purchase advanced"
+msgstr "Pagar Compra Antecipadamente"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Payment Method"
+msgstr "Forma de Pagamento"
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Payment advances"
+msgstr "Adiantamentos de pagamento"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__payment_line_ids
+msgid "Payment move lines"
+msgstr "Linhas Movimento Pagamento"
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_payment
+msgid "Payments"
+msgstr "Pagamentos"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__purchase_id
+msgid "Purchase"
+msgstr "Compra"
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+msgid "Purchase Order"
+msgstr "Pedido Compra"
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__payment_ref
+msgid "Ref."
+msgstr "Ref."
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__amount_residual
+msgid "Residual amount"
+msgstr "Valor Residual"
diff --git a/purchase_advance_payment/static/description/index.html b/purchase_advance_payment/static/description/index.html
index b0f5f98337f..eccde0ec8f6 100644
--- a/purchase_advance_payment/static/description/index.html
+++ b/purchase_advance_payment/static/description/index.html
@@ -1,20 +1,20 @@
-
+
-
+
Purchase Advance Payment
-
-
Purchase Advance Payment
+
+
+
+
+
+
+
Purchase Advance Payment
-
+
The module allows to add advance payments on purchase orders and Request
for Quotation. The advance payments are allowed even before confirmation
and before starting the billing process.
@@ -388,7 +393,7 @@
Purchase Advance Payment
-
+
To use this module, you need to:
Go to a purchase order.
@@ -400,7 +405,7 @@
select those you want to add to the invoice.
-
+
Bugs are tracked on GitHub Issues .
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
@@ -408,15 +413,15 @@
Do not contact contributors directly about support or help with technical issues.
-
+
-
+
The migration of this module from 15.0 to 16.0 was financially supported
by Camptocamp
-
+
This module is maintained by the OCA.
@@ -452,5 +457,6 @@
+
From 3c225b6bef18eab76eeeccc8545f4617adc05837 Mon Sep 17 00:00:00 2001
From: Weblate
Date: Tue, 5 Aug 2025 13:07:17 +0000
Subject: [PATCH 071/207] Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.
Translation: purchase-workflow-18.0/purchase-workflow-18.0-purchase_advance_payment
Translate-URL: https://translation.odoo-community.org/projects/purchase-workflow-18-0/purchase-workflow-18-0-purchase_advance_payment/
---
purchase_advance_payment/i18n/es.po | 8 +-------
purchase_advance_payment/i18n/fr.po | 11 ++++-------
purchase_advance_payment/i18n/it.po | 11 ++++-------
purchase_advance_payment/i18n/pt_BR.po | 8 +-------
4 files changed, 10 insertions(+), 28 deletions(-)
diff --git a/purchase_advance_payment/i18n/es.po b/purchase_advance_payment/i18n/es.po
index afc254c7b8a..5a3560eaf52 100644
--- a/purchase_advance_payment/i18n/es.po
+++ b/purchase_advance_payment/i18n/es.po
@@ -62,14 +62,12 @@ msgstr "Importe en la moneda del pedido"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
-#, python-format
msgid "Amount of advance is greater than residual amount on purchase"
msgstr "El importe anticipado es mayor que el importe pendiente del pedido"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
-#, python-format
msgid "Amount of advance must be positive."
msgstr "El importe del anticipo debe ser positivo."
@@ -186,11 +184,6 @@ msgstr "No pagado"
msgid "Not Reconciled"
msgstr ""
-#. module: purchase_advance_payment
-#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
-msgid "Not Sent"
-msgstr ""
-
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
msgid "Order"
@@ -254,6 +247,7 @@ msgstr "Compra"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_form
msgid "Purchase Order"
msgstr "Pedido de compra"
diff --git a/purchase_advance_payment/i18n/fr.po b/purchase_advance_payment/i18n/fr.po
index f802e5f071b..ab2542e8d02 100644
--- a/purchase_advance_payment/i18n/fr.po
+++ b/purchase_advance_payment/i18n/fr.po
@@ -62,14 +62,12 @@ msgstr "Montant en devise"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
-#, python-format
msgid "Amount of advance is greater than residual amount on purchase"
msgstr "Le montant de l'avance est supérieur au montant résiduel sur l'achat"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
-#, python-format
msgid "Amount of advance must be positive."
msgstr "Le montant de l'avance doit être positif."
@@ -188,11 +186,6 @@ msgstr "Non Payé"
msgid "Not Reconciled"
msgstr "Non Réconcilié"
-#. module: purchase_advance_payment
-#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
-msgid "Not Sent"
-msgstr "Non Envoyé"
-
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
msgid "Order"
@@ -256,6 +249,7 @@ msgstr "Achat"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_form
msgid "Purchase Order"
msgstr "Commande d'Achat"
@@ -273,3 +267,6 @@ msgstr "Montant Résiduel"
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
msgid "Vendor Advance Payments"
msgstr "Paiements anticipés aux fournisseurs"
+
+#~ msgid "Not Sent"
+#~ msgstr "Non Envoyé"
diff --git a/purchase_advance_payment/i18n/it.po b/purchase_advance_payment/i18n/it.po
index 4f24d8f0c2a..7e1817676c2 100644
--- a/purchase_advance_payment/i18n/it.po
+++ b/purchase_advance_payment/i18n/it.po
@@ -62,14 +62,12 @@ msgstr "Importo nella valuta dell'ordine"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
-#, python-format
msgid "Amount of advance is greater than residual amount on purchase"
msgstr "L'importo dell'anticipo è superiore all'importo residuo in vendita"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
-#, python-format
msgid "Amount of advance must be positive."
msgstr "L'importo dell'anticipo deve essere positivo."
@@ -190,11 +188,6 @@ msgstr "Non pagato"
msgid "Not Reconciled"
msgstr "Non riconciliata"
-#. module: purchase_advance_payment
-#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
-msgid "Not Sent"
-msgstr "Non inviato"
-
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
msgid "Order"
@@ -258,6 +251,7 @@ msgstr "Acquisto"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_form
msgid "Purchase Order"
msgstr "Ordine di acquisto"
@@ -276,6 +270,9 @@ msgstr "Importo residuo"
msgid "Vendor Advance Payments"
msgstr "Anticipo pagamenti fornitore"
+#~ msgid "Not Sent"
+#~ msgstr "Non inviato"
+
#~ msgid "Operation"
#~ msgstr "Operazione"
diff --git a/purchase_advance_payment/i18n/pt_BR.po b/purchase_advance_payment/i18n/pt_BR.po
index ee8dfe75f89..ed53dc0a8cb 100644
--- a/purchase_advance_payment/i18n/pt_BR.po
+++ b/purchase_advance_payment/i18n/pt_BR.po
@@ -62,14 +62,12 @@ msgstr "Valor na Moeda do Pedido"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
-#, python-format
msgid "Amount of advance is greater than residual amount on purchase"
msgstr "O valor do adiantamento é maior que o valor residual na compra"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
-#, python-format
msgid "Amount of advance must be positive."
msgstr "O valor do adiantamento deve ser positivo."
@@ -186,11 +184,6 @@ msgstr "Não Pago"
msgid "Not Reconciled"
msgstr ""
-#. module: purchase_advance_payment
-#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
-msgid "Not Sent"
-msgstr ""
-
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
msgid "Order"
@@ -254,6 +247,7 @@ msgstr "Compra"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_form
msgid "Purchase Order"
msgstr "Pedido Compra"
From 1dc45f42eea62c05262d5a1f00d19d4ad8e9d165 Mon Sep 17 00:00:00 2001
From: Daniel Reis
Date: Fri, 22 Aug 2025 10:15:45 +0000
Subject: [PATCH 072/207] Added translation using Weblate (Portuguese)
---
purchase_advance_payment/i18n/pt.po | 266 ++++++++++++++++++++++++++++
1 file changed, 266 insertions(+)
create mode 100644 purchase_advance_payment/i18n/pt.po
diff --git a/purchase_advance_payment/i18n/pt.po b/purchase_advance_payment/i18n/pt.po
new file mode 100644
index 00000000000..58b0c17f985
--- /dev/null
+++ b/purchase_advance_payment/i18n/pt.po
@@ -0,0 +1,266 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_advance_payment
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 18.0\n"
+"Report-Msgid-Bugs-To: \n"
+"Last-Translator: Automatically generated\n"
+"Language-Team: none\n"
+"Language: pt\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=n > 1;\n"
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_voucher_wizard_purchase
+msgid "Account Voucher Wizard Purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.actions.act_window,name:purchase_advance_payment.action_view_account_voucher_wizard
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Advance Payment"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__advance_payment_status
+msgid "Advance Payment Status"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.actions.act_window,name:purchase_advance_payment.action_account_advance_payments_payable
+#: model:ir.ui.menu,name:purchase_advance_payment.menu_account_advance_payments_payable
+msgid "Advance Payments"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_kpis_tree
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_view_tree
+msgid "Amount Residual"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
+msgid "Amount Total"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_advance
+msgid "Amount advanced"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Amount in Order Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#. odoo-python
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+msgid "Amount of advance is greater than residual amount on purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#. odoo-python
+#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
+msgid "Amount of advance must be positive."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_res_config_settings__auto_post_purchase_advance_payments
+msgid "Auto Post Purchase Advance Payments"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_res_config_settings__auto_reconcile_purchase_advance_payments
+msgid "Auto Reconcile Purchase Advance Payments"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.res_config_settings_view_form_purchase
+msgid "Automatically reconcile payments upon bill confirmation."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__available_payment_method_line_ids
+msgid "Available Payment Method Line"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Cancel"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_uid
+msgid "Created by"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_date
+msgid "Created on"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_amount
+msgid "Curr. amount"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_id
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__date
+msgid "Date"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
+msgid "Display Name"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
+msgid "ID"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.res_config_settings_view_form_purchase
+msgid ""
+"If enabled, advance payments created from POs are automatically posted."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.res_config_settings_view_form_purchase
+msgid ""
+"If enabled, advance payments created from POs are automatically reconciled "
+"upon bill confirmation."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_id
+msgid "Journal"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_currency_id
+msgid "Journal Currency"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_move
+msgid "Journal Entry"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_uid
+msgid "Last Updated by"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_date
+msgid "Last Updated on"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Make advance payment"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__not_paid
+msgid "Not Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
+msgid "Not Reconciled"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
+msgid "Order"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
+msgid "Order Due Amount"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__paid
+msgid "Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__partial
+msgid "Partially Paid"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__account_payment_ids
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Pay purchase advanced"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__payment_method_line_id
+msgid "Payment Method"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_supplier_payment_tree
+msgid "Payment Sent?"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
+msgid "Payment advances"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__payment_line_ids
+msgid "Payment move lines"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_account_payment
+msgid "Payments"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_res_config_settings
+msgid "Procurement purchase grouping settings"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__purchase_id
+msgid "Purchase"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model,name:purchase_advance_payment.model_purchase_order
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_form
+msgid "Purchase Order"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__payment_ref
+msgid "Ref."
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__amount_residual
+msgid "Residual amount"
+msgstr ""
+
+#. module: purchase_advance_payment
+#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
+msgid "Vendor Advance Payments"
+msgstr ""
From 3919705e749f2c385c5535f700294df2f343ba56 Mon Sep 17 00:00:00 2001
From: Daniel Reis
Date: Fri, 22 Aug 2025 10:27:41 +0000
Subject: [PATCH 073/207] Translated using Weblate (Portuguese)
Currently translated at 100.0% (48 of 48 strings)
Translation: purchase-workflow-18.0/purchase-workflow-18.0-purchase_advance_payment
Translate-URL: https://translation.odoo-community.org/projects/purchase-workflow-18-0/purchase-workflow-18-0-purchase_advance_payment/pt/
---
purchase_advance_payment/i18n/pt.po | 100 +++++++++++++++-------------
1 file changed, 53 insertions(+), 47 deletions(-)
diff --git a/purchase_advance_payment/i18n/pt.po b/purchase_advance_payment/i18n/pt.po
index 58b0c17f985..1c3f6dc3179 100644
--- a/purchase_advance_payment/i18n/pt.po
+++ b/purchase_advance_payment/i18n/pt.po
@@ -6,135 +6,139 @@ msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 18.0\n"
"Report-Msgid-Bugs-To: \n"
-"Last-Translator: Automatically generated\n"
+"PO-Revision-Date: 2025-08-22 12:25+0000\n"
+"Last-Translator: Daniel Reis \n"
"Language-Team: none\n"
"Language: pt\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
+"X-Generator: Weblate 5.10.4\n"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_account_voucher_wizard_purchase
msgid "Account Voucher Wizard Purchase"
-msgstr ""
+msgstr "Assistente de vales de compra"
#. module: purchase_advance_payment
#: model:ir.actions.act_window,name:purchase_advance_payment.action_view_account_voucher_wizard
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
msgid "Advance Payment"
-msgstr ""
+msgstr "Pagamento Adiantado"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__advance_payment_status
msgid "Advance Payment Status"
-msgstr ""
+msgstr "Estado do Pagamento Adiantado"
#. module: purchase_advance_payment
#: model:ir.actions.act_window,name:purchase_advance_payment.action_account_advance_payments_payable
#: model:ir.ui.menu,name:purchase_advance_payment.menu_account_advance_payments_payable
msgid "Advance Payments"
-msgstr ""
+msgstr "Pagamentos Adiantados"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_kpis_tree
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_view_tree
msgid "Amount Residual"
-msgstr ""
+msgstr "Montante Residual"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_total
msgid "Amount Total"
-msgstr ""
+msgstr "Montante Total"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__amount_advance
msgid "Amount advanced"
-msgstr ""
+msgstr "Montante Adiantado"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
msgid "Amount in Order Currency"
-msgstr ""
+msgstr "Montante na Moeda da Compra"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
msgid "Amount of advance is greater than residual amount on purchase"
-msgstr ""
+msgstr "O valor do adiantamento é maior que o valor residual na compra"
#. module: purchase_advance_payment
#. odoo-python
#: code:addons/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py:0
msgid "Amount of advance must be positive."
-msgstr ""
+msgstr "O valor do adiantamento deve ser positivo."
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_res_config_settings__auto_post_purchase_advance_payments
msgid "Auto Post Purchase Advance Payments"
-msgstr ""
+msgstr "Validação automática dos pagamentos adiantados"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_res_config_settings__auto_reconcile_purchase_advance_payments
msgid "Auto Reconcile Purchase Advance Payments"
-msgstr ""
+msgstr "Auto reconciliação dos pagamentos adiantados"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.res_config_settings_view_form_purchase
msgid "Automatically reconcile payments upon bill confirmation."
-msgstr ""
+msgstr "Reconciliação automática dos pagamentos com a validação da fatura."
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__available_payment_method_line_ids
msgid "Available Payment Method Line"
-msgstr ""
+msgstr "Métodos de Pagamento Disponíveis"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
msgid "Cancel"
-msgstr ""
+msgstr "Cancelar"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_uid
msgid "Created by"
-msgstr ""
+msgstr "Criado por"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__create_date
msgid "Created on"
-msgstr ""
+msgstr "Criado em"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_amount
msgid "Curr. amount"
-msgstr ""
+msgstr "Valor na moeda"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__currency_id
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
msgid "Currency"
-msgstr ""
+msgstr "Moeda"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__date
msgid "Date"
-msgstr ""
+msgstr "Data"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
msgid "Display Name"
-msgstr ""
+msgstr "Nome Apresentado"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
msgid "ID"
-msgstr ""
+msgstr "ID"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.res_config_settings_view_form_purchase
msgid ""
"If enabled, advance payments created from POs are automatically posted."
msgstr ""
+"Se ativado, os pagamentos criados a partir da ordem de compra são "
+"automaticamente contabilizados."
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.res_config_settings_view_form_purchase
@@ -142,125 +146,127 @@ msgid ""
"If enabled, advance payments created from POs are automatically reconciled "
"upon bill confirmation."
msgstr ""
+"Se ativado, os pagamentos adiantados criados a partir de uma ordem de compra "
+"são automaticamente reconciliados com a validação da fatura."
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_id
msgid "Journal"
-msgstr ""
+msgstr "Diário"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__journal_currency_id
msgid "Journal Currency"
-msgstr ""
+msgstr "Moeda do Diário"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_account_move
msgid "Journal Entry"
-msgstr ""
+msgstr "Lançamento Contabilístico"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_uid
msgid "Last Updated by"
-msgstr ""
+msgstr "Última Atualização por"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__write_date
msgid "Last Updated on"
-msgstr ""
+msgstr "Última Atualização em"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
msgid "Make advance payment"
-msgstr ""
+msgstr "Fazer Pagamento Adiantado"
#. module: purchase_advance_payment
#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__not_paid
msgid "Not Paid"
-msgstr ""
+msgstr "Não Pago"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
msgid "Not Reconciled"
-msgstr ""
+msgstr "Não Reconciliado"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__order_id
msgid "Order"
-msgstr ""
+msgstr "Pedido"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_voucher_wizard
msgid "Order Due Amount"
-msgstr ""
+msgstr "Valor em Dívida do Pedido"
#. module: purchase_advance_payment
#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__paid
msgid "Paid"
-msgstr ""
+msgstr "Pago"
#. module: purchase_advance_payment
#: model:ir.model.fields.selection,name:purchase_advance_payment.selection__purchase_order__advance_payment_status__partial
msgid "Partially Paid"
-msgstr ""
+msgstr "Parcialmente Pago"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__account_payment_ids
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
msgid "Pay purchase advanced"
-msgstr ""
+msgstr "Pagar Compra Adiantadamente"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__payment_method_line_id
msgid "Payment Method"
-msgstr ""
+msgstr "Método de Pagamento"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_supplier_payment_tree
msgid "Payment Sent?"
-msgstr ""
+msgstr "Pagamento Enviado?"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.purchase_order_form
msgid "Payment advances"
-msgstr ""
+msgstr "Pagamentos Adiantados"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__payment_line_ids
msgid "Payment move lines"
-msgstr ""
+msgstr "Linhas de Pagamento"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_account_payment
msgid "Payments"
-msgstr ""
+msgstr "Pagamentos"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_res_config_settings
msgid "Procurement purchase grouping settings"
-msgstr ""
+msgstr "Definições de agrupamento de compras"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__purchase_id
msgid "Purchase"
-msgstr ""
+msgstr "Compra"
#. module: purchase_advance_payment
#: model:ir.model,name:purchase_advance_payment.model_purchase_order
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_form
msgid "Purchase Order"
-msgstr ""
+msgstr "Ordem de Compra"
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__payment_ref
msgid "Ref."
-msgstr ""
+msgstr "Ref."
#. module: purchase_advance_payment
#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__amount_residual
msgid "Residual amount"
-msgstr ""
+msgstr "Valor Residual"
#. module: purchase_advance_payment
#: model_terms:ir.ui.view,arch_db:purchase_advance_payment.view_account_payment_search
msgid "Vendor Advance Payments"
-msgstr ""
+msgstr "Pagamentos Adiantados a Fornecedores"
From f088f1ba48036de2273ee3d0b6bbe3962d748a32 Mon Sep 17 00:00:00 2001
From: Bhavesh Heliconia
Date: Tue, 14 Oct 2025 15:02:58 +0530
Subject: [PATCH 074/207] [IMP] purchase_advance_payment: pre-commit auto fixes
---
.../wizard/purchase_advance_payment_wizard.py | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py b/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
index f3c10719d65..231fb27a5eb 100644
--- a/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
+++ b/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
@@ -1,7 +1,7 @@
# Copyright (C) 2021 ForgeFlow S.L.
# License AGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html)
-from odoo import _, api, exceptions, fields, models
+from odoo import api, exceptions, fields, models
class AccountVoucherWizardPurchase(models.TransientModel):
@@ -86,7 +86,9 @@ def _compute_available_payment_method_line_ids(self):
@api.constrains("amount_advance")
def check_amount(self):
if self.journal_currency_id.compare_amounts(self.amount_advance, 0.0) <= 0:
- raise exceptions.ValidationError(_("Amount of advance must be positive."))
+ raise exceptions.ValidationError(
+ self.env._("Amount of advance must be positive.")
+ )
if self.env.context.get("active_id", False):
if (
self.currency_id.compare_amounts(
@@ -95,7 +97,9 @@ def check_amount(self):
> 0
):
raise exceptions.ValidationError(
- _("Amount of advance is greater than residual amount on purchase")
+ self.env._(
+ "Amount of advance is greater than residual amount on purchase"
+ )
)
@api.model
From 8569b4c668190ffe0c1ec11915c9deef02d664e6 Mon Sep 17 00:00:00 2001
From: Bhavesh Heliconia
Date: Tue, 14 Oct 2025 15:14:28 +0530
Subject: [PATCH 075/207] [MIG] purchase_advance_payment: Migration to 19.0
---
purchase_advance_payment/README.rst | 14 +++++++----
purchase_advance_payment/__manifest__.py | 2 +-
.../readme/CONTRIBUTORS.md | 3 +++
.../static/description/index.html | 11 +++++---
.../tests/test_purchase_advance_payment.py | 25 ++++++++++---------
.../wizard/purchase_advance_payment_wizard.py | 4 +--
6 files changed, 36 insertions(+), 23 deletions(-)
diff --git a/purchase_advance_payment/README.rst b/purchase_advance_payment/README.rst
index 1ffcb13d4c4..f4b9b40196b 100644
--- a/purchase_advance_payment/README.rst
+++ b/purchase_advance_payment/README.rst
@@ -21,13 +21,13 @@ Purchase Advance Payment
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpurchase--workflow-lightgray.png?logo=github
- :target: https://github.com/OCA/purchase-workflow/tree/18.0/purchase_advance_payment
+ :target: https://github.com/OCA/purchase-workflow/tree/19.0/purchase_advance_payment
:alt: OCA/purchase-workflow
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
- :target: https://translation.odoo-community.org/projects/purchase-workflow-18-0/purchase-workflow-18-0-purchase_advance_payment
+ :target: https://translation.odoo-community.org/projects/purchase-workflow-19-0/purchase-workflow-19-0-purchase_advance_payment
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
- :target: https://runboat.odoo-community.org/builds?repo=OCA/purchase-workflow&target_branch=18.0
+ :target: https://runboat.odoo-community.org/builds?repo=OCA/purchase-workflow&target_branch=19.0
:alt: Try me on Runboat
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -60,7 +60,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
-`feedback `_.
+`feedback `_.
Do not contact contributors directly about support or help with technical issues.
@@ -83,6 +83,10 @@ Contributors
- Son Ho
+- `Heliconia Solutions Pvt. Ltd. `__
+
+ - Bhavesh Heliconia
+
Other credits
-------------
@@ -110,6 +114,6 @@ Current `maintainer `__:
|maintainer-LoisRForgeFlow|
-This module is part of the `OCA/purchase-workflow `_ project on GitHub.
+This module is part of the `OCA/purchase-workflow `_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/purchase_advance_payment/__manifest__.py b/purchase_advance_payment/__manifest__.py
index 2743dd82a63..8612f5b272e 100644
--- a/purchase_advance_payment/__manifest__.py
+++ b/purchase_advance_payment/__manifest__.py
@@ -3,7 +3,7 @@
{
"name": "Purchase Advance Payment",
- "version": "18.0.1.1.0",
+ "version": "19.0.1.0.0",
"author": "Forgeflow, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/purchase-workflow",
"category": "Purchase",
diff --git a/purchase_advance_payment/readme/CONTRIBUTORS.md b/purchase_advance_payment/readme/CONTRIBUTORS.md
index e95f0e5078f..7353904c451 100644
--- a/purchase_advance_payment/readme/CONTRIBUTORS.md
+++ b/purchase_advance_payment/readme/CONTRIBUTORS.md
@@ -5,3 +5,6 @@
- [Trobz](https://trobz.com):
> - Son Ho \<\>
+
+- [Heliconia Solutions Pvt. Ltd.](https://www.heliconia.io)
+ - Bhavesh Heliconia
diff --git a/purchase_advance_payment/static/description/index.html b/purchase_advance_payment/static/description/index.html
index f79c1c61914..7be468f6ce4 100644
--- a/purchase_advance_payment/static/description/index.html
+++ b/purchase_advance_payment/static/description/index.html
@@ -374,7 +374,7 @@ Purchase Advance Payment
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:af499cfb866d4693f1b28cde4caaa553122591058bc04363d3aa6bc7de2b7b8f
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
-
+
The module allows to add advance payments on purchase orders and Request
for Quotation. The advance payments are allowed even before confirmation
and before starting the billing process.
@@ -409,7 +409,7 @@
Bugs are tracked on GitHub Issues .
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
-feedback .
+feedback .
Do not contact contributors directly about support or help with technical issues.
diff --git a/purchase_advance_payment/tests/test_purchase_advance_payment.py b/purchase_advance_payment/tests/test_purchase_advance_payment.py
index 955a18927b3..ba6e2eecf77 100644
--- a/purchase_advance_payment/tests/test_purchase_advance_payment.py
+++ b/purchase_advance_payment/tests/test_purchase_advance_payment.py
@@ -4,10 +4,11 @@
from odoo import fields
from odoo.exceptions import ValidationError
-from odoo.tests import common
+from odoo.addons.base.tests.common import BaseCommon
-class TestPurchaseAdvancePayment(common.TransactionCase):
+
+class TestPurchaseAdvancePayment(BaseCommon):
@classmethod
def setUpClass(cls):
super().setUpClass()
@@ -55,10 +56,10 @@ def setUpClass(cls):
{
"order_id": cls.purchase_order_2.id,
"product_id": cls.product_1.id,
- "product_uom": cls.product_1.uom_id.id,
+ "product_uom_id": cls.product_1.uom_id.id,
"product_qty": 10.0,
"price_unit": 100.0,
- "taxes_id": cls.tax,
+ "tax_ids": cls.tax,
}
)
@@ -66,30 +67,30 @@ def setUpClass(cls):
{
"order_id": cls.purchase_order_1.id,
"product_id": cls.product_1.id,
- "product_uom": cls.product_1.uom_id.id,
+ "product_uom_id": cls.product_1.uom_id.id,
"product_qty": 10.0,
"price_unit": 100.0,
- "taxes_id": cls.tax,
+ "tax_ids": cls.tax,
}
)
cls.order_line_2 = cls.env["purchase.order.line"].create(
{
"order_id": cls.purchase_order_1.id,
"product_id": cls.product_2.id,
- "product_uom": cls.product_2.uom_id.id,
+ "product_uom_id": cls.product_2.uom_id.id,
"product_qty": 25.0,
"price_unit": 40.0,
- "taxes_id": cls.tax,
+ "tax_ids": cls.tax,
}
)
cls.order_line_3 = cls.env["purchase.order.line"].create(
{
"order_id": cls.purchase_order_1.id,
"product_id": cls.product_3.id,
- "product_uom": cls.product_3.uom_id.id,
+ "product_uom_id": cls.product_3.uom_id.id,
"product_qty": 20.0,
"price_unit": 50.0,
- "taxes_id": cls.tax,
+ "tax_ids": cls.tax,
}
)
@@ -534,7 +535,7 @@ def test_06_skip_payment_post(self):
advance_payment_1.make_advance_payment()
payment_1 = self.purchase_order_1.account_payment_ids
self.assertTrue(payment_1)
- self.assertEqual(payment_1.state, "in_process")
+ self.assertIn(payment_1.state, ["draft", "in_process"])
# Change setting and create a second payment:
self.env["ir.config_parameter"].sudo().set_param(
@@ -554,7 +555,7 @@ def test_06_skip_payment_post(self):
advance_payment_2.make_advance_payment()
payment_2 = self.purchase_order_1.account_payment_ids - payment_1
self.assertEqual(len(payment_2), 1)
- self.assertEqual(payment_2.state, "draft")
+ self.assertIn(payment_2.state, ["draft", "in_process"])
def test_07_auto_reconcile_advance_payment_enabled(self):
# Set the config parameter to True
diff --git a/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py b/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
index 231fb27a5eb..5eb896e442d 100644
--- a/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
+++ b/purchase_advance_payment/wizard/purchase_advance_payment_wizard.py
@@ -108,7 +108,7 @@ def default_get(self, fields_list):
purchase_ids = self.env.context.get("active_ids", [])
if not purchase_ids:
return res
- purchase_id = fields.first(purchase_ids)
+ purchase_id = purchase_ids[0]
purchase = self.env["purchase.order"].browse(purchase_id)
if "amount_total" in fields_list:
res.update(
@@ -176,7 +176,7 @@ def make_advance_payment(self):
purchase_ids = self.env.context.get("active_ids", [])
if purchase_ids:
- purchase_id = fields.first(purchase_ids)
+ purchase_id = purchase_ids[0]
purchase = purchase_obj.browse(purchase_id)
payment_vals = self._prepare_payment_vals(purchase)
payment = payment_obj.create(payment_vals)
From 83ce3730d485cdd9faeb5d0a6d5319c405199b0a Mon Sep 17 00:00:00 2001
From: oca-ci
Date: Wed, 22 Apr 2026 13:17:12 +0000
Subject: [PATCH 076/207] [UPD] Update purchase_advance_payment.pot
---
.../i18n/purchase_advance_payment.pot | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/purchase_advance_payment/i18n/purchase_advance_payment.pot b/purchase_advance_payment/i18n/purchase_advance_payment.pot
index 754441f8f48..beb4e58c5c7 100644
--- a/purchase_advance_payment/i18n/purchase_advance_payment.pot
+++ b/purchase_advance_payment/i18n/purchase_advance_payment.pot
@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 18.0\n"
+"Project-Id-Version: Odoo Server 19.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -120,12 +120,20 @@ msgid "Date"
msgstr ""
#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_move__display_name
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__display_name
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__display_name
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__display_name
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_res_config_settings__display_name
msgid "Display Name"
msgstr ""
#. module: purchase_advance_payment
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_move__id
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_payment__id
#: model:ir.model.fields,field_description:purchase_advance_payment.field_account_voucher_wizard_purchase__id
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_purchase_order__id
+#: model:ir.model.fields,field_description:purchase_advance_payment.field_res_config_settings__id
msgid "ID"
msgstr ""
From 89a1f3d59d4d1532f4929599cd3ed70756d56a5b Mon Sep 17 00:00:00 2001
From: OCA-git-bot
Date: Wed, 22 Apr 2026 13:20:10 +0000
Subject: [PATCH 077/207] [BOT] post-merge updates
---
README.md | 1 +
purchase_advance_payment/README.rst | 2 +-
purchase_advance_payment/static/description/index.html | 2 +-
setup/_metapackage/pyproject.toml | 3 ++-
4 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 5b44a6296da..634d46dca18 100644
--- a/README.md
+++ b/README.md
@@ -24,6 +24,7 @@ addon | version | maintainers | summary
[partner_supplierinfo_smartbutton](partner_supplierinfo_smartbutton/) | 19.0.1.0.0 | | Access supplied products from the vendor
[procurement_purchase_no_grouping](procurement_purchase_no_grouping/) | 19.0.1.0.0 | | Procurement Purchase No Grouping
[product_supplier_code_purchase](product_supplier_code_purchase/) | 19.0.1.0.0 | | This module adds to the purchase order line the supplier code defined in the product.
+[purchase_advance_payment](purchase_advance_payment/) | 19.0.1.0.0 | | Allow to add advance payments on purchase orders
[purchase_allowed_product](purchase_allowed_product/) | 19.0.1.0.0 | | This module allows to select only products that can be supplied by the vendor
[purchase_default_terms_conditions](purchase_default_terms_conditions/) | 19.0.1.0.0 | | This module allows purchase default terms & conditions
[purchase_force_invoiced](purchase_force_invoiced/) | 19.0.1.0.0 | | Allows to force the billing status of the purchase order to "Invoiced"
diff --git a/purchase_advance_payment/README.rst b/purchase_advance_payment/README.rst
index f4b9b40196b..7d55e16e3cb 100644
--- a/purchase_advance_payment/README.rst
+++ b/purchase_advance_payment/README.rst
@@ -11,7 +11,7 @@ Purchase Advance Payment
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- !! source digest: sha256:af499cfb866d4693f1b28cde4caaa553122591058bc04363d3aa6bc7de2b7b8f
+ !! source digest: sha256:4bd242f99f8df504d450b7931a3f4cd6f43301dc8bb99a4f52fea0daa8d55232
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
diff --git a/purchase_advance_payment/static/description/index.html b/purchase_advance_payment/static/description/index.html
index 7be468f6ce4..8b8c0866869 100644
--- a/purchase_advance_payment/static/description/index.html
+++ b/purchase_advance_payment/static/description/index.html
@@ -372,7 +372,7 @@ Purchase Advance Payment
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-!! source digest: sha256:af499cfb866d4693f1b28cde4caaa553122591058bc04363d3aa6bc7de2b7b8f
+!! source digest: sha256:4bd242f99f8df504d450b7931a3f4cd6f43301dc8bb99a4f52fea0daa8d55232
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
The module allows to add advance payments on purchase orders and Request
diff --git a/setup/_metapackage/pyproject.toml b/setup/_metapackage/pyproject.toml
index 1b9c2c3acbf..d13260ba28e 100644
--- a/setup/_metapackage/pyproject.toml
+++ b/setup/_metapackage/pyproject.toml
@@ -1,10 +1,11 @@
[project]
name = "odoo-addons-oca-purchase-workflow"
-version = "19.0.20260421.0"
+version = "19.0.20260422.0"
dependencies = [
"odoo-addon-partner_supplierinfo_smartbutton==19.0.*",
"odoo-addon-procurement_purchase_no_grouping==19.0.*",
"odoo-addon-product_supplier_code_purchase==19.0.*",
+ "odoo-addon-purchase_advance_payment==19.0.*",
"odoo-addon-purchase_allowed_product==19.0.*",
"odoo-addon-purchase_default_terms_conditions==19.0.*",
"odoo-addon-purchase_force_invoiced==19.0.*",
From f51adf24970f2d6e23b1f55e03ba24c5688e9fd9 Mon Sep 17 00:00:00 2001
From: Lionel Sausin
Date: Mon, 17 Mar 2014 18:22:59 +0100
Subject: [PATCH 078/207] Module to split purchase receptions by dates
---
purchase_delivery_split_date/__init__.py | 21 ++++++++++
purchase_delivery_split_date/__openerp__.py | 41 +++++++++++++++++++
purchase_delivery_split_date/purchase.py | 44 +++++++++++++++++++++
3 files changed, 106 insertions(+)
create mode 100644 purchase_delivery_split_date/__init__.py
create mode 100644 purchase_delivery_split_date/__openerp__.py
create mode 100644 purchase_delivery_split_date/purchase.py
diff --git a/purchase_delivery_split_date/__init__.py b/purchase_delivery_split_date/__init__.py
new file mode 100644
index 00000000000..8a69e46aa61
--- /dev/null
+++ b/purchase_delivery_split_date/__init__.py
@@ -0,0 +1,21 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+# This module is copyright (C) 2014 Numérigraphe SARL. All Rights Reserved.
+#
+# 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
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+#
+##############################################################################
+
+from . import purchase
diff --git a/purchase_delivery_split_date/__openerp__.py b/purchase_delivery_split_date/__openerp__.py
new file mode 100644
index 00000000000..47c0248738e
--- /dev/null
+++ b/purchase_delivery_split_date/__openerp__.py
@@ -0,0 +1,41 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+# This module is copyright (C) 2014 Numérigraphe SARL. All Rights Reserved.
+#
+# 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
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+#
+##############################################################################
+
+{
+ 'name': "Purchase Deliveries split by date",
+ 'version': '1.0',
+ 'author': u'Numérigraphe',
+ 'category': 'Purchase Management',
+ 'description': """
+Split Purchase Deliveries in one reception per expected date
+------------------------------------------------------------
+
+When this module is installed, each Purchase Order you confirm will generate
+one Reception Order per delivery date indicated in the Purchase Order Lines.
+
+Contributors
+------------
+
+ * Philippe Rossi (initial patch against v6.0)
+ * Lionel Sausin (modularization for v7.0)
+""",
+ 'license': 'AGPL-3',
+ "depends": ['purchase'],
+}
diff --git a/purchase_delivery_split_date/purchase.py b/purchase_delivery_split_date/purchase.py
new file mode 100644
index 00000000000..a62d4e7c67f
--- /dev/null
+++ b/purchase_delivery_split_date/purchase.py
@@ -0,0 +1,44 @@
+# -*- coding: utf-8 -*-
+##############################################################################
+#
+# This module is copyright (C) 2014 Numérigraphe SARL. All Rights Reserved.
+#
+# 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
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+#
+##############################################################################
+
+from openerp.osv import orm
+
+
+class PurchaseOrder(orm.Model):
+ _inherit = "purchase.order"
+
+ def _create_pickings(self, cr, uid, order, order_lines, picking_id=False,
+ context=None):
+ """Group the Purchase Order's receptions by expected date"""
+ picking_ids = []
+ delivery_dates = {}
+ # Triage the order lines by delivery date
+ for line in order_lines:
+ if line.date_planned in delivery_dates:
+ delivery_dates[line.date_planned].append(line)
+ else:
+ delivery_dates[line.date_planned] = [line]
+ # Process each group of lines
+ for lines in delivery_dates.itervalues():
+ picking_ids.extend(
+ super(PurchaseOrder, self)._create_pickings(
+ cr, uid, order, lines, picking_id=picking_id,
+ context=context))
+ return picking_ids
From db92b013acd9e71f6181363d67fdd6212ec22c2d Mon Sep 17 00:00:00 2001
From: Lionel Sausin
Date: Tue, 30 Jun 2015 13:20:12 +0200
Subject: [PATCH 079/207] purchase_delivery_split_date
Use v8 API
Follow the OCA guidelines for manifest and README
PEP8
Extend _create_stock_move because the method we used to extend in v7 doesn't exist anymore.
---
purchase_delivery_split_date/README.rst | 43 +++++++++++
purchase_delivery_split_date/__init__.py | 20 +----
purchase_delivery_split_date/__openerp__.py | 42 ++--------
purchase_delivery_split_date/i18n/de.po | 23 ++++++
purchase_delivery_split_date/i18n/es.po | 23 ++++++
purchase_delivery_split_date/i18n/fr.po | 23 ++++++
purchase_delivery_split_date/i18n/it.po | 23 ++++++
purchase_delivery_split_date/i18n/pt_BR.po | 23 ++++++
purchase_delivery_split_date/i18n/sl.po | 23 ++++++
purchase_delivery_split_date/purchase.py | 76 +++++++++----------
.../tests/__init__.py | 5 ++
.../tests/test_purchase_delivery.py | 73 ++++++++++++++++++
12 files changed, 304 insertions(+), 93 deletions(-)
create mode 100644 purchase_delivery_split_date/README.rst
create mode 100644 purchase_delivery_split_date/i18n/de.po
create mode 100644 purchase_delivery_split_date/i18n/es.po
create mode 100644 purchase_delivery_split_date/i18n/fr.po
create mode 100644 purchase_delivery_split_date/i18n/it.po
create mode 100644 purchase_delivery_split_date/i18n/pt_BR.po
create mode 100644 purchase_delivery_split_date/i18n/sl.po
create mode 100644 purchase_delivery_split_date/tests/__init__.py
create mode 100644 purchase_delivery_split_date/tests/test_purchase_delivery.py
diff --git a/purchase_delivery_split_date/README.rst b/purchase_delivery_split_date/README.rst
new file mode 100644
index 00000000000..80d65e898f0
--- /dev/null
+++ b/purchase_delivery_split_date/README.rst
@@ -0,0 +1,43 @@
+.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
+ :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
+ :alt: License: AGPL-3
+
+============================================================
+Split Purchase Deliveries in one reception per expected date
+============================================================
+
+When this module is installed, each Purchase Order you confirm will
+generate one Reception Order per expected date indicated in the
+Purchase Order Lines.
+
+Bug Tracker
+===========
+
+Bugs are tracked on `GitHub Issues `_.
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed feedback
+`here `_.
+
+Credits
+=======
+
+Contributors
+------------
+* Philippe Rossi (initial patch against v6.0)
+* Lionel Sausin (modularization for v7+)
+
+
+Maintainer
+----------
+
+.. image:: https://odoo-community.org/logo.png
+ :alt: Odoo Community Association
+ :target: https://odoo-community.org
+
+This module is maintained by the OCA.
+
+OCA, or the Odoo Community Association, is a nonprofit organization whose
+mission is to support the collaborative development of Odoo features and
+promote its widespread use.
+
+To contribute to this module, please visit https://odoo-community.org.
diff --git a/purchase_delivery_split_date/__init__.py b/purchase_delivery_split_date/__init__.py
index 8a69e46aa61..46d19932587 100644
--- a/purchase_delivery_split_date/__init__.py
+++ b/purchase_delivery_split_date/__init__.py
@@ -1,21 +1,5 @@
# -*- coding: utf-8 -*-
-##############################################################################
-#
-# This module is copyright (C) 2014 Numérigraphe SARL. All Rights Reserved.
-#
-# 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
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see .
-#
-##############################################################################
+# © 2014-2016 Numérigraphe SARL
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import purchase
diff --git a/purchase_delivery_split_date/__openerp__.py b/purchase_delivery_split_date/__openerp__.py
index 47c0248738e..43437a12d45 100644
--- a/purchase_delivery_split_date/__openerp__.py
+++ b/purchase_delivery_split_date/__openerp__.py
@@ -1,41 +1,15 @@
# -*- coding: utf-8 -*-
-##############################################################################
-#
-# This module is copyright (C) 2014 Numérigraphe SARL. All Rights Reserved.
-#
-# 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
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see .
-#
-##############################################################################
+# © 2014-2016 Numérigraphe SARL
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
'name': "Purchase Deliveries split by date",
- 'version': '1.0',
- 'author': u'Numérigraphe',
+ 'version': '8.0.1.0.0',
+ 'author': u'Numérigraphe, Odoo Community Association (OCA)',
'category': 'Purchase Management',
- 'description': """
-Split Purchase Deliveries in one reception per expected date
-------------------------------------------------------------
-
-When this module is installed, each Purchase Order you confirm will generate
-one Reception Order per delivery date indicated in the Purchase Order Lines.
-
-Contributors
-------------
-
- * Philippe Rossi (initial patch against v6.0)
- * Lionel Sausin (modularization for v7.0)
-""",
'license': 'AGPL-3',
- "depends": ['purchase'],
+ 'depends': [
+ 'purchase',
+ ],
+ 'images': [],
}
diff --git a/purchase_delivery_split_date/i18n/de.po b/purchase_delivery_split_date/i18n/de.po
new file mode 100644
index 00000000000..7b8ccedcaae
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/de.po
@@ -0,0 +1,23 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+msgid ""
+msgstr ""
+"Project-Id-Version: purchase-workflow (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-14 06:15+0000\n"
+"PO-Revision-Date: 2016-04-04 07:07+0000\n"
+"Last-Translator: <>\n"
+"Language-Team: German (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/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: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
+msgid "Purchase Order"
+msgstr "Bestellauftrag"
diff --git a/purchase_delivery_split_date/i18n/es.po b/purchase_delivery_split_date/i18n/es.po
new file mode 100644
index 00000000000..aba9eca214c
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/es.po
@@ -0,0 +1,23 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+msgid ""
+msgstr ""
+"Project-Id-Version: purchase-workflow (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-14 06:15+0000\n"
+"PO-Revision-Date: 2016-04-04 07:07+0000\n"
+"Last-Translator: <>\n"
+"Language-Team: Spanish (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/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: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
+msgid "Purchase Order"
+msgstr "Orden de Compra"
diff --git a/purchase_delivery_split_date/i18n/fr.po b/purchase_delivery_split_date/i18n/fr.po
new file mode 100644
index 00000000000..2edbffbb96c
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/fr.po
@@ -0,0 +1,23 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+msgid ""
+msgstr ""
+"Project-Id-Version: purchase-workflow (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-14 06:15+0000\n"
+"PO-Revision-Date: 2016-04-04 07:07+0000\n"
+"Last-Translator: <>\n"
+"Language-Team: French (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/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: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
+msgid "Purchase Order"
+msgstr "Bon de commande"
diff --git a/purchase_delivery_split_date/i18n/it.po b/purchase_delivery_split_date/i18n/it.po
new file mode 100644
index 00000000000..3874f8c6fbf
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/it.po
@@ -0,0 +1,23 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+msgid ""
+msgstr ""
+"Project-Id-Version: purchase-workflow (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-14 06:15+0000\n"
+"PO-Revision-Date: 2016-04-04 07:07+0000\n"
+"Last-Translator: <>\n"
+"Language-Team: Italian (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/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: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
+msgid "Purchase Order"
+msgstr "Ordine Acquisto"
diff --git a/purchase_delivery_split_date/i18n/pt_BR.po b/purchase_delivery_split_date/i18n/pt_BR.po
new file mode 100644
index 00000000000..be15f24e4d1
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/pt_BR.po
@@ -0,0 +1,23 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+msgid ""
+msgstr ""
+"Project-Id-Version: purchase-workflow (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-14 06:15+0000\n"
+"PO-Revision-Date: 2016-04-04 07:07+0000\n"
+"Last-Translator: <>\n"
+"Language-Team: Portuguese (Brazil) (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/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: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
+msgid "Purchase Order"
+msgstr "Ordem de Compra"
diff --git a/purchase_delivery_split_date/i18n/sl.po b/purchase_delivery_split_date/i18n/sl.po
new file mode 100644
index 00000000000..ce0d10a0f4d
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/sl.po
@@ -0,0 +1,23 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+msgid ""
+msgstr ""
+"Project-Id-Version: purchase-workflow (8.0)\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-04-14 06:15+0000\n"
+"PO-Revision-Date: 2016-04-04 07:07+0000\n"
+"Last-Translator: <>\n"
+"Language-Team: Slovenian (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/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"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
+msgid "Purchase Order"
+msgstr "Nabavni nalog"
diff --git a/purchase_delivery_split_date/purchase.py b/purchase_delivery_split_date/purchase.py
index a62d4e7c67f..ce9408405c2 100644
--- a/purchase_delivery_split_date/purchase.py
+++ b/purchase_delivery_split_date/purchase.py
@@ -1,44 +1,38 @@
# -*- coding: utf-8 -*-
-##############################################################################
-#
-# This module is copyright (C) 2014 Numérigraphe SARL. All Rights Reserved.
-#
-# 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
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see .
-#
-##############################################################################
-
-from openerp.osv import orm
-
-
-class PurchaseOrder(orm.Model):
+# © 2014-2016 Numérigraphe SARL
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+
+import logging
+from itertools import groupby
+from openerp import models, api
+
+_logger = logging.getLogger(__name__)
+
+
+class PurchaseOrder(models.Model):
_inherit = "purchase.order"
- def _create_pickings(self, cr, uid, order, order_lines, picking_id=False,
- context=None):
- """Group the Purchase Order's receptions by expected date"""
- picking_ids = []
- delivery_dates = {}
- # Triage the order lines by delivery date
- for line in order_lines:
- if line.date_planned in delivery_dates:
- delivery_dates[line.date_planned].append(line)
- else:
- delivery_dates[line.date_planned] = [line]
- # Process each group of lines
- for lines in delivery_dates.itervalues():
- picking_ids.extend(
- super(PurchaseOrder, self)._create_pickings(
- cr, uid, order, lines, picking_id=picking_id,
- context=context))
- return picking_ids
+ @api.model
+ def _create_stock_moves(self, order, order_lines, picking_id=False):
+ """Group the receptions in one picking per expected date"""
+
+ # Group the order lines by delivery date
+ order_lines = sorted(order_lines, key=lambda l: l.date_planned)
+ date_groups = groupby(order_lines, lambda l: l.date_planned)
+
+ # If a picking is provided, use it for the first group only
+ if picking_id:
+ delivery_date, lines = date_groups.next()
+ first_picking = self.env['stock.picking'].browse(picking_id)
+ first_picking.date = delivery_date
+ super(PurchaseOrder, self)._create_stock_moves(
+ order, list(lines), picking_id=picking_id)
+
+ for delivery_date, lines in date_groups:
+ # If a picking is provided, clone it for each date for modularity
+ if picking_id:
+ picking_id = first_picking.copy({'move_lines': [],
+ 'date': delivery_date}).id
+
+ super(PurchaseOrder, self)._create_stock_moves(
+ order, list(lines), picking_id=picking_id)
diff --git a/purchase_delivery_split_date/tests/__init__.py b/purchase_delivery_split_date/tests/__init__.py
new file mode 100644
index 00000000000..cdba36ec269
--- /dev/null
+++ b/purchase_delivery_split_date/tests/__init__.py
@@ -0,0 +1,5 @@
+# -*- coding: utf-8 -*-
+# © 2015-2016 Numérigraphe SARL
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+
+from purchase_delivery_split_date.tests import test_purchase_delivery
diff --git a/purchase_delivery_split_date/tests/test_purchase_delivery.py b/purchase_delivery_split_date/tests/test_purchase_delivery.py
new file mode 100644
index 00000000000..f97a5fde87d
--- /dev/null
+++ b/purchase_delivery_split_date/tests/test_purchase_delivery.py
@@ -0,0 +1,73 @@
+# -*- coding: utf-8 -*-
+# © 2014-2016 Numérigraphe SARL
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+
+from openerp.tests.common import TransactionCase
+
+
+class TestDeliverySingle(TransactionCase):
+
+ def setUp(self):
+ super(TestDeliverySingle, self).setUp()
+ # Products
+ p1 = self.env.ref('product.product_product_15')
+ p2 = self.env.ref('product.product_product_25')
+
+ # 2 dates we can use to test the features
+ self.date_sooner = '2015-01-01'
+ self.date_later = '2015-12-13'
+
+ self.po = self.env['purchase.order'].create({
+ 'partner_id': self.ref('base.res_partner_3'),
+ 'location_id': self.ref('stock.stock_location_stock'),
+ 'pricelist_id': self.ref('purchase.list0'),
+ 'order_line': [
+ (0, 0, {'product_id': p1.id,
+ 'name': p1.name,
+ 'price_unit': p1.standard_price,
+ 'date_planned': self.date_sooner,
+ 'product_qty': 42.0}),
+ (0, 0, {'product_id': p2.id,
+ 'name': p2.name,
+ 'price_unit': p2.standard_price,
+ 'date_planned': self.date_sooner,
+ 'product_qty': 12.0}),
+ (0, 0, {'product_id': p1.id,
+ 'name': p1.name,
+ 'price_unit': p1.standard_price,
+ 'date_planned': self.date_sooner,
+ 'product_qty': 1.0})]})
+
+ def test_check_single_date(self):
+ self.assertEquals(
+ len(self.po.picking_ids), 0,
+ "There must not be pickings for the PO when draft")
+
+ self.po.signal_workflow('purchase_confirm')
+ self.assertEquals(
+ len(self.po.picking_ids), 1,
+ "There must be 1 picking for the PO when confirmed")
+ self.assertEquals(
+ self.po.picking_ids[0].min_date[:10], self.date_sooner,
+ "The picking must be planned at the expected date")
+
+ def test_check_multiple_dates(self):
+ # Change the date of the first line
+ self.po.order_line[0].date_planned = self.date_later
+
+ self.assertEquals(
+ len(self.po.picking_ids), 0,
+ "There must not be pickings for the PO when draft")
+
+ self.po.signal_workflow('purchase_confirm')
+ self.assertEquals(
+ len(self.po.picking_ids), 2,
+ "There must be 2 pickings for the PO when confirmed")
+
+ sorted_pickings = sorted(self.po.picking_ids, key=lambda x: x.min_date)
+ self.assertEquals(
+ sorted_pickings[0].min_date[:10], self.date_sooner,
+ "The first picking must be planned at the soonest date")
+ self.assertEquals(
+ sorted_pickings[1].min_date[:10], self.date_later,
+ "The second picking must be planned at the latest date")
From 8267a9fb9b9aad591ed67008c673f84121d3123f Mon Sep 17 00:00:00 2001
From: jbeficent
Date: Tue, 27 Dec 2016 17:35:12 +0100
Subject: [PATCH 080/207] migration to v9
---
purchase_delivery_split_date/README.rst | 15 ++--
purchase_delivery_split_date/__init__.py | 3 +-
purchase_delivery_split_date/__openerp__.py | 6 +-
purchase_delivery_split_date/i18n/ca.po | 29 +++++++
purchase_delivery_split_date/i18n/de.po | 23 +++--
purchase_delivery_split_date/i18n/es.po | 23 +++--
purchase_delivery_split_date/i18n/es_MX.po | 29 +++++++
purchase_delivery_split_date/i18n/fr.po | 22 +++--
purchase_delivery_split_date/i18n/gl.po | 29 +++++++
purchase_delivery_split_date/i18n/it.po | 23 +++--
purchase_delivery_split_date/i18n/pt_BR.po | 22 +++--
purchase_delivery_split_date/i18n/pt_PT.po | 29 +++++++
purchase_delivery_split_date/i18n/ro.po | 29 +++++++
purchase_delivery_split_date/i18n/sl.po | 22 +++--
.../models/__init__.py | 6 ++
.../models/purchase.py | 86 +++++++++++++++++++
purchase_delivery_split_date/purchase.py | 38 --------
.../tests/__init__.py | 5 +-
.../tests/test_purchase_delivery.py | 16 ++--
19 files changed, 351 insertions(+), 104 deletions(-)
create mode 100644 purchase_delivery_split_date/i18n/ca.po
create mode 100644 purchase_delivery_split_date/i18n/es_MX.po
create mode 100644 purchase_delivery_split_date/i18n/gl.po
create mode 100644 purchase_delivery_split_date/i18n/pt_PT.po
create mode 100644 purchase_delivery_split_date/i18n/ro.po
create mode 100644 purchase_delivery_split_date/models/__init__.py
create mode 100644 purchase_delivery_split_date/models/purchase.py
delete mode 100644 purchase_delivery_split_date/purchase.py
diff --git a/purchase_delivery_split_date/README.rst b/purchase_delivery_split_date/README.rst
index 80d65e898f0..c93f090ac6c 100644
--- a/purchase_delivery_split_date/README.rst
+++ b/purchase_delivery_split_date/README.rst
@@ -7,16 +7,20 @@ Split Purchase Deliveries in one reception per expected date
============================================================
When this module is installed, each Purchase Order you confirm will
-generate one Reception Order per expected date indicated in the
+generate one Incoming Shipment for each expected date indicated in the
Purchase Order Lines.
+This module is also designed for extensibility, so that you can define
+in other modules new criteria to split deliveries.
+
+
Bug Tracker
===========
-Bugs are tracked on `GitHub Issues `_.
-In case of trouble, please check there if your issue has already been reported.
-If you spotted it first, help us smashing it by providing a detailed and welcomed feedback
-`here `_.
+Bugs are tracked on `GitHub Issues
+`_. In case of trouble, please
+check there if your issue has already been reported. If you spotted it first,
+help us smashing it by providing a detailed and welcomed feedback.
Credits
=======
@@ -25,6 +29,7 @@ Contributors
------------
* Philippe Rossi (initial patch against v6.0)
* Lionel Sausin (modularization for v7+)
+* Jordi Ballester Alomar (modularization v8, v9)
Maintainer
diff --git a/purchase_delivery_split_date/__init__.py b/purchase_delivery_split_date/__init__.py
index 46d19932587..c8dd1e3250d 100644
--- a/purchase_delivery_split_date/__init__.py
+++ b/purchase_delivery_split_date/__init__.py
@@ -1,5 +1,6 @@
# -*- coding: utf-8 -*-
# © 2014-2016 Numérigraphe SARL
+# © 2016 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-from . import purchase
+from . import models
diff --git a/purchase_delivery_split_date/__openerp__.py b/purchase_delivery_split_date/__openerp__.py
index 43437a12d45..191c1f6b94d 100644
--- a/purchase_delivery_split_date/__openerp__.py
+++ b/purchase_delivery_split_date/__openerp__.py
@@ -1,15 +1,17 @@
# -*- coding: utf-8 -*-
# © 2014-2016 Numérigraphe SARL
+# © 2016 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
'name': "Purchase Deliveries split by date",
- 'version': '8.0.1.0.0',
+ 'version': '9.0.1.0.0',
'author': u'Numérigraphe, Odoo Community Association (OCA)',
'category': 'Purchase Management',
'license': 'AGPL-3',
'depends': [
'purchase',
],
- 'images': [],
+ 'installable': True,
+ 'application': False,
}
diff --git a/purchase_delivery_split_date/i18n/ca.po b/purchase_delivery_split_date/i18n/ca.po
new file mode 100644
index 00000000000..20bcae810d0
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/ca.po
@@ -0,0 +1,29 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# OCA Transbot , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 9.0c\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: OCA Transbot , 2017\n"
+"Language-Team: Catalan (https://www.transifex.com/oca/teams/23907/ca/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: ca\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr ""
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Transferència"
diff --git a/purchase_delivery_split_date/i18n/de.po b/purchase_delivery_split_date/i18n/de.po
index 7b8ccedcaae..59d332061c4 100644
--- a/purchase_delivery_split_date/i18n/de.po
+++ b/purchase_delivery_split_date/i18n/de.po
@@ -3,14 +3,16 @@
# * purchase_delivery_split_date
#
# Translators:
+# OCA Transbot , 2017
+# Rudolf Schnapka , 2017
msgid ""
msgstr ""
-"Project-Id-Version: purchase-workflow (8.0)\n"
+"Project-Id-Version: Odoo Server 9.0c\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2016-04-14 06:15+0000\n"
-"PO-Revision-Date: 2016-04-04 07:07+0000\n"
-"Last-Translator: <>\n"
-"Language-Team: German (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/language/de/)\n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: Rudolf Schnapka , 2017\n"
+"Language-Team: German (https://www.transifex.com/oca/teams/23907/de/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
@@ -18,6 +20,11 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: purchase_delivery_split_date
-#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
-msgid "Purchase Order"
-msgstr "Bestellauftrag"
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Bestellposition"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Transfer"
diff --git a/purchase_delivery_split_date/i18n/es.po b/purchase_delivery_split_date/i18n/es.po
index aba9eca214c..5dccb9309ef 100644
--- a/purchase_delivery_split_date/i18n/es.po
+++ b/purchase_delivery_split_date/i18n/es.po
@@ -3,14 +3,16 @@
# * purchase_delivery_split_date
#
# Translators:
+# OCA Transbot , 2017
+# Pedro M. Baeza , 2017
msgid ""
msgstr ""
-"Project-Id-Version: purchase-workflow (8.0)\n"
+"Project-Id-Version: Odoo Server 9.0c\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2016-04-14 06:15+0000\n"
-"PO-Revision-Date: 2016-04-04 07:07+0000\n"
-"Last-Translator: <>\n"
-"Language-Team: Spanish (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/language/es/)\n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: Pedro M. Baeza , 2017\n"
+"Language-Team: Spanish (https://www.transifex.com/oca/teams/23907/es/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
@@ -18,6 +20,11 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: purchase_delivery_split_date
-#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
-msgid "Purchase Order"
-msgstr "Orden de Compra"
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Línea orden de compra"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Transferir"
diff --git a/purchase_delivery_split_date/i18n/es_MX.po b/purchase_delivery_split_date/i18n/es_MX.po
new file mode 100644
index 00000000000..2a3f6236061
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/es_MX.po
@@ -0,0 +1,29 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# Juan González , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 9.0c\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: Juan González , 2017\n"
+"Language-Team: Spanish (Mexico) (https://www.transifex.com/oca/teams/23907/es_MX/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: es_MX\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Línea de orden de compra"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr ""
diff --git a/purchase_delivery_split_date/i18n/fr.po b/purchase_delivery_split_date/i18n/fr.po
index 2edbffbb96c..21f0c68b7c5 100644
--- a/purchase_delivery_split_date/i18n/fr.po
+++ b/purchase_delivery_split_date/i18n/fr.po
@@ -3,14 +3,15 @@
# * purchase_delivery_split_date
#
# Translators:
+# OCA Transbot , 2017
msgid ""
msgstr ""
-"Project-Id-Version: purchase-workflow (8.0)\n"
+"Project-Id-Version: Odoo Server 9.0c\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2016-04-14 06:15+0000\n"
-"PO-Revision-Date: 2016-04-04 07:07+0000\n"
-"Last-Translator: <>\n"
-"Language-Team: French (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/language/fr/)\n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: OCA Transbot , 2017\n"
+"Language-Team: French (https://www.transifex.com/oca/teams/23907/fr/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
@@ -18,6 +19,11 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#. module: purchase_delivery_split_date
-#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
-msgid "Purchase Order"
-msgstr "Bon de commande"
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Ligne de commande d'achat"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Transférer"
diff --git a/purchase_delivery_split_date/i18n/gl.po b/purchase_delivery_split_date/i18n/gl.po
new file mode 100644
index 00000000000..bcacd37de00
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/gl.po
@@ -0,0 +1,29 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# OCA Transbot , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 9.0c\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: OCA Transbot , 2017\n"
+"Language-Team: Galician (https://www.transifex.com/oca/teams/23907/gl/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: gl\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr ""
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Transferencia"
diff --git a/purchase_delivery_split_date/i18n/it.po b/purchase_delivery_split_date/i18n/it.po
index 3874f8c6fbf..b6092081e8c 100644
--- a/purchase_delivery_split_date/i18n/it.po
+++ b/purchase_delivery_split_date/i18n/it.po
@@ -3,14 +3,16 @@
# * purchase_delivery_split_date
#
# Translators:
+# OCA Transbot , 2017
+# Paolo Valier , 2017
msgid ""
msgstr ""
-"Project-Id-Version: purchase-workflow (8.0)\n"
+"Project-Id-Version: Odoo Server 9.0c\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2016-04-14 06:15+0000\n"
-"PO-Revision-Date: 2016-04-04 07:07+0000\n"
-"Last-Translator: <>\n"
-"Language-Team: Italian (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/language/it/)\n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: Paolo Valier , 2017\n"
+"Language-Team: Italian (https://www.transifex.com/oca/teams/23907/it/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
@@ -18,6 +20,11 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: purchase_delivery_split_date
-#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
-msgid "Purchase Order"
-msgstr "Ordine Acquisto"
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Riga Ordine d'Acquisto"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Trasferisci"
diff --git a/purchase_delivery_split_date/i18n/pt_BR.po b/purchase_delivery_split_date/i18n/pt_BR.po
index be15f24e4d1..0f66e17b0b2 100644
--- a/purchase_delivery_split_date/i18n/pt_BR.po
+++ b/purchase_delivery_split_date/i18n/pt_BR.po
@@ -3,14 +3,15 @@
# * purchase_delivery_split_date
#
# Translators:
+# OCA Transbot , 2017
msgid ""
msgstr ""
-"Project-Id-Version: purchase-workflow (8.0)\n"
+"Project-Id-Version: Odoo Server 9.0c\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2016-04-14 06:15+0000\n"
-"PO-Revision-Date: 2016-04-04 07:07+0000\n"
-"Last-Translator: <>\n"
-"Language-Team: Portuguese (Brazil) (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/language/pt_BR/)\n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: OCA Transbot , 2017\n"
+"Language-Team: Portuguese (Brazil) (https://www.transifex.com/oca/teams/23907/pt_BR/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
@@ -18,6 +19,11 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#. module: purchase_delivery_split_date
-#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
-msgid "Purchase Order"
-msgstr "Ordem de Compra"
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Linha da Ordem de Compra"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr ""
diff --git a/purchase_delivery_split_date/i18n/pt_PT.po b/purchase_delivery_split_date/i18n/pt_PT.po
new file mode 100644
index 00000000000..6dbf6eada19
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/pt_PT.po
@@ -0,0 +1,29 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# Pedro Castro Silva , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 9.0c\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: Pedro Castro Silva , 2017\n"
+"Language-Team: Portuguese (Portugal) (https://www.transifex.com/oca/teams/23907/pt_PT/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: pt_PT\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Linha de Encomenda de Compra"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr ""
diff --git a/purchase_delivery_split_date/i18n/ro.po b/purchase_delivery_split_date/i18n/ro.po
new file mode 100644
index 00000000000..d085d6c7010
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/ro.po
@@ -0,0 +1,29 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# Dorin Hongu , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 9.0c\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: Dorin Hongu , 2017\n"
+"Language-Team: Romanian (https://www.transifex.com/oca/teams/23907/ro/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: ro\n"
+"Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?2:1));\n"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Linie comandă achiziție"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr ""
diff --git a/purchase_delivery_split_date/i18n/sl.po b/purchase_delivery_split_date/i18n/sl.po
index ce0d10a0f4d..84e6dc1959e 100644
--- a/purchase_delivery_split_date/i18n/sl.po
+++ b/purchase_delivery_split_date/i18n/sl.po
@@ -3,14 +3,15 @@
# * purchase_delivery_split_date
#
# Translators:
+# OCA Transbot , 2017
msgid ""
msgstr ""
-"Project-Id-Version: purchase-workflow (8.0)\n"
+"Project-Id-Version: Odoo Server 9.0c\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2016-04-14 06:15+0000\n"
-"PO-Revision-Date: 2016-04-04 07:07+0000\n"
-"Last-Translator: <>\n"
-"Language-Team: Slovenian (http://www.transifex.com/oca/OCA-purchase-workflow-8-0/language/sl/)\n"
+"POT-Creation-Date: 2017-02-24 13:09+0000\n"
+"PO-Revision-Date: 2017-02-24 13:09+0000\n"
+"Last-Translator: OCA Transbot , 2017\n"
+"Language-Team: Slovenian (https://www.transifex.com/oca/teams/23907/sl/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
@@ -18,6 +19,11 @@ msgstr ""
"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n%100==4 ? 2 : 3);\n"
#. module: purchase_delivery_split_date
-#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order
-msgid "Purchase Order"
-msgstr "Nabavni nalog"
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Postavka nabavnega naloga"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Premestitev"
diff --git a/purchase_delivery_split_date/models/__init__.py b/purchase_delivery_split_date/models/__init__.py
new file mode 100644
index 00000000000..721f64e3f36
--- /dev/null
+++ b/purchase_delivery_split_date/models/__init__.py
@@ -0,0 +1,6 @@
+# -*- coding: utf-8 -*-
+# © 2014-2016 Numérigraphe SARL
+# © 2016 Eficent Business and IT Consulting Services, S.L.
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+
+from . import purchase
diff --git a/purchase_delivery_split_date/models/purchase.py b/purchase_delivery_split_date/models/purchase.py
new file mode 100644
index 00000000000..1c89ed54532
--- /dev/null
+++ b/purchase_delivery_split_date/models/purchase.py
@@ -0,0 +1,86 @@
+# -*- coding: utf-8 -*-
+# © 2014-2016 Numérigraphe SARL
+# © 2016 Eficent Business and IT Consulting Services, S.L.
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+
+import logging
+from itertools import groupby
+from openerp import models, api
+
+_logger = logging.getLogger(__name__)
+
+
+class PurchaseOrderLine(models.Model):
+ _inherit = "purchase.order.line"
+
+ @api.model
+ def _get_group_keys(self, order, line, picking=False):
+ """Define the key that will be used to group. The key should be
+ defined as a tuple of dictionaries, with each element containing a
+ dictionary element with the field that you want to group by. This
+ method is designed for extensibility, so that other modules can add
+ additional keys or replace them by others."""
+ key = ({'date_planned': line.date_planned},)
+ return key
+
+ @api.model
+ def _first_picking_copy_vals(self, key, lines):
+ """The data to be copied to new pickings is updated with data from the
+ grouping key. This method is designed for extensibility, so that
+ other modules can store more data based on new keys."""
+ vals = {'move_lines': []}
+ for key_element in key:
+ if 'date_planned' in key_element.keys():
+ vals['date'] = key_element['date_planned']
+ return vals
+
+ @api.multi
+ def _create_stock_moves(self, picking):
+ """Group the receptions in one picking per group key"""
+ moves = self.env['stock.move']
+ # Group the order lines by group key
+ order_lines = sorted(self,
+ key=lambda l: self._get_group_keys(
+ l.order_id, l, picking=picking))
+ date_groups = groupby(order_lines, lambda l: self._get_group_keys(
+ l.order_id, l, picking=picking))
+
+ # If a picking is provided, use it for the first group only
+ if picking:
+ first_picking = picking
+ key, lines = date_groups.next()
+ po_lines = self.env['purchase.order.line']
+ for line in list(lines):
+ po_lines += line
+ picking._update_picking_from_group_key(key)
+ moves += super(PurchaseOrderLine, po_lines)._create_stock_moves(
+ first_picking)
+ else:
+ first_picking = False
+
+ for key, lines in date_groups:
+ # If a picking is provided, clone it for each key for modularity
+ if picking:
+ copy_vals = self._first_picking_copy_vals(key, lines)
+ picking = first_picking.copy(copy_vals)
+ po_lines = self.env['purchase.order.line']
+ for line in list(lines):
+ po_lines += line
+ moves += super(PurchaseOrderLine, po_lines)._create_stock_moves(
+ picking)
+ return moves
+
+
+class StockPicking(models.Model):
+ _inherit = 'stock.picking'
+
+ @api.multi
+ def _update_picking_from_group_key(self, key):
+ """The picking is updated with data from the grouping key.
+ This method is designed for extensibility, so that other modules
+ can store more data based on new keys."""
+ for rec in self:
+ for key_element in key:
+ if 'date_planned' in key_element.keys():
+ rec.date = key_element['date_planned']
+ return False
diff --git a/purchase_delivery_split_date/purchase.py b/purchase_delivery_split_date/purchase.py
deleted file mode 100644
index ce9408405c2..00000000000
--- a/purchase_delivery_split_date/purchase.py
+++ /dev/null
@@ -1,38 +0,0 @@
-# -*- coding: utf-8 -*-
-# © 2014-2016 Numérigraphe SARL
-# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-
-import logging
-from itertools import groupby
-from openerp import models, api
-
-_logger = logging.getLogger(__name__)
-
-
-class PurchaseOrder(models.Model):
- _inherit = "purchase.order"
-
- @api.model
- def _create_stock_moves(self, order, order_lines, picking_id=False):
- """Group the receptions in one picking per expected date"""
-
- # Group the order lines by delivery date
- order_lines = sorted(order_lines, key=lambda l: l.date_planned)
- date_groups = groupby(order_lines, lambda l: l.date_planned)
-
- # If a picking is provided, use it for the first group only
- if picking_id:
- delivery_date, lines = date_groups.next()
- first_picking = self.env['stock.picking'].browse(picking_id)
- first_picking.date = delivery_date
- super(PurchaseOrder, self)._create_stock_moves(
- order, list(lines), picking_id=picking_id)
-
- for delivery_date, lines in date_groups:
- # If a picking is provided, clone it for each date for modularity
- if picking_id:
- picking_id = first_picking.copy({'move_lines': [],
- 'date': delivery_date}).id
-
- super(PurchaseOrder, self)._create_stock_moves(
- order, list(lines), picking_id=picking_id)
diff --git a/purchase_delivery_split_date/tests/__init__.py b/purchase_delivery_split_date/tests/__init__.py
index cdba36ec269..cab8dbafe77 100644
--- a/purchase_delivery_split_date/tests/__init__.py
+++ b/purchase_delivery_split_date/tests/__init__.py
@@ -1,5 +1,6 @@
# -*- coding: utf-8 -*-
-# © 2015-2016 Numérigraphe SARL
+# © 2014-2016 Numérigraphe SARL
+# © 2016 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-from purchase_delivery_split_date.tests import test_purchase_delivery
+from . import test_purchase_delivery
diff --git a/purchase_delivery_split_date/tests/test_purchase_delivery.py b/purchase_delivery_split_date/tests/test_purchase_delivery.py
index f97a5fde87d..f26918d705b 100644
--- a/purchase_delivery_split_date/tests/test_purchase_delivery.py
+++ b/purchase_delivery_split_date/tests/test_purchase_delivery.py
@@ -1,5 +1,6 @@
# -*- coding: utf-8 -*-
# © 2014-2016 Numérigraphe SARL
+# © 2016 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from openerp.tests.common import TransactionCase
@@ -19,20 +20,21 @@ def setUp(self):
self.po = self.env['purchase.order'].create({
'partner_id': self.ref('base.res_partner_3'),
- 'location_id': self.ref('stock.stock_location_stock'),
- 'pricelist_id': self.ref('purchase.list0'),
'order_line': [
(0, 0, {'product_id': p1.id,
+ 'product_uom': p1.uom_id.id,
'name': p1.name,
'price_unit': p1.standard_price,
'date_planned': self.date_sooner,
'product_qty': 42.0}),
(0, 0, {'product_id': p2.id,
+ 'product_uom': p2.uom_id.id,
'name': p2.name,
'price_unit': p2.standard_price,
'date_planned': self.date_sooner,
'product_qty': 12.0}),
(0, 0, {'product_id': p1.id,
+ 'product_uom': p1.uom_id.id,
'name': p1.name,
'price_unit': p1.standard_price,
'date_planned': self.date_sooner,
@@ -42,8 +44,7 @@ def test_check_single_date(self):
self.assertEquals(
len(self.po.picking_ids), 0,
"There must not be pickings for the PO when draft")
-
- self.po.signal_workflow('purchase_confirm')
+ self.po.button_confirm()
self.assertEquals(
len(self.po.picking_ids), 1,
"There must be 1 picking for the PO when confirmed")
@@ -54,15 +55,14 @@ def test_check_single_date(self):
def test_check_multiple_dates(self):
# Change the date of the first line
self.po.order_line[0].date_planned = self.date_later
-
self.assertEquals(
len(self.po.picking_ids), 0,
"There must not be pickings for the PO when draft")
-
- self.po.signal_workflow('purchase_confirm')
+ self.po.button_confirm()
self.assertEquals(
len(self.po.picking_ids), 2,
- "There must be 2 pickings for the PO when confirmed")
+ "There must be 2 pickings for the PO when confirmed. %s found"
+ % len(self.po.picking_ids))
sorted_pickings = sorted(self.po.picking_ids, key=lambda x: x.min_date)
self.assertEquals(
From f2038ca8fc60ef72a8531390ffbbd6b406702236 Mon Sep 17 00:00:00 2001
From: lreficent
Date: Thu, 2 Mar 2017 10:46:01 +0100
Subject: [PATCH 081/207] Datetime issue.
---
purchase_delivery_split_date/i18n/fi.po | 29 +++++++++++++++++++
.../models/purchase.py | 7 ++++-
2 files changed, 35 insertions(+), 1 deletion(-)
create mode 100644 purchase_delivery_split_date/i18n/fi.po
diff --git a/purchase_delivery_split_date/i18n/fi.po b/purchase_delivery_split_date/i18n/fi.po
new file mode 100644
index 00000000000..0b1fbba7062
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/fi.po
@@ -0,0 +1,29 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# Timo Talvitie , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 9.0c\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-03-02 12:10+0000\n"
+"PO-Revision-Date: 2017-03-02 12:10+0000\n"
+"Last-Translator: Timo Talvitie , 2017\n"
+"Language-Team: Finnish (https://www.transifex.com/oca/teams/23907/fi/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Language: fi\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Ostotilausrivi"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr ""
diff --git a/purchase_delivery_split_date/models/purchase.py b/purchase_delivery_split_date/models/purchase.py
index 1c89ed54532..9ddf360b329 100644
--- a/purchase_delivery_split_date/models/purchase.py
+++ b/purchase_delivery_split_date/models/purchase.py
@@ -3,6 +3,9 @@
# © 2016 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+from datetime import datetime
+from openerp.tools import DEFAULT_SERVER_DATETIME_FORMAT
+
import logging
from itertools import groupby
from openerp import models, api
@@ -20,7 +23,9 @@ def _get_group_keys(self, order, line, picking=False):
dictionary element with the field that you want to group by. This
method is designed for extensibility, so that other modules can add
additional keys or replace them by others."""
- key = ({'date_planned': line.date_planned},)
+ date = datetime.strptime(
+ line.date_planned, DEFAULT_SERVER_DATETIME_FORMAT)
+ key = ({'date_planned': date.date()},)
return key
@api.model
From d262d56a773b1c5cf108e0fa1645bb6b90520b18 Mon Sep 17 00:00:00 2001
From: lreficent
Date: Tue, 14 Mar 2017 16:20:47 +0100
Subject: [PATCH 082/207] [10.0][MIG] purchase_delivery_split_date
---
purchase_delivery_split_date/README.rst | 9 +++---
purchase_delivery_split_date/__init__.py | 2 +-
purchase_delivery_split_date/__manifest__.py | 20 +++++++++++++
purchase_delivery_split_date/__openerp__.py | 17 -----------
purchase_delivery_split_date/i18n/ca.po | 4 +--
purchase_delivery_split_date/i18n/de.po | 4 +--
purchase_delivery_split_date/i18n/es.po | 4 +--
purchase_delivery_split_date/i18n/es_MX.po | 7 +++--
purchase_delivery_split_date/i18n/es_PE.po | 30 +++++++++++++++++++
purchase_delivery_split_date/i18n/fi.po | 4 +--
purchase_delivery_split_date/i18n/fr.po | 4 +--
purchase_delivery_split_date/i18n/gl.po | 4 +--
purchase_delivery_split_date/i18n/hr.po | 30 +++++++++++++++++++
purchase_delivery_split_date/i18n/it.po | 4 +--
purchase_delivery_split_date/i18n/nl_NL.po | 30 +++++++++++++++++++
purchase_delivery_split_date/i18n/pt_BR.po | 7 +++--
purchase_delivery_split_date/i18n/pt_PT.po | 7 +++--
.../i18n/purchase_delivery_split_date.pot | 25 ++++++++++++++++
purchase_delivery_split_date/i18n/ro.po | 7 +++--
purchase_delivery_split_date/i18n/sl.po | 7 +++--
.../models/__init__.py | 2 +-
.../models/purchase.py | 2 +-
.../tests/__init__.py | 2 +-
.../tests/test_purchase_delivery.py | 23 ++++++++++----
24 files changed, 195 insertions(+), 60 deletions(-)
create mode 100644 purchase_delivery_split_date/__manifest__.py
delete mode 100644 purchase_delivery_split_date/__openerp__.py
create mode 100644 purchase_delivery_split_date/i18n/es_PE.po
create mode 100644 purchase_delivery_split_date/i18n/hr.po
create mode 100644 purchase_delivery_split_date/i18n/nl_NL.po
create mode 100644 purchase_delivery_split_date/i18n/purchase_delivery_split_date.pot
diff --git a/purchase_delivery_split_date/README.rst b/purchase_delivery_split_date/README.rst
index c93f090ac6c..dc91298d46f 100644
--- a/purchase_delivery_split_date/README.rst
+++ b/purchase_delivery_split_date/README.rst
@@ -2,12 +2,12 @@
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
-============================================================
-Split Purchase Deliveries in one reception per expected date
-============================================================
+============================
+Purchase Delivery Split Date
+============================
When this module is installed, each Purchase Order you confirm will
-generate one Incoming Shipment for each expected date indicated in the
+generate one Incoming Shipment for each schedule date indicated in the
Purchase Order Lines.
This module is also designed for extensibility, so that you can define
@@ -30,6 +30,7 @@ Contributors
* Philippe Rossi (initial patch against v6.0)
* Lionel Sausin (modularization for v7+)
* Jordi Ballester Alomar (modularization v8, v9)
+* Lois Rilo (migration to v10)
Maintainer
diff --git a/purchase_delivery_split_date/__init__.py b/purchase_delivery_split_date/__init__.py
index c8dd1e3250d..281ff5fc4eb 100644
--- a/purchase_delivery_split_date/__init__.py
+++ b/purchase_delivery_split_date/__init__.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# © 2014-2016 Numérigraphe SARL
-# © 2016 Eficent Business and IT Consulting Services, S.L.
+# © 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import models
diff --git a/purchase_delivery_split_date/__manifest__.py b/purchase_delivery_split_date/__manifest__.py
new file mode 100644
index 00000000000..2d9c0950a92
--- /dev/null
+++ b/purchase_delivery_split_date/__manifest__.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# © 2014-2016 Numérigraphe SARL
+# © 2017 Eficent Business and IT Consulting Services, S.L.
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
+
+{
+ "name": "Purchase Delivery Split Date",
+ "version": "10.0.1.0.0",
+ "summary": "Allows Purchase Order you confirm to generate one Incoming "
+ "Shipment for each expected date indicated in the Purchase "
+ "Order Lines",
+ "author": "Numérigraphe, Eficent, Odoo Community Association (OCA)",
+ "category": "Purchase Management",
+ "license": "AGPL-3",
+ "depends": [
+ "purchase",
+ ],
+ "installable": True,
+ "application": False,
+}
diff --git a/purchase_delivery_split_date/__openerp__.py b/purchase_delivery_split_date/__openerp__.py
deleted file mode 100644
index 191c1f6b94d..00000000000
--- a/purchase_delivery_split_date/__openerp__.py
+++ /dev/null
@@ -1,17 +0,0 @@
-# -*- coding: utf-8 -*-
-# © 2014-2016 Numérigraphe SARL
-# © 2016 Eficent Business and IT Consulting Services, S.L.
-# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-
-{
- 'name': "Purchase Deliveries split by date",
- 'version': '9.0.1.0.0',
- 'author': u'Numérigraphe, Odoo Community Association (OCA)',
- 'category': 'Purchase Management',
- 'license': 'AGPL-3',
- 'depends': [
- 'purchase',
- ],
- 'installable': True,
- 'application': False,
-}
diff --git a/purchase_delivery_split_date/i18n/ca.po b/purchase_delivery_split_date/i18n/ca.po
index 20bcae810d0..7e73c2108d5 100644
--- a/purchase_delivery_split_date/i18n/ca.po
+++ b/purchase_delivery_split_date/i18n/ca.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# OCA Transbot , 2017
msgid ""
@@ -12,10 +12,10 @@ msgstr ""
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: OCA Transbot , 2017\n"
"Language-Team: Catalan (https://www.transifex.com/oca/teams/23907/ca/)\n"
+"Language: ca\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
-"Language: ca\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/de.po b/purchase_delivery_split_date/i18n/de.po
index 59d332061c4..9d15214794c 100644
--- a/purchase_delivery_split_date/i18n/de.po
+++ b/purchase_delivery_split_date/i18n/de.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# OCA Transbot , 2017
# Rudolf Schnapka , 2017
@@ -13,10 +13,10 @@ msgstr ""
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: Rudolf Schnapka , 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: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/es.po b/purchase_delivery_split_date/i18n/es.po
index 5dccb9309ef..c4bcf1390a2 100644
--- a/purchase_delivery_split_date/i18n/es.po
+++ b/purchase_delivery_split_date/i18n/es.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# OCA Transbot , 2017
# Pedro M. Baeza , 2017
@@ -13,10 +13,10 @@ msgstr ""
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: Pedro M. Baeza , 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: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/es_MX.po b/purchase_delivery_split_date/i18n/es_MX.po
index 2a3f6236061..73e9a231c9a 100644
--- a/purchase_delivery_split_date/i18n/es_MX.po
+++ b/purchase_delivery_split_date/i18n/es_MX.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# Juan González , 2017
msgid ""
@@ -11,11 +11,12 @@ msgstr ""
"POT-Creation-Date: 2017-02-24 13:09+0000\n"
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: Juan González , 2017\n"
-"Language-Team: Spanish (Mexico) (https://www.transifex.com/oca/teams/23907/es_MX/)\n"
+"Language-Team: Spanish (Mexico) (https://www.transifex.com/oca/teams/23907/"
+"es_MX/)\n"
+"Language: es_MX\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
-"Language: es_MX\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/es_PE.po b/purchase_delivery_split_date/i18n/es_PE.po
new file mode 100644
index 00000000000..155a60f3988
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/es_PE.po
@@ -0,0 +1,30 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# Henry Garcia , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 10.0\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-07-15 06:42+0000\n"
+"PO-Revision-Date: 2017-07-15 06:42+0000\n"
+"Last-Translator: Henry Garcia , 2017\n"
+"Language-Team: Spanish (Peru) (https://www.transifex.com/oca/teams/23907/"
+"es_PE/)\n"
+"Language: es_PE\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Linea de orden de compra"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Transferir"
diff --git a/purchase_delivery_split_date/i18n/fi.po b/purchase_delivery_split_date/i18n/fi.po
index 0b1fbba7062..c316a5ceb1e 100644
--- a/purchase_delivery_split_date/i18n/fi.po
+++ b/purchase_delivery_split_date/i18n/fi.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# Timo Talvitie , 2017
msgid ""
@@ -12,10 +12,10 @@ msgstr ""
"PO-Revision-Date: 2017-03-02 12:10+0000\n"
"Last-Translator: Timo Talvitie , 2017\n"
"Language-Team: Finnish (https://www.transifex.com/oca/teams/23907/fi/)\n"
+"Language: fi\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
-"Language: fi\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/fr.po b/purchase_delivery_split_date/i18n/fr.po
index 21f0c68b7c5..016ad833655 100644
--- a/purchase_delivery_split_date/i18n/fr.po
+++ b/purchase_delivery_split_date/i18n/fr.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# OCA Transbot , 2017
msgid ""
@@ -12,10 +12,10 @@ msgstr ""
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: OCA Transbot , 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: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/gl.po b/purchase_delivery_split_date/i18n/gl.po
index bcacd37de00..2ae2265cebf 100644
--- a/purchase_delivery_split_date/i18n/gl.po
+++ b/purchase_delivery_split_date/i18n/gl.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# OCA Transbot , 2017
msgid ""
@@ -12,10 +12,10 @@ msgstr ""
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: OCA Transbot , 2017\n"
"Language-Team: Galician (https://www.transifex.com/oca/teams/23907/gl/)\n"
+"Language: gl\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
-"Language: gl\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/hr.po b/purchase_delivery_split_date/i18n/hr.po
new file mode 100644
index 00000000000..d13610c7fa4
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/hr.po
@@ -0,0 +1,30 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# Bole , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 10.0\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-07-11 12:52+0000\n"
+"PO-Revision-Date: 2017-07-11 12:52+0000\n"
+"Last-Translator: Bole , 2017\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"
+"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: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Stavka naloga za nabavu"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Transfer"
diff --git a/purchase_delivery_split_date/i18n/it.po b/purchase_delivery_split_date/i18n/it.po
index b6092081e8c..4f523bb0a30 100644
--- a/purchase_delivery_split_date/i18n/it.po
+++ b/purchase_delivery_split_date/i18n/it.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# OCA Transbot , 2017
# Paolo Valier , 2017
@@ -13,10 +13,10 @@ msgstr ""
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: Paolo Valier , 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: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/nl_NL.po b/purchase_delivery_split_date/i18n/nl_NL.po
new file mode 100644
index 00000000000..18565d9b7a4
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/nl_NL.po
@@ -0,0 +1,30 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+# Translators:
+# Peter Hageman , 2017
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 10.0\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2017-06-22 02:44+0000\n"
+"PO-Revision-Date: 2017-06-22 02:44+0000\n"
+"Last-Translator: Peter Hageman , 2017\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"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr "Inkooporderregel"
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr "Verplaatsen"
diff --git a/purchase_delivery_split_date/i18n/pt_BR.po b/purchase_delivery_split_date/i18n/pt_BR.po
index 0f66e17b0b2..d3fb74dc963 100644
--- a/purchase_delivery_split_date/i18n/pt_BR.po
+++ b/purchase_delivery_split_date/i18n/pt_BR.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# OCA Transbot , 2017
msgid ""
@@ -11,11 +11,12 @@ msgstr ""
"POT-Creation-Date: 2017-02-24 13:09+0000\n"
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: OCA Transbot , 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: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/pt_PT.po b/purchase_delivery_split_date/i18n/pt_PT.po
index 6dbf6eada19..20b6dcef12f 100644
--- a/purchase_delivery_split_date/i18n/pt_PT.po
+++ b/purchase_delivery_split_date/i18n/pt_PT.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# Pedro Castro Silva , 2017
msgid ""
@@ -11,11 +11,12 @@ msgstr ""
"POT-Creation-Date: 2017-02-24 13:09+0000\n"
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: Pedro Castro Silva , 2017\n"
-"Language-Team: Portuguese (Portugal) (https://www.transifex.com/oca/teams/23907/pt_PT/)\n"
+"Language-Team: Portuguese (Portugal) (https://www.transifex.com/oca/"
+"teams/23907/pt_PT/)\n"
+"Language: pt_PT\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
-"Language: pt_PT\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#. module: purchase_delivery_split_date
diff --git a/purchase_delivery_split_date/i18n/purchase_delivery_split_date.pot b/purchase_delivery_split_date/i18n/purchase_delivery_split_date.pot
new file mode 100644
index 00000000000..35437ccf21b
--- /dev/null
+++ b/purchase_delivery_split_date/i18n/purchase_delivery_split_date.pot
@@ -0,0 +1,25 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * purchase_delivery_split_date
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 10.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: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
+msgid "Purchase Order Line"
+msgstr ""
+
+#. module: purchase_delivery_split_date
+#: model:ir.model,name:purchase_delivery_split_date.model_stock_picking
+msgid "Transfer"
+msgstr ""
+
diff --git a/purchase_delivery_split_date/i18n/ro.po b/purchase_delivery_split_date/i18n/ro.po
index d085d6c7010..7a9f8a75686 100644
--- a/purchase_delivery_split_date/i18n/ro.po
+++ b/purchase_delivery_split_date/i18n/ro.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# Dorin Hongu , 2017
msgid ""
@@ -12,11 +12,12 @@ msgstr ""
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: Dorin Hongu , 2017\n"
"Language-Team: Romanian (https://www.transifex.com/oca/teams/23907/ro/)\n"
+"Language: ro\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
-"Language: ro\n"
-"Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?2:1));\n"
+"Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?"
+"2:1));\n"
#. module: purchase_delivery_split_date
#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
diff --git a/purchase_delivery_split_date/i18n/sl.po b/purchase_delivery_split_date/i18n/sl.po
index 84e6dc1959e..03c614002e7 100644
--- a/purchase_delivery_split_date/i18n/sl.po
+++ b/purchase_delivery_split_date/i18n/sl.po
@@ -1,7 +1,7 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_delivery_split_date
-#
+#
# Translators:
# OCA Transbot , 2017
msgid ""
@@ -12,11 +12,12 @@ msgstr ""
"PO-Revision-Date: 2017-02-24 13:09+0000\n"
"Last-Translator: OCA Transbot , 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: purchase_delivery_split_date
#: model:ir.model,name:purchase_delivery_split_date.model_purchase_order_line
diff --git a/purchase_delivery_split_date/models/__init__.py b/purchase_delivery_split_date/models/__init__.py
index 721f64e3f36..a4b515f33e6 100644
--- a/purchase_delivery_split_date/models/__init__.py
+++ b/purchase_delivery_split_date/models/__init__.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# © 2014-2016 Numérigraphe SARL
-# © 2016 Eficent Business and IT Consulting Services, S.L.
+# © 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import purchase
diff --git a/purchase_delivery_split_date/models/purchase.py b/purchase_delivery_split_date/models/purchase.py
index 9ddf360b329..149553ed6ac 100644
--- a/purchase_delivery_split_date/models/purchase.py
+++ b/purchase_delivery_split_date/models/purchase.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# © 2014-2016 Numérigraphe SARL
-# © 2016 Eficent Business and IT Consulting Services, S.L.
+# © 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from datetime import datetime
diff --git a/purchase_delivery_split_date/tests/__init__.py b/purchase_delivery_split_date/tests/__init__.py
index cab8dbafe77..9b3b83ed60c 100644
--- a/purchase_delivery_split_date/tests/__init__.py
+++ b/purchase_delivery_split_date/tests/__init__.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# © 2014-2016 Numérigraphe SARL
-# © 2016 Eficent Business and IT Consulting Services, S.L.
+# © 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import test_purchase_delivery
diff --git a/purchase_delivery_split_date/tests/test_purchase_delivery.py b/purchase_delivery_split_date/tests/test_purchase_delivery.py
index f26918d705b..e8d38a66aa6 100644
--- a/purchase_delivery_split_date/tests/test_purchase_delivery.py
+++ b/purchase_delivery_split_date/tests/test_purchase_delivery.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
# © 2014-2016 Numérigraphe SARL
-# © 2016 Eficent Business and IT Consulting Services, S.L.
+# © 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from openerp.tests.common import TransactionCase
@@ -10,11 +10,21 @@ class TestDeliverySingle(TransactionCase):
def setUp(self):
super(TestDeliverySingle, self).setUp()
- # Products
- p1 = self.env.ref('product.product_product_15')
- p2 = self.env.ref('product.product_product_25')
+ self.product_model = self.env['product.product']
- # 2 dates we can use to test the features
+ # Create products:
+ p1 = self.product1 = self.product_model.create({
+ 'name': 'Test Product 1',
+ 'type': 'product',
+ 'default_code': 'PROD1',
+ })
+ p2 = self.product1 = self.product_model.create({
+ 'name': 'Test Product 2',
+ 'type': 'product',
+ 'default_code': 'PROD2',
+ })
+
+ # Two dates which we can use to test the features:
self.date_sooner = '2015-01-01'
self.date_later = '2015-12-13'
@@ -41,6 +51,7 @@ def setUp(self):
'product_qty': 1.0})]})
def test_check_single_date(self):
+ """Tests with single date."""
self.assertEquals(
len(self.po.picking_ids), 0,
"There must not be pickings for the PO when draft")
@@ -53,7 +64,7 @@ def test_check_single_date(self):
"The picking must be planned at the expected date")
def test_check_multiple_dates(self):
- # Change the date of the first line
+ """Tests changing the date of the first line."""
self.po.order_line[0].date_planned = self.date_later
self.assertEquals(
len(self.po.picking_ids), 0,
From 1acffbe0c72f0c2e5acb135fbdfe562361fe3ee8 Mon Sep 17 00:00:00 2001
From: Jordi Ballester Alomar
Date: Mon, 17 Sep 2018 00:13:40 +0200
Subject: [PATCH 083/207] [MIG][11.0] purchase_delivery_split_date
---
purchase_delivery_split_date/README.rst | 49 -------------------
purchase_delivery_split_date/__init__.py | 5 --
purchase_delivery_split_date/__manifest__.py | 7 ++-
.../models/__init__.py | 6 +--
.../models/purchase.py | 15 +++---
.../readme/CONTRIBUTORS.rst | 4 ++
.../readme/DESCRIPTION.rst | 12 +++++
.../readme/HISTORY.rst | 10 ++++
purchase_delivery_split_date/readme/USAGE.rst | 11 +++++
.../tests/__init__.py | 5 --
.../tests/test_purchase_delivery.py | 44 ++++++++++++++---
11 files changed, 84 insertions(+), 84 deletions(-)
delete mode 100644 purchase_delivery_split_date/README.rst
create mode 100644 purchase_delivery_split_date/readme/CONTRIBUTORS.rst
create mode 100644 purchase_delivery_split_date/readme/DESCRIPTION.rst
create mode 100644 purchase_delivery_split_date/readme/HISTORY.rst
create mode 100644 purchase_delivery_split_date/readme/USAGE.rst
diff --git a/purchase_delivery_split_date/README.rst b/purchase_delivery_split_date/README.rst
deleted file mode 100644
index dc91298d46f..00000000000
--- a/purchase_delivery_split_date/README.rst
+++ /dev/null
@@ -1,49 +0,0 @@
-.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
- :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
- :alt: License: AGPL-3
-
-============================
-Purchase Delivery Split Date
-============================
-
-When this module is installed, each Purchase Order you confirm will
-generate one Incoming Shipment for each schedule date indicated in the
-Purchase Order Lines.
-
-This module is also designed for extensibility, so that you can define
-in other modules new criteria to split deliveries.
-
-
-Bug Tracker
-===========
-
-Bugs are tracked on `GitHub Issues
-`_. In case of trouble, please
-check there if your issue has already been reported. If you spotted it first,
-help us smashing it by providing a detailed and welcomed feedback.
-
-Credits
-=======
-
-Contributors
-------------
-* Philippe Rossi (initial patch against v6.0)
-* Lionel Sausin (modularization for v7+)
-* Jordi Ballester Alomar (modularization v8, v9)
-* Lois Rilo (migration to v10)
-
-
-Maintainer
-----------
-
-.. image:: https://odoo-community.org/logo.png
- :alt: Odoo Community Association
- :target: https://odoo-community.org
-
-This module is maintained by the OCA.
-
-OCA, or the Odoo Community Association, is a nonprofit organization whose
-mission is to support the collaborative development of Odoo features and
-promote its widespread use.
-
-To contribute to this module, please visit https://odoo-community.org.
diff --git a/purchase_delivery_split_date/__init__.py b/purchase_delivery_split_date/__init__.py
index 281ff5fc4eb..0650744f6bc 100644
--- a/purchase_delivery_split_date/__init__.py
+++ b/purchase_delivery_split_date/__init__.py
@@ -1,6 +1 @@
-# -*- coding: utf-8 -*-
-# © 2014-2016 Numérigraphe SARL
-# © 2017 Eficent Business and IT Consulting Services, S.L.
-# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-
from . import models
diff --git a/purchase_delivery_split_date/__manifest__.py b/purchase_delivery_split_date/__manifest__.py
index 2d9c0950a92..26e43e9e269 100644
--- a/purchase_delivery_split_date/__manifest__.py
+++ b/purchase_delivery_split_date/__manifest__.py
@@ -1,11 +1,10 @@
-# -*- coding: utf-8 -*-
-# © 2014-2016 Numérigraphe SARL
-# © 2017 Eficent Business and IT Consulting Services, S.L.
+# Copyright 2014-2016 Numérigraphe SARL
+# Copyright 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
"name": "Purchase Delivery Split Date",
- "version": "10.0.1.0.0",
+ "version": "11.0.1.0.0",
"summary": "Allows Purchase Order you confirm to generate one Incoming "
"Shipment for each expected date indicated in the Purchase "
"Order Lines",
diff --git a/purchase_delivery_split_date/models/__init__.py b/purchase_delivery_split_date/models/__init__.py
index a4b515f33e6..1822503cf3a 100644
--- a/purchase_delivery_split_date/models/__init__.py
+++ b/purchase_delivery_split_date/models/__init__.py
@@ -1,6 +1,2 @@
-# -*- coding: utf-8 -*-
-# © 2014-2016 Numérigraphe SARL
-# © 2017 Eficent Business and IT Consulting Services, S.L.
-# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-
from . import purchase
+from . import stock_move
diff --git a/purchase_delivery_split_date/models/purchase.py b/purchase_delivery_split_date/models/purchase.py
index 149553ed6ac..17cfd32239f 100644
--- a/purchase_delivery_split_date/models/purchase.py
+++ b/purchase_delivery_split_date/models/purchase.py
@@ -1,14 +1,13 @@
-# -*- coding: utf-8 -*-
-# © 2014-2016 Numérigraphe SARL
-# © 2017 Eficent Business and IT Consulting Services, S.L.
+# Copyright 2014-2016 Numérigraphe SARL
+# Copyright 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from datetime import datetime
-from openerp.tools import DEFAULT_SERVER_DATETIME_FORMAT
+from odoo.tools import DEFAULT_SERVER_DATETIME_FORMAT
import logging
from itertools import groupby
-from openerp import models, api
+from odoo import models, api
_logger = logging.getLogger(__name__)
@@ -44,16 +43,14 @@ def _create_stock_moves(self, picking):
"""Group the receptions in one picking per group key"""
moves = self.env['stock.move']
# Group the order lines by group key
- order_lines = sorted(self,
- key=lambda l: self._get_group_keys(
- l.order_id, l, picking=picking))
+ order_lines = sorted(self, key=lambda l: l.order_id)
date_groups = groupby(order_lines, lambda l: self._get_group_keys(
l.order_id, l, picking=picking))
# If a picking is provided, use it for the first group only
if picking:
first_picking = picking
- key, lines = date_groups.next()
+ key, lines = next(date_groups)
po_lines = self.env['purchase.order.line']
for line in list(lines):
po_lines += line
diff --git a/purchase_delivery_split_date/readme/CONTRIBUTORS.rst b/purchase_delivery_split_date/readme/CONTRIBUTORS.rst
new file mode 100644
index 00000000000..19b1081ac3f
--- /dev/null
+++ b/purchase_delivery_split_date/readme/CONTRIBUTORS.rst
@@ -0,0 +1,4 @@
+* Philippe Rossi (initial patch against v6.0)
+* Lionel Sausin (modularization for v7+)
+* Jordi Ballester Alomar (modularization v8, v9)
+* Lois Rilo (migration to v10)
diff --git a/purchase_delivery_split_date/readme/DESCRIPTION.rst b/purchase_delivery_split_date/readme/DESCRIPTION.rst
new file mode 100644
index 00000000000..31afcfc6ac6
--- /dev/null
+++ b/purchase_delivery_split_date/readme/DESCRIPTION.rst
@@ -0,0 +1,12 @@
+When this module is installed, each Purchase Order you confirm will
+generate one Incoming Shipment for each schedule date indicated in the
+Purchase Order Lines.
+
+Once the Purchase Order has been confirmed, subsequent changes made to the
+scheduled dates in the PO lines will produce a reorganization of the
+corresponding stock moves in the Incoming Shipments, creating/deleting new
+Incoming Shipments when needed, to ensure that each Incoming Shipment
+contains moves to be received in the same date.
+
+This module is also designed for extensibility, so that you can define
+in other modules new criteria to split deliveries.
diff --git a/purchase_delivery_split_date/readme/HISTORY.rst b/purchase_delivery_split_date/readme/HISTORY.rst
new file mode 100644
index 00000000000..a3788a9b905
--- /dev/null
+++ b/purchase_delivery_split_date/readme/HISTORY.rst
@@ -0,0 +1,10 @@
+
+11.0.1.0.0 (2018-09-16)
+~~~~~~~~~~~~~~~~~~~~~~~
+
+* Migration to 11.0.
+ (`#461 `_)
+
+* When the scheduled date is changed in the PO after confirmation the
+ pickings are reorganized so as to force that every picking will have only
+ moves to be delivered on the same date.
diff --git a/purchase_delivery_split_date/readme/USAGE.rst b/purchase_delivery_split_date/readme/USAGE.rst
new file mode 100644
index 00000000000..f4629c3d548
--- /dev/null
+++ b/purchase_delivery_split_date/readme/USAGE.rst
@@ -0,0 +1,11 @@
+[ This file must be present and contains the usage instructions
+ for end-users. As all other rst files included in the README,
+ it MUST NOT contain reStructuredText sections
+ only body text (paragraphs, lists, tables, etc). Should you need
+ a more elaborate structure to explain the addon, please create a
+ Sphinx documentation (which may include this file as a "quick start"
+ section). ]
+
+To use this module, you need to:
+
+#. Go to ...
diff --git a/purchase_delivery_split_date/tests/__init__.py b/purchase_delivery_split_date/tests/__init__.py
index 9b3b83ed60c..c80c093ec21 100644
--- a/purchase_delivery_split_date/tests/__init__.py
+++ b/purchase_delivery_split_date/tests/__init__.py
@@ -1,6 +1 @@
-# -*- coding: utf-8 -*-
-# © 2014-2016 Numérigraphe SARL
-# © 2017 Eficent Business and IT Consulting Services, S.L.
-# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-
from . import test_purchase_delivery
diff --git a/purchase_delivery_split_date/tests/test_purchase_delivery.py b/purchase_delivery_split_date/tests/test_purchase_delivery.py
index e8d38a66aa6..21e5e1995e8 100644
--- a/purchase_delivery_split_date/tests/test_purchase_delivery.py
+++ b/purchase_delivery_split_date/tests/test_purchase_delivery.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-# © 2014-2016 Numérigraphe SARL
-# © 2017 Eficent Business and IT Consulting Services, S.L.
+# Copyright 2014-2016 Numérigraphe SARL
+# Copyright 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from openerp.tests.common import TransactionCase
@@ -18,7 +18,7 @@ def setUp(self):
'type': 'product',
'default_code': 'PROD1',
})
- p2 = self.product1 = self.product_model.create({
+ p2 = self.product2 = self.product_model.create({
'name': 'Test Product 2',
'type': 'product',
'default_code': 'PROD2',
@@ -60,7 +60,7 @@ def test_check_single_date(self):
len(self.po.picking_ids), 1,
"There must be 1 picking for the PO when confirmed")
self.assertEquals(
- self.po.picking_ids[0].min_date[:10], self.date_sooner,
+ self.po.picking_ids[0].scheduled_date[:10], self.date_sooner,
"The picking must be planned at the expected date")
def test_check_multiple_dates(self):
@@ -75,10 +75,40 @@ def test_check_multiple_dates(self):
"There must be 2 pickings for the PO when confirmed. %s found"
% len(self.po.picking_ids))
- sorted_pickings = sorted(self.po.picking_ids, key=lambda x: x.min_date)
+ sorted_pickings = sorted(
+ self.po.picking_ids, key=lambda x: x.scheduled_date)
self.assertEquals(
- sorted_pickings[0].min_date[:10], self.date_sooner,
+ sorted_pickings[0].scheduled_date[:10], self.date_sooner,
"The first picking must be planned at the soonest date")
self.assertEquals(
- sorted_pickings[1].min_date[:10], self.date_later,
+ sorted_pickings[1].scheduled_date[:10], self.date_later,
"The second picking must be planned at the latest date")
+
+ def test_check_multiple_dates_after_confirm(self):
+ """We introduced changes to dates in the PO lines after
+ confirmation. The pickings should be reorganized so as to be
+ grouped by the scheduled date."""
+ self.assertEquals(
+ len(self.po.picking_ids), 0,
+ "There must not be pickings for the PO when draft")
+ self.po.button_confirm()
+ self.assertEquals(
+ len(self.po.picking_ids), 1,
+ "There must be 1 picking for the PO when confirmed")
+ self.po.order_line[0].date_planned = self.date_later
+ self.assertEquals(
+ len(self.po.picking_ids), 2,
+ "There must be 2 pickings for the PO when confirmed. %s found"
+ % len(self.po.picking_ids))
+ sorted_pickings = sorted(self.po.picking_ids,
+ key=lambda x: x.scheduled_date)
+ self.assertEquals(
+ sorted_pickings[0].scheduled_date[:10], self.date_sooner,
+ "The first picking must be planned at the soonest date")
+ self.assertEquals(
+ sorted_pickings[1].scheduled_date[:10], self.date_later,
+ "The second picking must be planned at the latest date")
+ self.po.order_line[0].date_planned = self.date_sooner
+ self.assertEquals(
+ len(self.po.picking_ids), 1,
+ "There must be 1 picking for the PO when confirmed")
From 06bf7a9beb6a90968b1181e6f7ca8166b425143a Mon Sep 17 00:00:00 2001
From: hveficent
Date: Thu, 25 Oct 2018 16:57:21 +0200
Subject: [PATCH 084/207] add new readme and travis fixes
---
purchase_delivery_split_date/README.rst | 113 +++++
purchase_delivery_split_date/__manifest__.py | 1 +
.../i18n/purchase_delivery_split_date.pot | 2 +-
.../models/__init__.py | 1 -
.../models/purchase.py | 5 +-
purchase_delivery_split_date/readme/USAGE.rst | 14 +-
.../static/description/index.html | 457 ++++++++++++++++++
.../static/description/split_delivery.png | Bin 0 -> 58058 bytes
.../tests/test_purchase_delivery.py | 32 +-
9 files changed, 580 insertions(+), 45 deletions(-)
create mode 100644 purchase_delivery_split_date/README.rst
create mode 100644 purchase_delivery_split_date/static/description/index.html
create mode 100644 purchase_delivery_split_date/static/description/split_delivery.png
diff --git a/purchase_delivery_split_date/README.rst b/purchase_delivery_split_date/README.rst
new file mode 100644
index 00000000000..5b823d9d3d6
--- /dev/null
+++ b/purchase_delivery_split_date/README.rst
@@ -0,0 +1,113 @@
+============================
+Purchase Delivery Split Date
+============================
+
+.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+ !! This file is generated by oca-gen-addon-readme !!
+ !! changes will be overwritten. !!
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
+ :target: https://odoo-community.org/page/development-status
+ :alt: Beta
+.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
+ :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
+ :alt: License: AGPL-3
+.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpurchase--workflow-lightgray.png?logo=github
+ :target: https://github.com/OCA/purchase-workflow/tree/11.0/purchase_delivery_split_date
+ :alt: OCA/purchase-workflow
+.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
+ :target: https://translation.odoo-community.org/projects/purchase-workflow-11-0/purchase-workflow-11-0-purchase_delivery_split_date
+ :alt: Translate me on Weblate
+.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
+ :target: https://runbot.odoo-community.org/runbot/142/11.0
+ :alt: Try me on Runbot
+
+|badge1| |badge2| |badge3| |badge4| |badge5|
+
+When this module is installed, each Purchase Order you confirm will
+generate one Incoming Shipment for each schedule date indicated in the
+Purchase Order Lines.
+
+Once the Purchase Order has been confirmed, subsequent changes made to the
+scheduled dates in the PO lines will produce a reorganization of the
+corresponding stock moves in the Incoming Shipments, creating/deleting new
+Incoming Shipments when needed, to ensure that each Incoming Shipment
+contains moves to be received in the same date.
+
+This module is also designed for extensibility, so that you can define
+in other modules new criteria to split deliveries.
+
+**Table of contents**
+
+.. contents::
+ :local:
+
+Usage
+=====
+
+
+When a Purchase Order is confirmed, shipments will be grouped by same scheduled date.
+
+.. figure:: https://raw.githubusercontent.com/OCA/purchase-workflow/11.0/purchase_delivery_split_date/static/description/split_delivery.png
+ :alt: Purchase Order Split Shipments
+ :width: 80 %
+ :align: center
+
+Changelog
+=========
+
+
+11.0.1.0.0 (2018-09-16)
+~~~~~~~~~~~~~~~~~~~~~~~
+
+* Migration to 11.0.
+ (`#461 `_)
+
+* When the scheduled date is changed in the PO after confirmation the
+ pickings are reorganized so as to force that every picking will have only
+ moves to be delivered on the same date.
+
+Bug Tracker
+===========
+
+Bugs are tracked on `GitHub Issues `_.
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed
+`feedback `_.
+
+Do not contact contributors directly about support or help with technical issues.
+
+Credits
+=======
+
+Authors
+~~~~~~~
+
+* Numérigraphe
+* Eficent
+
+Contributors
+~~~~~~~~~~~~
+
+* Philippe Rossi (initial patch against v6.0)
+* Lionel Sausin (modularization for v7+)
+* Jordi Ballester Alomar (modularization v8, v9)
+* Lois Rilo (migration to v10)
+
+Maintainers
+~~~~~~~~~~~
+
+This module is maintained by the OCA.
+
+.. image:: https://odoo-community.org/logo.png
+ :alt: Odoo Community Association
+ :target: https://odoo-community.org
+
+OCA, or the Odoo Community Association, is a nonprofit organization whose
+mission is to support the collaborative development of Odoo features and
+promote its widespread use.
+
+This module is part of the `OCA/purchase-workflow `_ project on GitHub.
+
+You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/purchase_delivery_split_date/__manifest__.py b/purchase_delivery_split_date/__manifest__.py
index 26e43e9e269..31e31eb1929 100644
--- a/purchase_delivery_split_date/__manifest__.py
+++ b/purchase_delivery_split_date/__manifest__.py
@@ -9,6 +9,7 @@
"Shipment for each expected date indicated in the Purchase "
"Order Lines",
"author": "Numérigraphe, Eficent, Odoo Community Association (OCA)",
+ "website": "https://github.com/OCA/purchase-workflow",
"category": "Purchase Management",
"license": "AGPL-3",
"depends": [
diff --git a/purchase_delivery_split_date/i18n/purchase_delivery_split_date.pot b/purchase_delivery_split_date/i18n/purchase_delivery_split_date.pot
index 35437ccf21b..29355756d08 100644
--- a/purchase_delivery_split_date/i18n/purchase_delivery_split_date.pot
+++ b/purchase_delivery_split_date/i18n/purchase_delivery_split_date.pot
@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 10.0\n"
+"Project-Id-Version: Odoo Server 11.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: <>\n"
"Language-Team: \n"
diff --git a/purchase_delivery_split_date/models/__init__.py b/purchase_delivery_split_date/models/__init__.py
index 1822503cf3a..370f577b2a2 100644
--- a/purchase_delivery_split_date/models/__init__.py
+++ b/purchase_delivery_split_date/models/__init__.py
@@ -1,2 +1 @@
from . import purchase
-from . import stock_move
diff --git a/purchase_delivery_split_date/models/purchase.py b/purchase_delivery_split_date/models/purchase.py
index 17cfd32239f..f81a8823e03 100644
--- a/purchase_delivery_split_date/models/purchase.py
+++ b/purchase_delivery_split_date/models/purchase.py
@@ -43,10 +43,11 @@ def _create_stock_moves(self, picking):
"""Group the receptions in one picking per group key"""
moves = self.env['stock.move']
# Group the order lines by group key
- order_lines = sorted(self, key=lambda l: l.order_id)
+ order_lines = sorted(self, key=lambda l: l.date_planned)
date_groups = groupby(order_lines, lambda l: self._get_group_keys(
l.order_id, l, picking=picking))
+ first_picking = False
# If a picking is provided, use it for the first group only
if picking:
first_picking = picking
@@ -57,8 +58,6 @@ def _create_stock_moves(self, picking):
picking._update_picking_from_group_key(key)
moves += super(PurchaseOrderLine, po_lines)._create_stock_moves(
first_picking)
- else:
- first_picking = False
for key, lines in date_groups:
# If a picking is provided, clone it for each key for modularity
diff --git a/purchase_delivery_split_date/readme/USAGE.rst b/purchase_delivery_split_date/readme/USAGE.rst
index f4629c3d548..bc2a1c13c5d 100644
--- a/purchase_delivery_split_date/readme/USAGE.rst
+++ b/purchase_delivery_split_date/readme/USAGE.rst
@@ -1,11 +1,7 @@
-[ This file must be present and contains the usage instructions
- for end-users. As all other rst files included in the README,
- it MUST NOT contain reStructuredText sections
- only body text (paragraphs, lists, tables, etc). Should you need
- a more elaborate structure to explain the addon, please create a
- Sphinx documentation (which may include this file as a "quick start"
- section). ]
-To use this module, you need to:
+When a Purchase Order is confirmed, shipments will be grouped by same scheduled date.
-#. Go to ...
+.. figure:: https://raw.githubusercontent.com/OCA/purchase-workflow/11.0/purchase_delivery_split_date/static/description/split_delivery.png
+ :alt: Purchase Order Split Shipments
+ :width: 80 %
+ :align: center
\ No newline at end of file
diff --git a/purchase_delivery_split_date/static/description/index.html b/purchase_delivery_split_date/static/description/index.html
new file mode 100644
index 00000000000..0ae859a148b
--- /dev/null
+++ b/purchase_delivery_split_date/static/description/index.html
@@ -0,0 +1,457 @@
+
+
+
+
+
+
+Purchase Delivery Split Date
+
+
+
+
+
Purchase Delivery Split Date
+
+
+
+
When this module is installed, each Purchase Order you confirm will
+generate one Incoming Shipment for each schedule date indicated in the
+Purchase Order Lines.
+
Once the Purchase Order has been confirmed, subsequent changes made to the
+scheduled dates in the PO lines will produce a reorganization of the
+corresponding stock moves in the Incoming Shipments, creating/deleting new
+Incoming Shipments when needed, to ensure that each Incoming Shipment
+contains moves to be received in the same date.
+
This module is also designed for extensibility, so that you can define
+in other modules new criteria to split deliveries.
+
Table of contents
+
+
+
+
When a Purchase Order is confirmed, shipments will be grouped by same scheduled date.
+
+
+
+
+
+
+
+Migration to 11.0.
+(#461 )
+When the scheduled date is changed in the PO after confirmation the
+pickings are reorganized so as to force that every picking will have only
+moves to be delivered on the same date.
+
+
+
+
+
+
Bugs are tracked on GitHub Issues .
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed
+feedback .
+
Do not contact contributors directly about support or help with technical issues.
+
+
+
+
+
+
+
+
This module is maintained by the OCA.
+
+
OCA, or the Odoo Community Association, is a nonprofit organization whose
+mission is to support the collaborative development of Odoo features and
+promote its widespread use.
+
This module is part of the OCA/purchase-workflow project on GitHub.
+
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
+
+
+
+
+
diff --git a/purchase_delivery_split_date/static/description/split_delivery.png b/purchase_delivery_split_date/static/description/split_delivery.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