Files
suite/hr_timesheet_work_entry/__init__.py
2024-10-24 10:43:22 +00:00

16 lines
489 B
Python

from . import models
def ts_work_type_pre_init_hook(env):
"""
This module installs a Work Entry Type with code "TS"
If you have undergone a migration (either for this module
or even your own Payslip Work Entry lines with code "TS")
then the uniqueness constraint will prevent this module
from installing.
"""
env.cr.execute("UPDATE hr_work_entry_type "
"SET code = 'TS-PRE-INSTALL-14' "
"WHERE code = 'TS';"
)