-
-
Notifications
You must be signed in to change notification settings - Fork 530
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 pedrobaeza
- Loading branch information
Showing
43 changed files
with
1,691 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,102 @@ | ||
===================== | ||
Contract Payment Mode | ||
===================== | ||
|
||
.. | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! This file is generated by oca-gen-addon-readme !! | ||
!! changes will be overwritten. !! | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! source digest: sha256:b0c3f63c4d845960be5d0e10a987897276ccdd53fe4a54d417bd64884c7377f6 | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
.. |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%2Fcontract-lightgray.png?logo=github | ||
:target: https://github.com/OCA/contract/tree/15.0/contract_payment_mode | ||
:alt: OCA/contract | ||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png | ||
:target: https://translation.odoo-community.org/projects/contract-15-0/contract-15-0-contract_payment_mode | ||
: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/contract&target_branch=15.0 | ||
:alt: Try me on Runboat | ||
|
||
|badge1| |badge2| |badge3| |badge4| |badge5| | ||
|
||
This module allows to set a payment mode on contract for creating the invoices | ||
with this payment mode. | ||
|
||
**Table of contents** | ||
|
||
.. contents:: | ||
:local: | ||
|
||
Configuration | ||
============= | ||
|
||
Your user should be a Sales Manager or Accountant. | ||
|
||
Usage | ||
===== | ||
|
||
#. Go to *Accounting > Sales > Contracts*. | ||
#. Create one. | ||
#. Select a partner to which invoice. | ||
#. If the partner has a payment mode, this payment mode is selected here. | ||
#. If not, or if you want another payment mode, you can change it in the | ||
corresponding field. | ||
#. Click on **Generate recurring invoices automatically** checkbox. | ||
#. Add a product to invoice. | ||
#. If you create an invoice, new invoice will have the selected payment mode. | ||
|
||
Bug Tracker | ||
=========== | ||
|
||
Bugs are tracked on `GitHub Issues <https://github.com/OCA/contract/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/contract/issues/new?body=module:%20contract_payment_mode%0Aversion:%2015.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 | ||
~~~~~~~ | ||
|
||
* Domatix | ||
* Tecnativa | ||
|
||
Contributors | ||
~~~~~~~~~~~~ | ||
|
||
* Ángel Moya <[email protected]> | ||
* Antonio Espinosa <[email protected]> | ||
* Vicent Cubells <[email protected]> | ||
* David Vidal <[email protected]> | ||
* Carlos Dauden <[email protected]> | ||
* Guillermo Llinares <[email protected]> | ||
* Amamr Officewala <[email protected]> | ||
|
||
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/contract <https://github.com/OCA/contract/tree/15.0/contract_payment_mode>`_ 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,4 @@ | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). | ||
|
||
from . import models | ||
from .hooks import post_init_hook |
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,23 @@ | ||
# Copyright 2015 Domatix (<www.domatix.com>) | ||
# Copyright 2016 Antiun Ingenieria S.L. - Antonio Espinosa | ||
# Copyright 2017 Tecnativa - David Vidal | ||
# Copyright 2017 Tecnativa - Carlos Dauden <[email protected]> | ||
# Copyright 2017-2018 Tecnativa - Vicent Cubells <[email protected]> | ||
# Copyright (C) 2021 Open Source Integrators | ||
# Copyright 2023 Tecnativa - Carolina Fernandez | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). | ||
|
||
{ | ||
"name": "Contract Payment Mode", | ||
"summary": "Payment mode in contracts and their invoices", | ||
"version": "16.0.1.0.0", | ||
"author": "Domatix, " "Tecnativa, " "Odoo Community Association (OCA)", | ||
"website": "https://github.com/OCA/contract", | ||
"depends": ["contract", "account_payment_partner"], | ||
"category": "Sales Management", | ||
"license": "AGPL-3", | ||
"data": ["views/contract_view.xml"], | ||
"post_init_hook": "post_init_hook", | ||
"installable": True, | ||
"auto_install": 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,22 @@ | ||
# Copyright 2016 Antiun Ingenieria S.L. - Antonio Espinosa | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). | ||
|
||
import logging | ||
|
||
from odoo import SUPERUSER_ID, api | ||
|
||
_logger = logging.getLogger(__name__) | ||
|
||
|
||
def post_init_hook(cr, registry): | ||
"""Copy payment mode from partner to the new field at contract.""" | ||
env = api.Environment(cr, SUPERUSER_ID, {}) | ||
m_contract = env["contract.contract"] | ||
contracts = m_contract.search([("payment_mode_id", "=", False)]) | ||
if contracts: | ||
_logger.info("Setting payment mode: %d contracts" % len(contracts)) | ||
for contract in contracts: | ||
payment_mode = contract.partner_id.customer_payment_mode_id | ||
if payment_mode: | ||
contract.payment_mode_id = payment_mode.id | ||
_logger.info("Setting payment mode: Done") |
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,34 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * contract_payment_mode | ||
# | ||
# Translators: | ||
# OCA Transbot <[email protected]>, 2017 | ||
# Marc Tormo i Bochaca <[email protected]>, 2017 | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 15.0c\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"POT-Creation-Date: 2019-05-29 10:30+0000\n" | ||
"PO-Revision-Date: 2019-10-09 18:37+0000\n" | ||
"Last-Translator: Albert Pons <[email protected]>\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" | ||
"Plural-Forms: nplurals=2; plural=n != 1;\n" | ||
"X-Generator: Weblate 3.8\n" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model,name:contract_payment_mode.model_contract_contract | ||
msgid "Contract" | ||
msgstr "Contracte" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model.fields,field_description:contract_payment_mode.field_contract_contract__payment_mode_id | ||
msgid "Payment Mode" | ||
msgstr "Forma de pagament" | ||
|
||
#~ msgid "Analytic Account" | ||
#~ msgstr "Compte analític" |
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,24 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * contract_payment_mode | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 15.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: contract_payment_mode | ||
#: model:ir.model,name:contract_payment_mode.model_contract_contract | ||
msgid "Contract" | ||
msgstr "" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model.fields,field_description:contract_payment_mode.field_contract_contract__payment_mode_id | ||
msgid "Payment Mode" | ||
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,33 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * contract_payment_mode | ||
# | ||
# Translators: | ||
# OCA Transbot <[email protected]>, 2017 | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 15.0c\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"POT-Creation-Date: 2019-05-29 10:30+0000\n" | ||
"PO-Revision-Date: 2019-10-29 21:33+0000\n" | ||
"Last-Translator: Rudolf Schnapka <[email protected]>\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" | ||
"Plural-Forms: nplurals=2; plural=n != 1;\n" | ||
"X-Generator: Weblate 3.8\n" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model,name:contract_payment_mode.model_contract_contract | ||
msgid "Contract" | ||
msgstr "Vertrag" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model.fields,field_description:contract_payment_mode.field_contract_contract__payment_mode_id | ||
msgid "Payment Mode" | ||
msgstr "Zahlweise" | ||
|
||
#~ msgid "Analytic Account" | ||
#~ msgstr "Kostenstelle" |
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,32 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * contract_payment_mode | ||
# | ||
# Translators: | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: contract (15.0)\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"POT-Creation-Date: 2019-05-29 10:30+0000\n" | ||
"PO-Revision-Date: 2015-11-07 12:33+0000\n" | ||
"Last-Translator: <>\n" | ||
"Language-Team: Greek (Greece) (http://www.transifex.com/oca/OCA-contract-8-0/" | ||
"language/el_GR/)\n" | ||
"Language: el_GR\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: contract_payment_mode | ||
#: model:ir.model,name:contract_payment_mode.model_contract_contract | ||
msgid "Contract" | ||
msgstr "" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model.fields,field_description:contract_payment_mode.field_contract_contract__payment_mode_id | ||
msgid "Payment Mode" | ||
msgstr "" | ||
|
||
#~ msgid "Analytic Account" | ||
#~ 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,32 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * contract_payment_mode | ||
# | ||
# Translators: | ||
# OCA Transbot <[email protected]>, 2017 | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 15.0c\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"POT-Creation-Date: 2019-05-29 10:30+0000\n" | ||
"PO-Revision-Date: 2017-04-01 02:46+0000\n" | ||
"Last-Translator: OCA Transbot <[email protected]>, 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" | ||
"Plural-Forms: nplurals=2; plural=(n != 1);\n" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model,name:contract_payment_mode.model_contract_contract | ||
msgid "Contract" | ||
msgstr "" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model.fields,field_description:contract_payment_mode.field_contract_contract__payment_mode_id | ||
msgid "Payment Mode" | ||
msgstr "Modo de pago" | ||
|
||
#~ msgid "Analytic Account" | ||
#~ msgstr "Cuenta analítica" |
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,27 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * contract_payment_mode | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 15.0\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"PO-Revision-Date: 2022-09-05 07:07+0000\n" | ||
"Last-Translator: Ignacio Buioli <[email protected]>\n" | ||
"Language-Team: none\n" | ||
"Language: es_AR\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.3.2\n" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model,name:contract_payment_mode.model_contract_contract | ||
msgid "Contract" | ||
msgstr "Contrato" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model.fields,field_description:contract_payment_mode.field_contract_contract__payment_mode_id | ||
msgid "Payment Mode" | ||
msgstr "Método de Pago" |
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,32 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * contract_payment_mode | ||
# | ||
# Translators: | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: contract (15.0)\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"POT-Creation-Date: 2019-05-29 10:30+0000\n" | ||
"PO-Revision-Date: 2015-11-07 12:33+0000\n" | ||
"Last-Translator: <>\n" | ||
"Language-Team: Spanish (Mexico) (http://www.transifex.com/oca/OCA-" | ||
"contract-8-0/language/es_MX/)\n" | ||
"Language: es_MX\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: contract_payment_mode | ||
#: model:ir.model,name:contract_payment_mode.model_contract_contract | ||
msgid "Contract" | ||
msgstr "" | ||
|
||
#. module: contract_payment_mode | ||
#: model:ir.model.fields,field_description:contract_payment_mode.field_contract_contract__payment_mode_id | ||
msgid "Payment Mode" | ||
msgstr "" | ||
|
||
#~ msgid "Analytic Account" | ||
#~ msgstr "Cuenta analítica" |
Oops, something went wrong.