From c6ff1034a75fc93a65fcfe3ab69ad70fd72d41c4 Mon Sep 17 00:00:00 2001 From: Gurupreet Singh Date: Wed, 15 Feb 2023 12:38:32 +0000 Subject: [PATCH] [FIX] project: fix groupby by none issue in project sharing Steps: - Go to portal and select tasks and search anything in search bar. - Showing no tasks available - choose group by none and search anything it will show table labels. Fix: shows warning when there is no record when groupby by none. task-3183771 closes odoo/odoo#128560 X-original-commit: 1d858798f53d56e5b81cc9df0fa70113dedd4f50 Signed-off-by: Xavier Bol (xbo) --- addons/project/controllers/portal.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/project/controllers/portal.py b/addons/project/controllers/portal.py index 97e4793dd80..2910ac63e9e 100644 --- a/addons/project/controllers/portal.py +++ b/addons/project/controllers/portal.py @@ -428,7 +428,7 @@ class ProjectCustomerPortal(CustomerPortal): else: grouped_tasks = [Task_sudo.concat(*g) for k, g in groupbyelem(tasks, itemgetter(group))] else: - grouped_tasks = [tasks] + grouped_tasks = [tasks] if tasks else [] task_states = dict(Task_sudo._fields['state']._description_selection(request.env))