From 56fbb3fdc0478d9dcc1d181e1038f9a5e8a07fd3 Mon Sep 17 00:00:00 2001 From: rdbsolutions Date: Wed, 22 May 2024 10:41:29 +0100 Subject: [PATCH] fixed page flow from submission of questionnaire --- .../representation/representationComplete.js | 2 +- .../representationCompleteSubmit.js | 48 ++++++++++++++----- 2 files changed, 36 insertions(+), 14 deletions(-) diff --git a/components/case/representation/representationComplete.js b/components/case/representation/representationComplete.js index 3ec645de..111d59b6 100644 --- a/components/case/representation/representationComplete.js +++ b/components/case/representation/representationComplete.js @@ -69,7 +69,7 @@ const RepComplete = (props) => {
setRepresentationReset()} className="govuk-button" > diff --git a/components/case/representation/representationCompleteSubmit.js b/components/case/representation/representationCompleteSubmit.js index 8a7efb80..13b3793b 100644 --- a/components/case/representation/representationCompleteSubmit.js +++ b/components/case/representation/representationCompleteSubmit.js @@ -5,6 +5,7 @@ import { useDropzone } from "react-dropzone"; import RepComplete from "./representationComplete"; import RepLPAQuestionnaireCheck_s78 from "./representationQuestionnairesCheck/representationLPAQuestionnaireCheck_s78"; import RepLPAQuestionnaireCheck_enforcement from "./representationQuestionnairesCheck/representationLPAQuestionnaireCheck_enforcement"; +import { useState, useEffect } from "react"; import { getFormCollectionByID, @@ -35,6 +36,8 @@ const RepCompleteSubmit = (props) => { )); + const [confirmSections, setConfirmSections] = useState(false); + const repFormData = formObj.representationForm.values; // const repDate = new Date(); @@ -364,15 +367,31 @@ const RepCompleteSubmit = (props) => {

- +
+
+ { + setConfirmSections( + !confirmSections + ); + }} + /> + +
+
+ {/* {