Skip to content
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
104 changes: 104 additions & 0 deletions l10n_jp_hr_employee_name_kana/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
.. image:: https://odoo-community.org/readme-banner-image
:target: https://odoo-community.org/get-involved?utm_source=readme
:alt: Odoo Community Association

===========================
Japanese Employee Kana Name
===========================

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

.. |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/license-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%2Fl10n--japan-lightgray.png?logo=github
:target: https://github.com/OCA/l10n-japan/tree/19.0/l10n_jp_hr_employee_name_kana
:alt: OCA/l10n-japan
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/l10n-japan-19-0/l10n-japan-19-0-l10n_jp_hr_employee_name_kana
: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/l10n-japan&target_branch=19.0
:alt: Try me on Runboat

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

Adds a normalized kana reading to employees. The reading is also exposed
on the public employee model so internal users can search the employee
directory by pronunciation.

**Table of contents**

.. contents::
:local:

Usage
=====

Enter the phonetic reading in **Name (Kana)** on the employee. It is
also exposed on the public employee record, so users without HR access
can find colleagues by pronunciation.

Employees follow the kana format configured in **Japanese Kana Name**.
To keep employee furigana in hiragana while contacts and products stay
in katakana, set the ``l10n_jp_name_kana.format.hr.employee`` system
parameter — see that module's usage notes.

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

Bugs are tracked on `GitHub Issues <https://github.com/OCA/l10n-japan/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/l10n-japan/issues/new?body=module:%20l10n_jp_hr_employee_name_kana%0Aversion:%2019.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
-------

* Quartile

Contributors
------------

- `Quartile <https://www.quartile.co>`__:

- Aung Ko Ko Lin

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.

.. |maintainer-AungKoKoLin1997| image:: https://github.com/AungKoKoLin1997.png?size=40px
:target: https://github.com/AungKoKoLin1997
:alt: AungKoKoLin1997

Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-AungKoKoLin1997|

This module is part of the `OCA/l10n-japan <https://github.com/OCA/l10n-japan/tree/19.0/l10n_jp_hr_employee_name_kana>`_ 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 l10n_jp_hr_employee_name_kana/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
17 changes: 17 additions & 0 deletions l10n_jp_hr_employee_name_kana/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Copyright 2026 Quartile (https://www.quartile.co)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).

{
"name": "Japanese Employee Kana Name",
"summary": "Add a normalized kana name to employees",
"version": "19.0.1.0.0",
"category": "Localization/Japan",
"author": "Quartile, Odoo Community Association (OCA)",
"maintainers": ["AungKoKoLin1997"],
"website": "https://github.com/OCA/l10n-japan",
"license": "AGPL-3",
"depends": ["hr", "l10n_jp_name_kana"],
"data": ["views/hr_employee_views.xml"],
"auto_install": True,
"installable": True,
}
2 changes: 2 additions & 0 deletions l10n_jp_hr_employee_name_kana/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
from . import hr_employee
from . import hr_employee_public
9 changes: 9 additions & 0 deletions l10n_jp_hr_employee_name_kana/models/hr_employee.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Copyright 2026 Quartile (https://www.quartile.co)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).

from odoo import models


class HrEmployee(models.Model):
_name = "hr.employee"
_inherit = ["hr.employee", "name.kana.mixin"]
22 changes: 22 additions & 0 deletions l10n_jp_hr_employee_name_kana/models/hr_employee_public.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Copyright 2026 Quartile (https://www.quartile.co)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).

from odoo import api, fields, models


class HrEmployeePublic(models.Model):
_name = "hr.employee.public"
_inherit = ["hr.employee.public", "name.kana.mixin"]

name_kana = fields.Char(readonly=True)

@api.model
def _get_kana_format(self):
"""Follow the employee setting rather than resolving one of our own.

This model is a read-only SQL view: the reading it exposes is the one
stored on hr.employee, so a search term has to be normalized to that
format. A setting of its own could disagree, and searching the employee
directory would then match nothing.
"""
return self.env["hr.employee"]._get_kana_format()
3 changes: 3 additions & 0 deletions l10n_jp_hr_employee_name_kana/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[build-system]
requires = ["whool"]
build-backend = "whool.buildapi"
2 changes: 2 additions & 0 deletions l10n_jp_hr_employee_name_kana/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- [Quartile](https://www.quartile.co):
- Aung Ko Ko Lin
3 changes: 3 additions & 0 deletions l10n_jp_hr_employee_name_kana/readme/DESCRIPTION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Adds a normalized kana reading to employees. The reading is also exposed on
the public employee model so internal users can search the employee directory
by pronunciation.
8 changes: 8 additions & 0 deletions l10n_jp_hr_employee_name_kana/readme/USAGE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
Enter the phonetic reading in **Name (Kana)** on the employee. It is also
exposed on the public employee record, so users without HR access can find
colleagues by pronunciation.

Employees follow the kana format configured in **Japanese Kana Name**. To keep
employee furigana in hiragana while contacts and products stay in katakana, set
the `l10n_jp_name_kana.format.hr.employee` system parameter — see that module's
usage notes.
Loading
Loading