diff --git a/addons/hr_timesheet_attendance/__manifest__.py b/addons/hr_timesheet_attendance/__manifest__.py index 82aa866ef42..4a1f3c1114a 100644 --- a/addons/hr_timesheet_attendance/__manifest__.py +++ b/addons/hr_timesheet_attendance/__manifest__.py @@ -7,7 +7,7 @@ Module linking the attendance module to the timesheet app. """, 'category': 'Hidden', - 'version': '1.0', + 'version': '1.1', 'depends': ['hr_timesheet', 'hr_attendance'], 'data': [ diff --git a/addons/hr_timesheet_attendance/security/hr_timesheet_attendance_report_security.xml b/addons/hr_timesheet_attendance/security/hr_timesheet_attendance_report_security.xml index 19ef67d512e..ced1decaec9 100644 --- a/addons/hr_timesheet_attendance/security/hr_timesheet_attendance_report_security.xml +++ b/addons/hr_timesheet_attendance/security/hr_timesheet_attendance_report_security.xml @@ -16,12 +16,7 @@ Timesheet attendance Report: Approver - [ - ('project_id', '!=', False), - '|', - ('project_id.privacy_visibility', '!=', 'followers'), - ('project_id.message_partner_ids', 'in', [user.partner_id.id]) - ] + [(1, '=', 1)] diff --git a/addons/hr_timesheet_attendance/upgrades/1.1/pre-migrate.py b/addons/hr_timesheet_attendance/upgrades/1.1/pre-migrate.py new file mode 100644 index 00000000000..4612246b41c --- /dev/null +++ b/addons/hr_timesheet_attendance/upgrades/1.1/pre-migrate.py @@ -0,0 +1,14 @@ +# -*- coding: utf-8 -*- +# Part of Odoo. See LICENSE file for full copyright and licensing details. + + +def migrate(cr, version): + cr.execute(""" + UPDATE ir_rule r + SET domain_force = '[(1, "=", 1)]' + FROM ir_model_data d + WHERE d.res_id = r.id + AND d.model = 'ir.rule' + AND d.module = 'hr_timesheet_attendance' + AND d.name = 'hr_timesheet_attendance_report_rule_approver' + """)