add hr_timesheet_sheet_no_review, hr_timesheet_sheet_holidays, hr_timesheet_sheet_delete_cascade

This commit is contained in:
Luis 2026-09-22 10:58:36 +02:00
parent b07082f70d
commit 8b0d0bb6cc
53 changed files with 3953 additions and 0 deletions

View file

@ -0,0 +1,21 @@
# Copyright 2026 Criptomart
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from odoo import api, models
class Sheet(models.Model):
_inherit = "hr_timesheet.sheet"
def _with_sheet_recompute(self):
"""Hook for extensions"""
token = self.env["account.analytic.line"]._sheet_recompute_token()
return self.with_context(sheet_recompute=token)
@api.model_create_multi
def create(self, vals_list):
sheets = super(Sheet, self._with_sheet_recompute()).create(vals_list)
return sheets.with_env(self.env)
def write(self, vals):
return super(Sheet, self._with_sheet_recompute()).write(vals)