From 4835ba449324517cdcf5bd9a7a20efdaed092859 Mon Sep 17 00:00:00 2001 From: joshunrau Date: Thu, 5 Feb 2026 16:16:06 -0500 Subject: [PATCH 1/4] fix issue where retrospective session date is not recorded --- apps/web/src/routes/_app/instruments/render/$id.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/web/src/routes/_app/instruments/render/$id.tsx b/apps/web/src/routes/_app/instruments/render/$id.tsx index 03e88c70e..a642d6f42 100644 --- a/apps/web/src/routes/_app/instruments/render/$id.tsx +++ b/apps/web/src/routes/_app/instruments/render/$id.tsx @@ -38,7 +38,7 @@ const RouteComponent = () => { const handleSubmit: InstrumentSubmitHandler = async ({ data, instrumentId }) => { await axios.post('/v1/instrument-records', { data, - date: new Date(), + date: currentSession!.date, groupId: currentGroup?.id, instrumentId, sessionId: currentSession!.id, From 5a6fdd55c20544e314a7abbba49afb7371943926 Mon Sep 17 00:00:00 2001 From: joshunrau Date: Thu, 5 Feb 2026 16:16:24 -0500 Subject: [PATCH 2/4] increment version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index f64af8d41..34237a443 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "opendatacapture", "type": "module", - "version": "1.12.4", + "version": "1.13.0", "private": true, "packageManager": "pnpm@10.7.0", "license": "Apache-2.0", From 05f2b0cd8a6e7db4a3581029e58973407341ee2c Mon Sep 17 00:00:00 2001 From: joshunrau Date: Thu, 5 Feb 2026 16:21:04 -0500 Subject: [PATCH 3/4] fix issue with session modal not automatically closing --- apps/web/src/components/Sidebar/Sidebar.tsx | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/apps/web/src/components/Sidebar/Sidebar.tsx b/apps/web/src/components/Sidebar/Sidebar.tsx index 49cb61970..f74a5e33b 100644 --- a/apps/web/src/components/Sidebar/Sidebar.tsx +++ b/apps/web/src/components/Sidebar/Sidebar.tsx @@ -1,3 +1,5 @@ +import { useState } from 'react'; + import { toBasicISOString, toLowerCase } from '@douglasneuroinformatics/libjs'; import { Button, Dialog, LanguageToggle, ThemeToggle } from '@douglasneuroinformatics/libui/components'; import { useTranslation } from '@douglasneuroinformatics/libui/hooks'; @@ -14,6 +16,8 @@ import { NavButton } from '../NavButton'; import { UserDropup } from '../UserDropup'; export const Sidebar = () => { + const [isEndSessionModalOpen, setIsEndSessionModalOpen] = useState(false); + const navItems = useNavItems(); const currentSession = useAppStore((store) => store.currentSession); const endSession = useAppStore((store) => store.endSession); @@ -43,7 +47,7 @@ export const Sidebar = () => { /> ))} {i === navItems.length - 1 && ( - + { className="min-w-20" onClick={() => { endSession(); - void navigate({ to: '/session/start-session' }); + void navigate({ to: '/session/start-session' }).then(() => { + setIsEndSessionModalOpen(false); + }); }} > {t('core.yes')} - From b95d74787ae02cbf59ee87cb9c204171a38988c7 Mon Sep 17 00:00:00 2001 From: joshunrau Date: Thu, 5 Feb 2026 16:36:20 -0500 Subject: [PATCH 4/4] adjust start session styles --- .../src/routes/_app/session/start-session.tsx | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/apps/web/src/routes/_app/session/start-session.tsx b/apps/web/src/routes/_app/session/start-session.tsx index 485ea8053..f06869076 100644 --- a/apps/web/src/routes/_app/session/start-session.tsx +++ b/apps/web/src/routes/_app/session/start-session.tsx @@ -60,24 +60,24 @@ const RouteComponent = () => {
- {currentSession !== null && ( - -
- -

- {t({ - en: 'The current session must be ended before starting the form again.', - fr: 'La session en cours doit être terminée avant de recommencer le formulaire.' - })} -

-
-
- )} + + +
+ {t({ en: 'Session Successfully Started', fr: 'Session démarrée avec succès' })} +
+

+ {t({ + en: 'Please note that you must end the current session before completing this form again.', + fr: 'Veuillez noter que vous devez mettre fin à la session en cours avant de remplir à nouveau ce formulaire.' + })} +

+
)}