diff --git a/advance_hr_attendance_dashboard/doc/RELEASE_NOTES.md b/advance_hr_attendance_dashboard/doc/RELEASE_NOTES.md index 50c5be1c2..5291f99b7 100644 --- a/advance_hr_attendance_dashboard/doc/RELEASE_NOTES.md +++ b/advance_hr_attendance_dashboard/doc/RELEASE_NOTES.md @@ -10,3 +10,8 @@ #### Version 18.0.1.0.0 #### Bug fixes - Resolved the style issue of the related products + +#### 31.07.2025 +#### Version 18.0.1.0.0 +#### Bug fixes + - Fixed by handling both comma and dash separators in the cids cookie. diff --git a/advance_hr_attendance_dashboard/models/hr_employee.py b/advance_hr_attendance_dashboard/models/hr_employee.py index 5c81daaad..6dc39e093 100644 --- a/advance_hr_attendance_dashboard/models/hr_employee.py +++ b/advance_hr_attendance_dashboard/models/hr_employee.py @@ -17,6 +17,8 @@ # You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE # (AGPL v3) along with this program. ############################################################################### +import re + import pandas from datetime import date, timedelta from odoo import api, fields, models @@ -57,8 +59,10 @@ class HrEmployee(models.Model): elif option == 'last_15_days': dates = [str(date.today() - timedelta(days=day)) for day in range(15)] - cids = request.httprequest.cookies.get('cids') - allowed_company_ids = [int(cid) for cid in cids.split(',')] + + cids = request.httprequest.cookies.get('cids', '') + split_cids = re.split(r'[,-]', cids) + allowed_company_ids = [int(cid) for cid in split_cids if cid.isdigit()] for employee in self.env['hr.employee'].search( [('company_id', '=', allowed_company_ids)]): leave_data = [] diff --git a/advance_hr_attendance_dashboard/static/description/index.html b/advance_hr_attendance_dashboard/static/description/index.html index 7a074994b..8dfc57c44 100644 --- a/advance_hr_attendance_dashboard/static/description/index.html +++ b/advance_hr_attendance_dashboard/static/description/index.html @@ -865,6 +865,37 @@ Set Default Present Mark For Present And Default Absent Mark For Absent From Con + +
+
+

+ Latest Release 18.0.1.0.0 +

+ + 31th July, 2025 + +
+
+
+
+
+ Updt +
+
+
+
    +
  • + Fixed by handling both comma and dash separators in the cids cookie. +
  • + +
+
+
+
+
+
+