Skip to content

Commit

Permalink
Fix timezone difference issue not showing some meetings happening on …
Browse files Browse the repository at this point in the history
…today
  • Loading branch information
Abradat committed Sep 16, 2024
1 parent 5156fcd commit c0ff763
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,9 @@ export class ApplicationDecisionMeetingService {
.addSelect(
`
CASE
WHEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE) THEN meeting.date END) is NOT NULL
THEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE) THEN meeting.date END)
ELSE MAX(CASE WHEN meeting.date < (CURRENT_DATE) THEN meeting.date END)
WHEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END) is NOT NULL
THEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END)
ELSE MAX(CASE WHEN meeting.date < (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END)
END
`,
'next_meeting',
Expand All @@ -159,9 +159,9 @@ export class ApplicationDecisionMeetingService {
.addSelect(
`
CASE
WHEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE) THEN meeting.date END) is NOT NULL
THEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE) THEN meeting.date END)
ELSE MAX(CASE WHEN meeting.date < (CURRENT_DATE) THEN meeting.date END)
WHEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END) is NOT NULL
THEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END)
ELSE MAX(CASE WHEN meeting.date < (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END)
END
`,
'next_meeting',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,9 @@ export class PlanningReviewMeetingService {
.addSelect(
`
CASE
WHEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE) THEN meeting.date END) is NOT NULL
THEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE) THEN meeting.date END)
ELSE MAX(CASE WHEN meeting.date < (CURRENT_DATE) THEN meeting.date END)
WHEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END) is NOT NULL
THEN MIN(CASE WHEN meeting.date >= (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END)
ELSE MAX(CASE WHEN meeting.date < (CURRENT_DATE AT TIME ZONE \'America/Vancouver\') THEN meeting.date END)
END
`,
'next_meeting',
Expand Down

0 comments on commit c0ff763

Please sign in to comment.