diff --git a/client/apps/Planning/PlanningList.tsx b/client/apps/Planning/PlanningList.tsx index e7a0b3423..331bc6db2 100644 --- a/client/apps/Planning/PlanningList.tsx +++ b/client/apps/Planning/PlanningList.tsx @@ -186,16 +186,14 @@ export class PlanningListComponent extends React.PureComponent { { - const dateFilter = currentSearch.advancedSearch?.dates?.start?.toDate() - ?? new Date(); + const dateFilter = currentSearch.advancedSearch?.dates?.start?.toDate() ?? new Date(); - dateFilter.setHours(0, 0, 0, 0); + dateFilter.setUTCHours(0, 0, 0, 0); // group date is UTC 00:00:00 return groups.filter((group) => { - const dateStringToJSDate = new Date(group.date); + const groupDate = new Date(group.date); - dateStringToJSDate.setHours(0, 0, 0, 0); - return dateStringToJSDate >= dateFilter; + return groupDate >= dateFilter; }); })()} onItemClick={openPreview}