Imposed holidays days

hr_holidays_imposed_days
REPOSITORY
REPOSITORYOCA/hr
GIT
GIThttps://github.com/OCA/hr.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/hr/tree/11.0/hr_holidays_imposed_days
VERSION
VERSION 1.0.0
CATEGORY
CATEGORYHuman Resources
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Camptocamp SA
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Camptocamp SA
COMMITTERS
COMMITTERSAndrea, OCA Transbot, oca-travis, OCA-git-bot
WEBSITE
WEBSITEhttps://github.com/OCA/hr
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:23:58
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - hr_holidays
    - hr
    - base_setup
    - base
    - web
    - mail
    - bus
    - web_tour
    - resource
    - calendar
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (2)
XML IDNameModelTypeStatus
hr_holidays_imposed_view_form hr.holidays.imposed form New
hr_holidays_imposed_view_tree hr.holidays.imposed tree New
Models touched (2)

New fields (0)

No new fields.

Public methods (1)
  • create(self, values)
    @api.model
    add imposed days if a configuration exists

New fields (8)
  • auto_confirm Boolean
  • company_id Many2one → res.company
    default=<expr> string='Company' args: 'res.company'
  • date_from Datetime
    required=True
  • date_to Datetime
    required=True
  • employee_ids Many2many → hr.employee
    help='If empty, all employees of the company will have this day/period imposed' args: 'hr.employee'
  • name Char
    required=True
  • number_of_days Float
  • status_id Many2one → hr.holidays.status
    required=True string='Leave type' args: 'hr.holidays.status'
Public methods (3)
  • compute_nb_days(self, diff)
    @classmethod
  • onchange_dates(self)
    @api.onchange('date_from', 'date_to')
    If there are no date set for date_to, automatically set one HOURS_PER_DAY later than the date_from. Also update the number_of_days.
  • validate(self)
    @api.multi
REPOSITORY
REPOSITORYOCA/hr
GIT
GIThttps://github.com/OCA/hr.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/hr/tree/10.0/hr_holidays_imposed_days
VERSION
VERSION 1.0.1
CATEGORY
CATEGORYHuman Resources
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Camptocamp SA
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Camptocamp SA
COMMITTERS
COMMITTERSGitHub, OCA Transbot, Denis Leemann, oca-travis, Weblate, OCA-git-bot, Iryna Vyshnevska, François Honoré, Nikul Chaudhary
WEBSITE
WEBSITEhttp://www.camptocamp.com
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:19:58
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - hr_holidays
    - hr
    - base_setup
    - base
    - web_kanban
    - web
    - mail
    - bus
    - web_tour
    - resource
    - calendar
    - base_action_rule
    - web_calendar
    - product
    - decimal_precision
    - report
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (2)
XML IDNameModelTypeStatus
hr_holidays_imposed_view_form hr.holidays.imposed.view.form hr.holidays.imposed form New
hr_holidays_imposed_view_tree hr.holidays.imposed.view.tree hr.holidays.imposed tree New
Models touched (2)

New fields (0)

No new fields.

Public methods (1)
  • create(self, values)
    @api.model@api.returns('self', <expr>)
    add imposed days if a configuration exists

New fields (8)
  • auto_confirm Boolean
  • company_id Many2one → res.company
    comodel_name='res.company' default=<expr> string='Company'
  • date_from Datetime
    required=True
  • date_to Datetime
    required=True
  • employee_ids Many2many → hr.employee
    comodel_name='hr.employee' help='If empty, all employees of the company will have this day/period imposed'
  • name Char
    required=True
  • number_of_days Float
  • status_id Many2one → hr.holidays.status
    comodel_name='hr.holidays.status' required=True string='Leave type'
Public methods (3)
  • compute_nb_days(self, diff)
  • onchange_dates(self)
    @api.onchange('date_from', 'date_to')
    If there are no date set for date_to, automatically set one 8 hours later than the date_from. Also update the number_of_days.
  • validate(self)
    @api.multi