diff --git a/backend/server/main/settings.py b/backend/server/main/settings.py index 35020b8c..71c1525b 100644 --- a/backend/server/main/settings.py +++ b/backend/server/main/settings.py @@ -112,7 +112,7 @@ LANGUAGE_CODE = 'en-us' -TIME_ZONE = 'America/New_York' +TIME_ZONE = 'UTC' USE_I18N = True diff --git a/frontend/src/lib/components/AdventureCard.svelte b/frontend/src/lib/components/AdventureCard.svelte index fe7d41de..191656c9 100644 --- a/frontend/src/lib/components/AdventureCard.svelte +++ b/frontend/src/lib/components/AdventureCard.svelte @@ -198,7 +198,7 @@ {#if adventure.date && adventure.date !== ''}
{new Date(adventure.date).toLocaleDateString('en-US', { timeZone: 'UTC' })}
+{new Date(adventure.date).toLocaleDateString(undefined, { timeZone: 'UTC' })}
{new Date(checklist.date).toLocaleDateString('en-US', { timeZone: 'UTC' })}
+{new Date(checklist.date).toLocaleDateString(undefined, { timeZone: 'UTC' })}
{collection.adventures.length} Adventures
{#if collection.start_date && collection.end_date}- Dates: {new Date(collection.start_date).toLocaleDateString('en-US', { timeZone: 'UTC' })} - {new Date( - collection.end_date - ).toLocaleDateString('en-US', { timeZone: 'UTC' })} + Dates: {new Date(collection.start_date).toLocaleDateString(undefined, { timeZone: 'UTC' })} - + {new Date(collection.end_date).toLocaleDateString(undefined, { timeZone: 'UTC' })}
diff --git a/frontend/src/lib/components/NoteCard.svelte b/frontend/src/lib/components/NoteCard.svelte index 71a8ea40..863ea4d1 100644 --- a/frontend/src/lib/components/NoteCard.svelte +++ b/frontend/src/lib/components/NoteCard.svelte @@ -45,7 +45,7 @@ {#if note.date && note.date !== ''}
{new Date(note.date).toLocaleDateString('en-US', { timeZone: 'UTC' })}
+{new Date(note.date).toLocaleDateString(undefined, { timeZone: 'UTC' })}
{adventure.date - ? new Date(adventure.date).toLocaleDateString('en-US', { + ? new Date(adventure.date).toLocaleDateString(undefined, { timeZone: 'UTC' }) : ''} diff --git a/frontend/src/routes/collections/[id]/+page.svelte b/frontend/src/routes/collections/[id]/+page.svelte index 3f8cb864..ce2b3cae 100644 --- a/frontend/src/routes/collections/[id]/+page.svelte +++ b/frontend/src/routes/collections/[id]/+page.svelte @@ -510,9 +510,9 @@
Duration: {numberOfDays} days
{/if}- Dates: {new Date(collection.start_date).toLocaleDateString('en-US', { timeZone: 'UTC' })} - {new Date( + Dates: {new Date(collection.start_date).toLocaleDateString(undefined, { timeZone: 'UTC' })} - {new Date( collection.end_date - ).toLocaleDateString('en-US', { timeZone: 'UTC' })} + ).toLocaleDateString(undefined, { timeZone: 'UTC' })}
{#each Array(numberOfDays) as _, i} @@ -539,7 +539,7 @@ )[dateString]}{adventure.date - ? new Date(adventure.date).toLocaleDateString('en-US', { timeZone: 'UTC' }) + ? new Date(adventure.date).toLocaleDateString(undefined, { timeZone: 'UTC' }) : ''}
diff --git a/frontend/src/routes/profile/+page.svelte b/frontend/src/routes/profile/+page.svelte index 44472b13..4265d7fc 100644 --- a/frontend/src/routes/profile/+page.svelte +++ b/frontend/src/routes/profile/+page.svelte @@ -50,7 +50,9 @@Member Since
{new Date(data.user.date_joined).toLocaleDateString()}
++ {new Date(data.user.date_joined).toLocaleDateString(undefined, { timeZone: 'UTC' })} +