Browse Source

[MIG] 13.0 partner_contact_lang

12.0
Pedro 5 years ago
committed by Pedro M. Baeza
parent
commit
a894a4456e
  1. 14
      partner_contact_lang/README.rst
  2. 2
      partner_contact_lang/__init__.py
  3. 8
      partner_contact_lang/__manifest__.py
  4. 5
      partner_contact_lang/i18n/am.po
  5. 5
      partner_contact_lang/i18n/ar.po
  6. 5
      partner_contact_lang/i18n/bg.po
  7. 5
      partner_contact_lang/i18n/bs.po
  8. 5
      partner_contact_lang/i18n/ca.po
  9. 5
      partner_contact_lang/i18n/cs.po
  10. 5
      partner_contact_lang/i18n/da.po
  11. 5
      partner_contact_lang/i18n/de.po
  12. 5
      partner_contact_lang/i18n/el_GR.po
  13. 5
      partner_contact_lang/i18n/en_GB.po
  14. 5
      partner_contact_lang/i18n/es.po
  15. 5
      partner_contact_lang/i18n/es_CR.po
  16. 5
      partner_contact_lang/i18n/es_EC.po
  17. 5
      partner_contact_lang/i18n/es_MX.po
  18. 5
      partner_contact_lang/i18n/es_VE.po
  19. 5
      partner_contact_lang/i18n/et.po
  20. 5
      partner_contact_lang/i18n/eu.po
  21. 5
      partner_contact_lang/i18n/fi.po
  22. 5
      partner_contact_lang/i18n/fr.po
  23. 5
      partner_contact_lang/i18n/fr_CA.po
  24. 5
      partner_contact_lang/i18n/fr_CH.po
  25. 5
      partner_contact_lang/i18n/gl.po
  26. 5
      partner_contact_lang/i18n/hr.po
  27. 5
      partner_contact_lang/i18n/hr_HR.po
  28. 5
      partner_contact_lang/i18n/hu.po
  29. 5
      partner_contact_lang/i18n/it.po
  30. 5
      partner_contact_lang/i18n/ja.po
  31. 5
      partner_contact_lang/i18n/lt.po
  32. 5
      partner_contact_lang/i18n/lv.po
  33. 5
      partner_contact_lang/i18n/mk.po
  34. 5
      partner_contact_lang/i18n/mn.po
  35. 5
      partner_contact_lang/i18n/nb.po
  36. 5
      partner_contact_lang/i18n/nb_NO.po
  37. 5
      partner_contact_lang/i18n/nl.po
  38. 5
      partner_contact_lang/i18n/nl_BE.po
  39. 8
      partner_contact_lang/i18n/partner_contact_lang.pot
  40. 5
      partner_contact_lang/i18n/pl.po
  41. 5
      partner_contact_lang/i18n/pt.po
  42. 5
      partner_contact_lang/i18n/pt_BR.po
  43. 5
      partner_contact_lang/i18n/pt_PT.po
  44. 5
      partner_contact_lang/i18n/ro.po
  45. 5
      partner_contact_lang/i18n/ru.po
  46. 5
      partner_contact_lang/i18n/sk.po
  47. 5
      partner_contact_lang/i18n/sl.po
  48. 5
      partner_contact_lang/i18n/sr@latin.po
  49. 5
      partner_contact_lang/i18n/sv.po
  50. 5
      partner_contact_lang/i18n/th.po
  51. 5
      partner_contact_lang/i18n/tr.po
  52. 5
      partner_contact_lang/i18n/tr_TR.po
  53. 5
      partner_contact_lang/i18n/vi.po
  54. 5
      partner_contact_lang/i18n/zh_CN.po
  55. 5
      partner_contact_lang/i18n/zh_TW.po
  56. 2
      partner_contact_lang/models/__init__.py
  57. 15
      partner_contact_lang/models/res_partner.py
  58. 1
      partner_contact_lang/readme/CONTRIBUTORS.rst
  59. 3
      partner_contact_lang/readme/DESCRIPTION.rst
  60. 12
      partner_contact_lang/static/description/index.html
  61. 2
      partner_contact_lang/tests/__init__.py
  62. 8
      partner_contact_lang/tests/test_partner_contact_lang.py
  63. 41
      partner_contact_lang/views/res_partner_view.xml

14
partner_contact_lang/README.rst

@ -14,13 +14,13 @@ Manage language in contacts
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fpartner--contact-lightgray.png?logo=github
:target: https://github.com/OCA/partner-contact/tree/11.0/partner_contact_lang
:target: https://github.com/OCA/partner-contact/tree/13.0/partner_contact_lang
:alt: OCA/partner-contact
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/partner-contact-11-0/partner-contact-11-0-partner_contact_lang
:target: https://translation.odoo-community.org/projects/partner-contact-13-0/partner-contact-13-0-partner_contact_lang
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
:target: https://runbot.odoo-community.org/runbot/134/11.0
:target: https://runbot.odoo-community.org/runbot/134/13.0
:alt: Try me on Runbot
|badge1| |badge2| |badge3| |badge4| |badge5|
@ -35,6 +35,9 @@ contact language management:
language and this parent company is assigned.
#. When the company changes the language, it fills with the same language all
the contacts that don't have any.
#. Show the language in the inner narrowed Contact form and
set the new conctact with a different language if needed.
#. Search and also group contacts by their language.
**Table of contents**
@ -53,7 +56,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues <https://github.com/OCA/partner-contact/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/partner-contact/issues/new?body=module:%20partner_contact_lang%0Aversion:%2011.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
`feedback <https://github.com/OCA/partner-contact/issues/new?body=module:%20partner_contact_lang%0Aversion:%2013.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.
@ -74,6 +77,7 @@ Contributors
* Vicent Cubells
* David Vidal
* Cristina Martín
* Pedro Evaristo Gonzalez Sanchez <pedro.gonzalez@pesol.es>
Maintainers
~~~~~~~~~~~
@ -88,6 +92,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/partner-contact <https://github.com/OCA/partner-contact/tree/11.0/partner_contact_lang>`_ project on GitHub.
This module is part of the `OCA/partner-contact <https://github.com/OCA/partner-contact/tree/13.0/partner_contact_lang>`_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

2
partner_contact_lang/__init__.py

@ -1,3 +1,3 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from . import models

8
partner_contact_lang/__manifest__.py

@ -1,14 +1,16 @@
# Copyright 2016 Tecnativa - Pedro M. Baeza <pedro.baeza@tecnativa.com>
# Copyright 2017 Tecnativa - Vicent Cubells <vicent.cubells@tecnativa.com>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
# Copyright 2020 Pesol - Pedro Evaristo Gonzalez Sanchez <pedro.gonzalez@pesol.es>
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
{
"name": "Manage language in contacts",
"version": "11.0.1.0.0",
"version": "13.0.1.0.0",
"category": "Sales",
"license": "AGPL-3",
"author": "Tecnativa," "Odoo Community Association (OCA)",
"website": "https://github.com/OCA/partner-contact/",
"depends": ["base",],
"depends": ["base"],
"data": ["views/res_partner_view.xml"],
"installable": True,
}

5
partner_contact_lang/i18n/am.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "ተባባሪ"

5
partner_contact_lang/i18n/ar.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "الشريك"

5
partner_contact_lang/i18n/bg.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Партньор"

5
partner_contact_lang/i18n/bs.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/ca.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Empresa"

5
partner_contact_lang/i18n/cs.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Společník"

5
partner_contact_lang/i18n/da.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/de.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/el_GR.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Συνεργάτης"

5
partner_contact_lang/i18n/en_GB.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/es.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Empresa"

5
partner_contact_lang/i18n/es_CR.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Empresa"

5
partner_contact_lang/i18n/es_EC.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Empresa"

5
partner_contact_lang/i18n/es_MX.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Empresa"

5
partner_contact_lang/i18n/es_VE.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Empresa"

5
partner_contact_lang/i18n/et.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/eu.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Kidea"

5
partner_contact_lang/i18n/fi.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Kumppani"

5
partner_contact_lang/i18n/fr.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partenaire"

5
partner_contact_lang/i18n/fr_CA.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partenaire"

5
partner_contact_lang/i18n/fr_CH.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partenaire"

5
partner_contact_lang/i18n/gl.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Empresa"

5
partner_contact_lang/i18n/hr.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/hr_HR.po

@ -25,5 +25,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/hu.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/it.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/ja.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "パートナ"

5
partner_contact_lang/i18n/lt.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partneris"

5
partner_contact_lang/i18n/lv.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partneris"

5
partner_contact_lang/i18n/mk.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Партнер"

5
partner_contact_lang/i18n/mn.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Харилцагч"

5
partner_contact_lang/i18n/nb.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/nb_NO.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/nl.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/nl_BE.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Relatie"

8
partner_contact_lang/i18n/partner_contact_lang.pot

@ -4,9 +4,9 @@
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 11.0\n"
"Project-Id-Version: Odoo Server 13.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: <>\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@ -18,3 +18,7 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""

5
partner_contact_lang/i18n/pl.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/pt.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Entidade"

5
partner_contact_lang/i18n/pt_BR.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Parceiro"

5
partner_contact_lang/i18n/pt_PT.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Parceiro"

5
partner_contact_lang/i18n/ro.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partener"

5
partner_contact_lang/i18n/ru.po

@ -25,5 +25,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Контрагент"

5
partner_contact_lang/i18n/sk.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/sl.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/sr@latin.po

@ -25,5 +25,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/sv.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Partner"

5
partner_contact_lang/i18n/th.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "พาร์ทเนอร์"

5
partner_contact_lang/i18n/tr.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "İş Ortağı"

5
partner_contact_lang/i18n/tr_TR.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Ortak"

5
partner_contact_lang/i18n/vi.po

@ -23,5 +23,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "Đối tác"

5
partner_contact_lang/i18n/zh_CN.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "业务伙伴"

5
partner_contact_lang/i18n/zh_TW.po

@ -24,5 +24,10 @@ msgstr ""
msgid "Contact"
msgstr ""
#. module: partner_contact_lang
#: model_terms:ir.ui.view,arch_db:partner_contact_lang.view_res_partner_filter
msgid "Language"
msgstr ""
#~ msgid "Partner"
#~ msgstr "夥伴"

2
partner_contact_lang/models/__init__.py

@ -1,3 +1,3 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from . import res_partner

15
partner_contact_lang/models/res_partner.py

@ -1,6 +1,6 @@
# Copyright 2016 Tecnativa - Pedro M. Baeza <pedro.baeza@tecnativa.com>
# Copyright 2017 Tecnativa - Vicent Cubells <vicent.cubells@tecnativa.com>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from odoo import api, models
@ -8,12 +8,11 @@ from odoo import api, models
class ResPartner(models.Model):
_inherit = "res.partner"
@api.multi
def write(self, vals):
"""Propagate a language change in the partner to the child contacts."""
res = super(ResPartner, self).write(vals)
if vals.get("lang"):
childs = self.search([("id", "child_of", self.ids), ("lang", "=", False),])
childs = self.search([("id", "child_of", self.ids), ("lang", "=", False)])
if childs:
childs.write({"lang": vals["lang"]})
return res
@ -23,7 +22,11 @@ class ResPartner(models.Model):
"""Change language if the parent company changes and there's no
language defined yet"""
res = super(ResPartner, self).onchange_parent_id()
if self.parent_id and self.parent_id != self and not self.lang:
val = res.setdefault("value", {})
val["lang"] = self.parent_id.lang
if (
self.parent_id
and self.parent_id != self
and not self.lang
and self.parent_id.lang
):
self.lang = self.parent_id.lang
return res

1
partner_contact_lang/readme/CONTRIBUTORS.rst

@ -4,3 +4,4 @@
* Vicent Cubells
* David Vidal
* Cristina Martín
* Pedro Evaristo Gonzalez Sanchez <pedro.gonzalez@pesol.es>

3
partner_contact_lang/readme/DESCRIPTION.rst

@ -8,3 +8,6 @@ contact language management:
language and this parent company is assigned.
#. When the company changes the language, it fills with the same language all
the contacts that don't have any.
#. Show the language in the inner narrowed Contact form and
set the new conctact with a different language if needed.
#. Search and also group contacts by their language.

12
partner_contact_lang/static/description/index.html

@ -367,7 +367,7 @@ ul.auto-toc {
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<p><a class="reference external" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external" href="https://github.com/OCA/partner-contact/tree/11.0/partner_contact_lang"><img alt="OCA/partner-contact" src="https://img.shields.io/badge/github-OCA%2Fpartner--contact-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/partner-contact-11-0/partner-contact-11-0-partner_contact_lang"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external" href="https://runbot.odoo-community.org/runbot/134/11.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
<p><a class="reference external" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external" href="https://github.com/OCA/partner-contact/tree/13.0/partner_contact_lang"><img alt="OCA/partner-contact" src="https://img.shields.io/badge/github-OCA%2Fpartner--contact-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/partner-contact-13-0/partner-contact-13-0-partner_contact_lang"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external" href="https://runbot.odoo-community.org/runbot/134/13.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
<p>Odoo by default propagate language field to the created contacts from their
form, but it doesn’t allow to change it once created.</p>
<p>This module fills this gap, and also provides other facilities for the
@ -375,7 +375,10 @@ contact language management:</p>
<p>#. Put the language of the parent company when the contact doesn’t have a
language and this parent company is assigned.
#. When the company changes the language, it fills with the same language all
the contacts that don’t have any.</p>
the contacts that don’t have any.
#. Show the language in the inner narrowed Contact form and
set the new conctact with a different language if needed.
#. Search and also group contacts by their language.</p>
<p><strong>Table of contents</strong></p>
<div class="contents local topic" id="contents">
<ul class="simple">
@ -401,7 +404,7 @@ the contacts that don’t have any.</p>
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/partner-contact/issues">GitHub Issues</a>.
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
<a class="reference external" href="https://github.com/OCA/partner-contact/issues/new?body=module:%20partner_contact_lang%0Aversion:%2011.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<a class="reference external" href="https://github.com/OCA/partner-contact/issues/new?body=module:%20partner_contact_lang%0Aversion:%2013.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<p>Do not contact contributors directly about support or help with technical issues.</p>
</div>
<div class="section" id="credits">
@ -420,6 +423,7 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
<li>Vicent Cubells</li>
<li>David Vidal</li>
<li>Cristina Martín</li>
<li>Pedro Evaristo Gonzalez Sanchez &lt;<a class="reference external" href="mailto:pedro.gonzalez&#64;pesol.es">pedro.gonzalez&#64;pesol.es</a>&gt;</li>
</ul>
</li>
</ul>
@ -431,7 +435,7 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
<p>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.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/partner-contact/tree/11.0/partner_contact_lang">OCA/partner-contact</a> project on GitHub.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/partner-contact/tree/13.0/partner_contact_lang">OCA/partner-contact</a> project on GitHub.</p>
<p>You are welcome to contribute. To learn how please visit <a class="reference external" href="https://odoo-community.org/page/Contribute">https://odoo-community.org/page/Contribute</a>.</p>
</div>
</div>

2
partner_contact_lang/tests/__init__.py

@ -1,3 +1,3 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from . import test_partner_contact_lang

8
partner_contact_lang/tests/test_partner_contact_lang.py

@ -1,7 +1,7 @@
# Copyright 2016 Tecnativa - Pedro M. Baeza <pedro.baeza@tecnativa.com>
# Copyright 2017 Tecnativa - Vicent Cubells <vicent.cubells@tecnativa.com>
# Copyright 2018 Tecnativa - Cristina Martín
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
from odoo.tests import common
@ -11,9 +11,9 @@ class TestPartnerContactLang(common.SavepointCase):
def setUpClass(cls):
super(TestPartnerContactLang, cls).setUpClass()
cls.ResPartner = cls.env["res.partner"]
cls.partner = cls.ResPartner.create({"name": "Partner test", "lang": "en_US",})
cls.partner = cls.ResPartner.create({"name": "Partner test", "lang": "en_US"})
cls.contact = cls.ResPartner.create(
{"name": "Contact test", "lang": False, "parent_id": cls.partner.id,}
{"name": "Contact test", "lang": False, "parent_id": cls.partner.id}
)
def test_onchange_parent_id(self):
@ -22,7 +22,7 @@ class TestPartnerContactLang(common.SavepointCase):
self.assertIsNone(res)
self.contact.parent_id = self.partner
res = self.contact.onchange_parent_id()
self.assertEqual(res.get("value", {}).get("lang"), "en_US")
self.assertEqual(self.contact.lang, "en_US")
def test_write_parent_lang(self):
"""First empty the field for filling it again afterwards to see if

41
partner_contact_lang/views/res_partner_view.xml

@ -0,0 +1,41 @@
<?xml version="1.0" encoding="utf-8" ?>
<odoo>
<!-- Copyright 2020 Pesol <pedro.gonzalez@pesol.es>
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -->
<record id="view_partner_form" model="ir.ui.view">
<field name="name">view.partner.address.form.extension</field>
<field name="model">res.partner</field>
<field name="priority">100</field>
<field name="inherit_id" ref="base.view_partner_form" />
<field name="arch" type="xml">
<xpath
expr="//field[@name='child_ids']/form/sheet/field[@name='lang']"
position="replace"
>
<field name="active_lang_count" invisible="1" />
<group attrs="{'invisible': [('active_lang_count', '&lt;=', 1)]}">
<group>
<field name="lang" />
</group>
</group>
</xpath>
</field>
</record>
<record id="view_res_partner_filter" model="ir.ui.view">
<field name="name">res.partner.filter.extension</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_res_partner_filter" />
<field name="arch" type="xml">
<xpath expr="//field[@name='parent_id']" position="after">
<field name="lang" />
</xpath>
<xpath expr="//group[@name='group_by']" position="inside">
<filter
name="language"
string="Language"
context="{'group_by' : 'lang'}"
/>
</xpath>
</field>
</record>
</odoo>
Loading…
Cancel
Save