[IMP] hr_holidays: move security check in separated method.
[IMP] hr_holidays: move security check in separated method.

Closes #16792
Closes #16491
opw-740246

ygol/odoo,ygol/odoo,ygol/odoo,ygol/odoo,ygol/odoo,ygol/odoo,ygol/odoo