19.0 vanilla

This commit is contained in:
Ernad Husremovic 2026-03-09 09:31:00 +01:00
parent a1137a1456
commit e1d89e11e3
2789 changed files with 1093187 additions and 605897 deletions

View file

@ -7,6 +7,16 @@ from odoo import http
class HrHolidaysController(http.Controller):
@http.route('/leave/approve', type='http', auth='user', methods=['GET'])
def hr_holidays_request_approve(self, res_id, token):
comparison, record, redirect = MailController._check_token_and_record_or_redirect('hr.leave', int(res_id), token)
if comparison and record:
try:
record.action_approve()
except Exception:
return MailController._redirect_to_generic_fallback('hr.leave', res_id)
return redirect
@http.route('/leave/validate', type='http', auth='user', methods=['GET'])
def hr_holidays_request_validate(self, res_id, token):
comparison, record, redirect = MailController._check_token_and_record_or_redirect('hr.leave', int(res_id), token)