oca-hr/odoo-bringout-oca-hr-holidays-hr_holidays_public/hr_holidays_public/models/res_users.py
Ernad Husremovic dfcda4100c Move all OCA HR modules from oca-technical to dedicated oca-hr submodule
Reorganized 67 HR-related modules for better structure:
- Moved all odoo-bringout-oca-hr-* packages from packages/oca-technical/
- Now organized in dedicated packages/oca-hr/ submodule
- Includes attendance, expense, holiday, employee, and contract modules
- Maintains all module functionality while improving project organization

This creates a cleaner separation between general technical modules
and HR-specific functionality.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-30 17:11:28 +02:00

18 lines
547 B
Python

# Copyright 2025 Tecnativa - Víctor Martínez
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from odoo import models
class User(models.Model):
_inherit = "res.users"
def _compute_im_status(self):
res = super()._compute_im_status()
for user in self.filtered(
lambda x: x.employee_id.is_public_holiday and "leave_" not in x.im_status
):
user.im_status = user.employee_id._get_im_status_hr_holidays_public(
user.im_status
)
return res