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

[FIX] hr_employee_firstname: translate name order config value #1385

Open
wants to merge 1 commit into
base: 16.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 32 additions & 20 deletions hr_employee_firstname/i18n/fr.po
Original file line number Diff line number Diff line change
@@ -1,23 +1,19 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * hr_employee_firstname
# * hr_employee_firstname
#
# Translators:
# OCA Transbot <[email protected]>, 2017
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 10.0\n"
"Project-Id-Version: Odoo Server 16.0+e\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-01-28 02:12+0000\n"
"PO-Revision-Date: 2024-02-23 10:46+0000\n"
"Last-Translator: Vincent Hatakeyama <[email protected]>\n"
"Language-Team: French (https://www.transifex.com/oca/teams/23907/fr/)\n"
"Language: fr\n"
"POT-Creation-Date: 2024-08-01 10:13+0000\n"
"PO-Revision-Date: 2024-08-01 10:13+0000\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: nplurals=2; plural=n > 1;\n"
"X-Generator: Weblate 4.17\n"
"Plural-Forms: \n"

#. module: hr_employee_firstname
#: model:ir.model,name:hr_employee_firstname.model_hr_employee_base
Expand All @@ -44,30 +40,46 @@ msgstr "Ordre des noms d’employé"
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee__firstname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee_base__firstname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee_public__firstname
msgid "First name"
msgid "Firstname"
msgstr "Prénom"

#. module: hr_employee_firstname
#. odoo-python
#: code:addons/hr_employee_firstname/models/base_config_settings.py:0
#, python-format
msgid "Firstname Lastname"
msgstr "Prénom, Nom"

#. module: hr_employee_firstname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee__lastname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee_base__lastname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee_public__lastname
msgid "Last name"
msgid "Lastname"
msgstr "Nom"

#. module: hr_employee_firstname
#. odoo-python
#: code:addons/hr_employee_firstname/models/base_config_settings.py:0
#, python-format
msgid "Lastname Firstname"
msgstr "Nom Prénom"

#. module: hr_employee_firstname
#. odoo-python
#: code:addons/hr_employee_firstname/models/base_config_settings.py:0
#, python-format
msgid "Lastname, Firstname"
msgstr "Nom, Prénom"

#. module: hr_employee_firstname
#. odoo-python
#: code:addons/hr_employee_firstname/models/hr_employee.py:0
#: code:addons/hr_employee_firstname/models/hr_employee.py:0
#, python-format
msgid "No name set."
msgstr "Aucun nom défini."

#. module: hr_employee_firstname
#: model:ir.model.fields,help:hr_employee_firstname.field_res_config_settings__employee_names_order
msgid "Order to compose employee fullname"
msgstr "Règle de composition des noms complets des employés"

#~ msgid "Firstname"
#~ msgstr "Prénom"

#~ msgid "Lastname"
#~ msgstr "Nom"
msgstr "Règle de composition des noms complets des employés"
31 changes: 27 additions & 4 deletions hr_employee_firstname/i18n/hr_employee_firstname.pot
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Project-Id-Version: Odoo Server 16.0+e\n"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Avoid these changes because they will be reverted by the bot anyway.

I'd suggest modifying just the Python code or in fault modifying also the .pot file but only terms related to your change.

Copy link
Author

@benwillig benwillig Aug 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Won't weblate override it anyway and do a msgmerge with the new translations from the .po ? I needed the translations now but yes I can remove theses changes if needed

"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-08-01 10:14+0000\n"
"PO-Revision-Date: 2024-08-01 10:14+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
Expand Down Expand Up @@ -38,14 +40,35 @@ msgstr ""
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee__firstname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee_base__firstname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee_public__firstname
msgid "First name"
msgid "Firstname"
msgstr ""

#. module: hr_employee_firstname
#. odoo-python
#: code:addons/hr_employee_firstname/models/base_config_settings.py:0
#, python-format
msgid "Firstname Lastname"
msgstr ""

#. module: hr_employee_firstname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee__lastname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee_base__lastname
#: model:ir.model.fields,field_description:hr_employee_firstname.field_hr_employee_public__lastname
msgid "Last name"
msgid "Lastname"
msgstr ""

#. module: hr_employee_firstname
#. odoo-python
#: code:addons/hr_employee_firstname/models/base_config_settings.py:0
#, python-format
msgid "Lastname Firstname"
msgstr ""

#. module: hr_employee_firstname
#. odoo-python
#: code:addons/hr_employee_firstname/models/base_config_settings.py:0
#, python-format
msgid "Lastname, Firstname"
msgstr ""

#. module: hr_employee_firstname
Expand All @@ -59,4 +82,4 @@ msgstr ""
#. module: hr_employee_firstname
#: model:ir.model.fields,help:hr_employee_firstname.field_res_config_settings__employee_names_order
msgid "Order to compose employee fullname"
msgstr ""
msgstr ""
8 changes: 4 additions & 4 deletions hr_employee_firstname/models/base_config_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

import logging

from odoo import fields, models
from odoo import _, fields, models

_logger = logging.getLogger(__name__)

Expand All @@ -21,9 +21,9 @@ class ResConfigSettings(models.TransientModel):

def _employee_names_order_selection(self):
return [
("last_first", "Lastname Firstname"),
("last_first_comma", "Lastname, Firstname"),
("first_last", "Firstname Lastname"),
("last_first", _("Lastname Firstname")),
("last_first_comma", _("Lastname, Firstname")),
("first_last", _("Firstname Lastname")),
]

def _employee_names_order_default(self):
Expand Down
Loading