Skip to content

Commit

Permalink
Merge PR #75 into 12.0
Browse files Browse the repository at this point in the history
Signed-off-by pedrobaeza
  • Loading branch information
OCA-git-bot committed Nov 21, 2019
2 parents a9dd4e3 + faeb102 commit e59a4f8
Show file tree
Hide file tree
Showing 19 changed files with 706 additions and 0 deletions.
93 changes: 93 additions & 0 deletions contract_membership_delegated_partner/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
====================================
Contract Membership Delegate Partner
====================================

.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! 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%2Fvertical--association-lightgray.png?logo=github
:target: https://github.com/OCA/vertical-association/tree/12.0/contract_membership_delegated_partner
:alt: OCA/vertical-association
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/vertical-association-11-0/vertical-association-11-0-contract_membership_delegated_partner
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
:target: https://runbot.odoo-community.org/runbot/208/12.0
:alt: Try me on Runbot

|badge1| |badge2| |badge3| |badge4| |badge5|

This module allows to set the delegated membership at the contract so the
recurring invoices automatically have it set.

**Table of contents**

.. contents::
:local:

Installation
============

You'll need to install the module contract from https://github.com/OCA/contract

Configuration
=============

In *Settings > Users > <your_user>* set *Delegated partner in membership*
permission on.

Usage
=====

#. Set the delegated partner in contract.
#. The recurring invoices will set this partner as delegated partner from now
on.

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/vertical-association/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 <https://github.com/OCA/vertical-association/issues/new?body=module:%20contract_membership_delegated_partner%0Aversion:%2012.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
~~~~~~~

* Tecnativa

Contributors
~~~~~~~~~~~~

* David Vidal <david.vidal@tecnativa.com>
* Rafael Blasco <rafael.blasco@tecnativa.com>

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/vertical-association <https://github.com/OCA/vertical-association/tree/12.0/contract_membership_delegated_partner>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
1 change: 1 addition & 0 deletions contract_membership_delegated_partner/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
20 changes: 20 additions & 0 deletions contract_membership_delegated_partner/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Copyright 2017-18 Tecnativa - David Vidal
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
{
'name': 'Contract Membership Delegate Partner',
'version': '12.0.1.0.0',
'category': 'Membership',
'author': 'Tecnativa, '
'Odoo Community Association (OCA)',
'website': 'https://github.com/oca/vertical-association',
'license': 'AGPL-3',
'summary': 'Set delegate membership on the contract',
'depends': [
'membership_delegated_partner',
'contract',
],
'data': [
'views/contract.xml',
],
'installable': True,
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * contract_membership_delegated_partner
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 11.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: <>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"

#. module: contract_membership_delegated_partner
#: model:ir.model,name:contract_membership_delegated_partner.model_account_analytic_account
msgid "Analytic Account"
msgstr ""

#. module: contract_membership_delegated_partner
#: model:ir.model.fields,field_description:contract_membership_delegated_partner.field_account_analytic_account_delegated_member_id
msgid "Delegated Member"
msgstr ""

29 changes: 29 additions & 0 deletions contract_membership_delegated_partner/i18n/de.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * contract_membership_delegated_partner
#
# Translators:
# Rudolf Schnapka <rs@techno-flex.de>, 2018
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 10.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-01-12 19:14+0000\n"
"PO-Revision-Date: 2018-01-12 19:14+0000\n"
"Last-Translator: Rudolf Schnapka <rs@techno-flex.de>, 2018\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"

#. module: contract_membership_delegated_partner
#: model:ir.model,name:contract_membership_delegated_partner.model_account_analytic_account
msgid "Analytic Account"
msgstr "Vertragskonto"

#. module: contract_membership_delegated_partner
#: model:ir.model.fields,field_description:contract_membership_delegated_partner.field_account_analytic_account_delegated_member_id
msgid "Delegated Member"
msgstr "Delegationsmitglied"
29 changes: 29 additions & 0 deletions contract_membership_delegated_partner/i18n/es.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * contract_membership_delegated_partner
#
# Translators:
# enjolras <yo@miguelrevilla.com>, 2018
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 10.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-02-28 01:55+0000\n"
"PO-Revision-Date: 2018-02-28 01:55+0000\n"
"Last-Translator: enjolras <yo@miguelrevilla.com>, 2018\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_membership_delegated_partner
#: model:ir.model,name:contract_membership_delegated_partner.model_account_analytic_account
msgid "Analytic Account"
msgstr "Cuenta analítica"

#. module: contract_membership_delegated_partner
#: model:ir.model.fields,field_description:contract_membership_delegated_partner.field_account_analytic_account_delegated_member_id
msgid "Delegated Member"
msgstr "Miembro delegado"
1 change: 1 addition & 0 deletions contract_membership_delegated_partner/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import contract
17 changes: 17 additions & 0 deletions contract_membership_delegated_partner/models/contract.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Copyright 2017-19 Tecnativa - David Vidal
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from odoo import fields, models


class AccountAnalyticAccount(models.Model):
_inherit = 'contract.contract'

delegated_member_id = fields.Many2one(
comodel_name='res.partner',
string='Delegated Member',
)

def _prepare_invoice(self, date_invoice, journal=None):
res = super()._prepare_invoice(date_invoice, journal=journal)
res['delegated_member_id'] = self.delegated_member_id.id
return res
2 changes: 2 additions & 0 deletions contract_membership_delegated_partner/readme/CONFIGURE.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
In *Settings > Users > <your_user>* set *Delegated partner in membership*
permission on.
2 changes: 2 additions & 0 deletions contract_membership_delegated_partner/readme/CONTRIBUTORS.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
* David Vidal <david.vidal@tecnativa.com>
* Rafael Blasco <rafael.blasco@tecnativa.com>
2 changes: 2 additions & 0 deletions contract_membership_delegated_partner/readme/DESCRIPTION.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
This module allows to set the delegated membership at the contract so the
recurring invoices automatically have it set.
1 change: 1 addition & 0 deletions contract_membership_delegated_partner/readme/INSTALL.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
You'll need to install the module contract from https://github.com/OCA/contract
3 changes: 3 additions & 0 deletions contract_membership_delegated_partner/readme/USAGE.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#. Set the delegated partner in contract.
#. The recurring invoices will set this partner as delegated partner from now
on.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit e59a4f8

Please sign in to comment.