From 6d3c187e89396965180724426dcf91fd1f1b35af Mon Sep 17 00:00:00 2001 From: Elouan Le Bars Date: Wed, 8 Jan 2020 17:12:50 +0100 Subject: [PATCH] [IMP] b_shift : attendance sheet validation wizard Temporary changes can be saved. Warnings added and modified. --- beesdoo_shift/models/attendance_sheet.py | 2 +- beesdoo_shift/views/attendance_sheet.xml | 3 + .../wizard/validate_attendance_sheet.py | 100 ++++++++++++------ .../wizard/validate_attendance_sheet.xml | 21 ++-- 4 files changed, 84 insertions(+), 42 deletions(-) diff --git a/beesdoo_shift/models/attendance_sheet.py b/beesdoo_shift/models/attendance_sheet.py index 8239343..9f3f108 100644 --- a/beesdoo_shift/models/attendance_sheet.py +++ b/beesdoo_shift/models/attendance_sheet.py @@ -545,7 +545,7 @@ class AttendanceSheet(models.Model): % expected_shift.worker_id.name ) - # open a validation wizard if not admin + # Open a validation wizard only if not admin if self.env.user.has_group("beesdoo_shift.group_cooperative_admin"): self._validate(self.env.user.partner_id) return diff --git a/beesdoo_shift/views/attendance_sheet.xml b/beesdoo_shift/views/attendance_sheet.xml index 2900323..579b076 100644 --- a/beesdoo_shift/views/attendance_sheet.xml +++ b/beesdoo_shift/views/attendance_sheet.xml @@ -136,6 +136,9 @@