Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MIG] crm_l10n_eu_nace: Migration to 16.0 #629

Closed
wants to merge 13 commits into from
89 changes: 89 additions & 0 deletions crm_l10n_eu_nace/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
===============================
European NACE categories in CRM
===============================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:d6eb7a1deb931a10a56be1e16d58c7cf3100301609fd5736c1cfeecb8de72e18
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |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%2Fcrm-lightgray.png?logo=github
:target: https://github.com/OCA/crm/tree/16.0/crm_l10n_eu_nace
:alt: OCA/crm
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/crm-16-0/crm-16-0-crm_l10n_eu_nace
: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/crm&target_branch=16.0
:alt: Try me on Runboat

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

This module adds the concept of NACE activity to the CRM main objects (lead,
opportunity), and propagates them through the workflow.

**Table of contents**

.. contents::
:local:

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

This module depends on ``l10n_eu_nace``, which you can download from
`OCA/community-data-files <https://github.com/OCA/community-data-files>`__.

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

Bugs are tracked on `GitHub Issues <https://github.com/OCA/crm/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/crm/issues/new?body=module:%20crm_l10n_eu_nace%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
~~~~~~~

* Tecnativa

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

* `Tecnativa <https://www.tecnativa.com/>`__:

* Pedro M. Baeza
* Antonio Espinosa
* David Vidal
* Jairo Llopis
* Ernesto Tejeda

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/crm <https://github.com/OCA/crm/tree/16.0/crm_l10n_eu_nace>`_ 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 crm_l10n_eu_nace/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
11 changes: 11 additions & 0 deletions crm_l10n_eu_nace/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"name": "European NACE categories in CRM",
"version": "16.0.1.0.0",
"category": "Customer Relationship Management",
"author": "Tecnativa, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/crm",
"depends": ["crm", "l10n_eu_nace"],
"data": ["views/crm_lead_view.xml"],
"installable": True,
"license": "AGPL-3",
}
50 changes: 50 additions & 0 deletions crm_l10n_eu_nace/i18n/crm_l10n_eu_nace.pot
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:
# * crm_l10n_eu_nace
#
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: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__display_name
msgid "Display Name"
msgstr ""

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__id
msgid "ID"
msgstr ""

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead____last_update
msgid "Last Modified on"
msgstr ""

#. module: crm_l10n_eu_nace
#: model:ir.model,name:crm_l10n_eu_nace.model_crm_lead
msgid "Lead/Opportunity"
msgstr ""

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__nace_id
msgid "Main NACE"
msgstr ""

#. module: crm_l10n_eu_nace
#: model_terms:ir.ui.view,arch_db:crm_l10n_eu_nace.view_crm_case_leads_filter
#: model_terms:ir.ui.view,arch_db:crm_l10n_eu_nace.view_crm_case_opportunities_filter
msgid "NACE"
msgstr ""

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__secondary_nace_ids
msgid "Secondary NACE"
msgstr ""
63 changes: 63 additions & 0 deletions crm_l10n_eu_nace/i18n/es.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * crm_activity_nace
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 10.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-06-19 18:30+0000\n"
"PO-Revision-Date: 2024-02-17 00:45+0000\n"
"Last-Translator: Ivorra78 <informatica@totmaterial.es>\n"
"Language-Team: \n"
"Language: es\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 4.17\n"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__display_name
msgid "Display Name"
msgstr "Mostrar Nombre"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__id
msgid "ID"
msgstr "ID"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead____last_update
msgid "Last Modified on"
msgstr "Última Modificación el"

#. module: crm_l10n_eu_nace
#: model:ir.model,name:crm_l10n_eu_nace.model_crm_lead
msgid "Lead/Opportunity"
msgstr "Iniciativa/Oportunidad"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__nace_id
msgid "Main NACE"
msgstr "NACE principal"

#. module: crm_l10n_eu_nace
#: model_terms:ir.ui.view,arch_db:crm_l10n_eu_nace.view_crm_case_leads_filter
#: model_terms:ir.ui.view,arch_db:crm_l10n_eu_nace.view_crm_case_opportunities_filter
msgid "NACE"
msgstr "NACE"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__secondary_nace_ids
msgid "Secondary NACE"
msgstr "Secundaria NACE"

#~ msgid "Activity"
#~ msgstr "Actividad"

#~ msgid "Main activity"
#~ msgstr "Actividad principal"

#~ msgid "Other activities"
#~ msgstr "Otras actividades"
53 changes: 53 additions & 0 deletions crm_l10n_eu_nace/i18n/fr.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * crm_l10n_eu_nace
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2022-09-13 12:07+0000\n"
"Last-Translator: Claude R Perrin <claude@perrin.it>\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"
"X-Generator: Weblate 4.3.2\n"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__display_name
msgid "Display Name"
msgstr "Nom affiché"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__id
msgid "ID"
msgstr "ID"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead____last_update
msgid "Last Modified on"
msgstr "Dernière modification le"

#. module: crm_l10n_eu_nace
#: model:ir.model,name:crm_l10n_eu_nace.model_crm_lead
msgid "Lead/Opportunity"
msgstr "Piste/opportunité"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__nace_id
msgid "Main NACE"
msgstr "NACE Principal"

#. module: crm_l10n_eu_nace
#: model_terms:ir.ui.view,arch_db:crm_l10n_eu_nace.view_crm_case_leads_filter
#: model_terms:ir.ui.view,arch_db:crm_l10n_eu_nace.view_crm_case_opportunities_filter
msgid "NACE"
msgstr "NACE"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__secondary_nace_ids
msgid "Secondary NACE"
msgstr "NACE Secondaire"
53 changes: 53 additions & 0 deletions crm_l10n_eu_nace/i18n/it.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * crm_l10n_eu_nace
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2023-06-14 15:08+0000\n"
"Last-Translator: mymage <stefano.consolaro@mymage.it>\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: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__display_name
msgid "Display Name"
msgstr "Nome visualizzato"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__id
msgid "ID"
msgstr "ID"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead____last_update
msgid "Last Modified on"
msgstr "Ultima modifica il"

#. module: crm_l10n_eu_nace
#: model:ir.model,name:crm_l10n_eu_nace.model_crm_lead
msgid "Lead/Opportunity"
msgstr "Contatto/Opportunità"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__nace_id
msgid "Main NACE"
msgstr "NACE principale"

#. module: crm_l10n_eu_nace
#: model_terms:ir.ui.view,arch_db:crm_l10n_eu_nace.view_crm_case_leads_filter
#: model_terms:ir.ui.view,arch_db:crm_l10n_eu_nace.view_crm_case_opportunities_filter
msgid "NACE"
msgstr "NACE"

#. module: crm_l10n_eu_nace
#: model:ir.model.fields,field_description:crm_l10n_eu_nace.field_crm_lead__secondary_nace_ids
msgid "Secondary NACE"
msgstr "NACE secondario"
1 change: 1 addition & 0 deletions crm_l10n_eu_nace/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import crm_lead
23 changes: 23 additions & 0 deletions crm_l10n_eu_nace/models/crm_lead.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
from odoo import fields, models


class CrmLead(models.Model):
_inherit = "crm.lead"

nace_id = fields.Many2one(
comodel_name="res.partner.nace", string="Main NACE", index=True
)
secondary_nace_ids = fields.Many2many(
comodel_name="res.partner.nace", string="Secondary NACE"
)

def _prepare_customer_values(self, name, is_company, parent_id=False):
"""Propagate NACE activity to created partner."""
result = super()._prepare_customer_values(name, is_company, parent_id)
if self.nace_id:
result["nace_id"] = self.nace_id.id
if self.secondary_nace_ids:
result["secondary_nace_ids"] = [
(4, id_) for id_ in self.secondary_nace_ids.ids
]
return result
7 changes: 7 additions & 0 deletions crm_l10n_eu_nace/readme/CONTRIBUTORS.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
* `Tecnativa <https://www.tecnativa.com/>`__:

* Pedro M. Baeza
* Antonio Espinosa
* David Vidal
* Jairo Llopis
* Ernesto Tejeda
2 changes: 2 additions & 0 deletions crm_l10n_eu_nace/readme/DESCRIPTION.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
This module adds the concept of NACE activity to the CRM main objects (lead,
opportunity), and propagates them through the workflow.
2 changes: 2 additions & 0 deletions crm_l10n_eu_nace/readme/INSTALL.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
This module depends on ``l10n_eu_nace``, which you can download from
`OCA/community-data-files <https://github.com/OCA/community-data-files>`__.
Binary file added crm_l10n_eu_nace/static/description/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading