[FIX] hr_timesheet: fix the traceback when group by date
Description of the issue/feature this PR addresses: When selecting the "group by date" option in the timesheet portal view, a traceback error occurs. Fix: This PR addresses the traceback error by improving the handling of recordsets when grouping by date. task:3468392 closes odoo/odoo#145854 X-original-commit: f244a0685ceeff24edd4b6ab4a2213298dbf8621 Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
This commit is contained in:
committed by
Xavier Bol (xbo)
parent
5f22eed49c
commit
dcac8730f9
@@ -138,7 +138,7 @@ class TimesheetCustomerPortal(CustomerPortal):
|
||||
if field:
|
||||
if groupby == 'date':
|
||||
raw_timesheets_group = Timesheet_sudo._read_group(
|
||||
domain, ['date:day'], ['unit_amount:sum', 'id:array_agg']
|
||||
domain, ['date:day'], ['unit_amount:sum', 'id:recordset']
|
||||
)
|
||||
grouped_timesheets = [(records, unit_amount) for __, unit_amount, records in raw_timesheets_group]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user