-
-
Notifications
You must be signed in to change notification settings - Fork 790
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by gurneyalex
- Loading branch information
Showing
19 changed files
with
815 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
===================================== | ||
Default purchase incoterm per partner | ||
===================================== | ||
|
||
.. | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! This file is generated by oca-gen-addon-readme !! | ||
!! changes will be overwritten. !! | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! source digest: sha256:1679d1ffb6e608db2dac3887451673e17077113039e4bb701b2159d3bf55b06c | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
.. |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/16.0/purchase_partner_incoterm | ||
: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-16-0/purchase-workflow-16-0-purchase_partner_incoterm | ||
: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=16.0 | ||
:alt: Try me on Runboat | ||
|
||
|badge1| |badge2| |badge3| |badge4| |badge5| | ||
|
||
This module adds incoterms for suppliers and purchase order: | ||
|
||
* incoterm modes | ||
* incoterm address | ||
|
||
Based on Partner/Supplier It will add Incoterm address. | ||
|
||
**Table of contents** | ||
|
||
.. contents:: | ||
:local: | ||
|
||
Bug Tracker | ||
=========== | ||
|
||
Bugs are tracked on `GitHub Issues <https://github.com/OCA/purchase-workflow/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 <https://github.com/OCA/purchase-workflow/issues/new?body=module:%20purchase_partner_incoterm%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_. | ||
|
||
Do not contact contributors directly about support or help with technical issues. | ||
|
||
Credits | ||
======= | ||
|
||
Authors | ||
~~~~~~~ | ||
|
||
* Camptocamp | ||
|
||
Contributors | ||
~~~~~~~~~~~~ | ||
|
||
* `Camptocamp <https://www.camptocamp.com>`_: | ||
* Thierry Ducrest <[email protected]> | ||
* Denis Leemann <[email protected]> | ||
* `Trobz <https://trobz.com>`_: | ||
* Son Ho <[email protected]> | ||
* `Akretion <https://akretion.com>`_: | ||
* David BEAL <[email protected]> | ||
* Raphaël Reverdy <[email protected]> | ||
* `InitOS <https://www.initos.com>`_: | ||
* Dhara Solanki <[email protected]> | ||
* Manish Kumar Bohra <[email protected]> | ||
Other credits | ||
~~~~~~~~~~~~~ | ||
|
||
**Financial support** | ||
* Cosanum | ||
* Camptocamp R&D | ||
|
||
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. | ||
|
||
.. |maintainer-TDu| image:: https://github.com/TDu.png?size=40px | ||
:target: https://github.com/TDu | ||
:alt: TDu | ||
.. |maintainer-bealdav| image:: https://github.com/bealdav.png?size=40px | ||
:target: https://github.com/bealdav | ||
:alt: bealdav | ||
|
||
Current `maintainers <https://odoo-community.org/page/maintainer-role>`__: | ||
|
||
|maintainer-TDu| |maintainer-bealdav| | ||
|
||
This module is part of the `OCA/purchase-workflow <https://github.com/OCA/purchase-workflow/tree/16.0/purchase_partner_incoterm>`_ project on GitHub. | ||
|
||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
from . import models |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Copyright 2020-2022 Camptocamp SA | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). | ||
{ | ||
"name": "Default purchase incoterm per partner", | ||
"summary": "Add a an incoterm field for supplier and use it on purchase order", | ||
"version": "17.0.1.0.0", | ||
"category": "Purchase", | ||
"author": "Camptocamp, Odoo Community Association (OCA)", | ||
"license": "AGPL-3", | ||
"maintainers": ["TDu", "bealdav"], | ||
"depends": [ | ||
"account", | ||
"purchase_stock", | ||
], | ||
"website": "https://github.com/OCA/purchase-workflow", | ||
"data": [ | ||
"views/partner_view.xml", | ||
"views/purchase_view.xml", | ||
], | ||
"installable": True, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * purchase_partner_incoterm | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 16.0\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"PO-Revision-Date: 2023-12-24 15:34+0000\n" | ||
"Last-Translator: mymage <[email protected]>\n" | ||
"Language-Team: none\n" | ||
"Language: it\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_partner_incoterm | ||
#: model:ir.model.fields,help:purchase_partner_incoterm.field_purchase_order__incoterm_address_id | ||
msgid "Address where goods responsibility is transferred to the buyer" | ||
msgstr "" | ||
"Indirizzo dove la responsabilità della merce viene trasferita all'acquirente" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model,name:purchase_partner_incoterm.model_res_partner | ||
msgid "Contact" | ||
msgstr "Contatto" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_res_partner__purchase_incoterm_id | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_res_users__purchase_incoterm_id | ||
msgid "Default Purchase Incoterm" | ||
msgstr "Incoterm acquisto predefinito" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_res_partner__purchase_incoterm_address_id | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_res_users__purchase_incoterm_address_id | ||
msgid "Default Purchase Incoterm Address" | ||
msgstr "Indirizzo incoterm acquisto predefinito" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_purchase_order__incoterm_address_id | ||
msgid "Incoterm Address" | ||
msgstr "Indirizzo Incoterm" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model,name:purchase_partner_incoterm.model_purchase_order | ||
msgid "Purchase Order" | ||
msgstr "Ordine di acquisto" |
46 changes: 46 additions & 0 deletions
46
purchase_partner_incoterm/i18n/purchase_partner_incoterm.pot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * purchase_partner_incoterm | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 16.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_partner_incoterm | ||
#: model:ir.model.fields,help:purchase_partner_incoterm.field_purchase_order__incoterm_address_id | ||
msgid "Address where goods responsibility is transferred to the buyer" | ||
msgstr "" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model,name:purchase_partner_incoterm.model_res_partner | ||
msgid "Contact" | ||
msgstr "" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_res_partner__purchase_incoterm_id | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_res_users__purchase_incoterm_id | ||
msgid "Default Purchase Incoterm" | ||
msgstr "" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_res_partner__purchase_incoterm_address_id | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_res_users__purchase_incoterm_address_id | ||
msgid "Default Purchase Incoterm Address" | ||
msgstr "" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model.fields,field_description:purchase_partner_incoterm.field_purchase_order__incoterm_address_id | ||
msgid "Incoterm Address" | ||
msgstr "" | ||
|
||
#. module: purchase_partner_incoterm | ||
#: model:ir.model,name:purchase_partner_incoterm.model_purchase_order | ||
msgid "Purchase Order" | ||
msgstr "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
from . import purchase_order | ||
from . import res_partner |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Copyright 2020 Camptocamp SA | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
from odoo import api, fields, models | ||
|
||
|
||
class PurchaseOrder(models.Model): | ||
_inherit = "purchase.order" | ||
|
||
incoterm_address_id = fields.Many2one( | ||
comodel_name="res.partner", | ||
string="Incoterm Address", | ||
help="Address where goods responsibility is transferred to the buyer", | ||
) | ||
|
||
@api.onchange("partner_id") | ||
def onchange_partner_id(self): | ||
res = super().onchange_partner_id() | ||
self.incoterm_id = self.partner_id.commercial_partner_id.purchase_incoterm_id | ||
self.incoterm_address_id = ( | ||
self.partner_id.commercial_partner_id.purchase_incoterm_address_id | ||
) | ||
return res |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Copyright 2020 Camptocamp SA | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
from odoo import api, fields, models | ||
|
||
|
||
class ResPartner(models.Model): | ||
_inherit = "res.partner" | ||
|
||
purchase_incoterm_id = fields.Many2one( | ||
comodel_name="account.incoterms", | ||
ondelete="restrict", | ||
string="Default Purchase Incoterm", | ||
) | ||
purchase_incoterm_address_id = fields.Many2one( | ||
comodel_name="res.partner", | ||
ondelete="restrict", | ||
string="Default Purchase Incoterm Address", | ||
) | ||
|
||
@api.model | ||
def _commercial_fields(self): | ||
return super()._commercial_fields() + [ | ||
"purchase_incoterm_address_id", | ||
"purchase_incoterm_id", | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[build-system] | ||
requires = ["whool"] | ||
build-backend = "whool.buildapi" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
- [Camptocamp](https://www.camptocamp.com): | ||
- Thierry Ducrest \<<[email protected]>\> | ||
- Denis Leemann \<<[email protected]>\> | ||
|
||
- [Trobz](https://trobz.com): | ||
- Son Ho \<<[email protected]>\> | ||
|
||
- [Akretion](https://akretion.com): | ||
- David BEAL \<<[email protected]>\> | ||
- Raphaël Reverdy \<<[email protected]>\> | ||
|
||
- [InitOS](https://www.initos.com): | ||
- Dhara Solanki \<<[email protected]>\> | ||
* Manish Kumar Bohra <[email protected]> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
* `Camptocamp <https://www.camptocamp.com>`_: | ||
* Thierry Ducrest <[email protected]> | ||
* Denis Leemann <[email protected]> | ||
* `Trobz <https://trobz.com>`_: | ||
* Son Ho <[email protected]> | ||
* `Akretion <https://akretion.com>`_: | ||
* David BEAL <[email protected]> | ||
* Raphaël Reverdy <[email protected]> | ||
* `InitOS <https://www.initos.com>`_: | ||
* Dhara Solanki <[email protected]> | ||
* Manish Kumar Bohra <[email protected]> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
**Financial support** \* Cosanum \* Camptocamp R&D |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
**Financial support** | ||
* Cosanum | ||
* Camptocamp R&D |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
This module adds incoterms for suppliers and purchase order: | ||
|
||
- incoterm modes | ||
- incoterm address | ||
|
||
Based on Partner/Supplier It will add Incoterm address. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
This module adds incoterms for suppliers and purchase order: | ||
|
||
* incoterm modes | ||
* incoterm address | ||
|
||
Based on Partner/Supplier It will add Incoterm address. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.