From 159854d503ca7f8fe50e9fa5b0814a72a0fe5f1e Mon Sep 17 00:00:00 2001 From: Chibuisi Enyia Date: Tue, 15 Oct 2024 14:54:20 -0500 Subject: [PATCH] Ccap 411 submit provider response (#687) --- src/main/resources/application.yaml | 2 + src/main/resources/flows-config.yaml | 9 ++++ src/main/resources/messages.properties | 12 +++++- .../templates/gcc/submit-sign-name.html | 3 +- .../providerresponse/info-review.html | 29 +++++++++++++ .../submit-complete-final.html | 43 +++++++++++++++++++ .../ProviderresponseFlowJourneyTest.java | 19 ++++++-- 7 files changed, 112 insertions(+), 5 deletions(-) create mode 100644 src/main/resources/templates/providerresponse/info-review.html create mode 100644 src/main/resources/templates/providerresponse/submit-complete-final.html diff --git a/src/main/resources/application.yaml b/src/main/resources/application.yaml index a22c56335..6ff3fc38b 100644 --- a/src/main/resources/application.yaml +++ b/src/main/resources/application.yaml @@ -3,6 +3,8 @@ form-flow: lock-after-submitted: - flow: gcc redirect: submit-complete + - flow: providerresponse + redirect: submit-complete-final design-system: name: honeycrisp languages: en, es diff --git a/src/main/resources/flows-config.yaml b/src/main/resources/flows-config.yaml index f5ca1b578..bc38bd009 100644 --- a/src/main/resources/flows-config.yaml +++ b/src/main/resources/flows-config.yaml @@ -453,6 +453,15 @@ flow: nextScreens: - name: submit-complete submit-complete: + nextScreens: + - name: info-review + info-review: + nextScreens: + - name: submit-complete-final + submit-complete-final: nextScreens: null + landmarks: firstScreen: submit-start + afterSubmitPages: + - submit-complete-final diff --git a/src/main/resources/messages.properties b/src/main/resources/messages.properties index 5c42b6568..e6a73206a 100644 --- a/src/main/resources/messages.properties +++ b/src/main/resources/messages.properties @@ -1091,4 +1091,14 @@ provider-response-submit-complete.header=Your response has been recorded provider-response-submit-complete.notice-yes=Next, we will collect your provider information. This should take 2-3 minutes. provider-response-submit-complete.notice-no=We will notify the CCR&R of your response. provider-response-submit-complete.button-no=Return to home - +#info-review +provider-response-info-review.title=Info Review +provider-response-info-review.header=Let's review your info +provider-response +#submit-complete-final +provider-response-submit-complete-final.title=Provider Submission Complete +provider-response-submit-complete-final.header=Done! You are now listed as a child care provider for this family. +provider-response-submit-complete-final.notice-pt1=The complete the application with confirmation code: {0}. +provider-response-submit-complete-final.notice-pt2=It has been sent to the CCR&R for processing. +provider-response-submit-complete-final.return-to-home-button=Return to home +provider-response-submit-complete-final.respond-to-another-app-button=Respond to another app diff --git a/src/main/resources/templates/gcc/submit-sign-name.html b/src/main/resources/templates/gcc/submit-sign-name.html index 4ba4678ad..9e4f62414 100644 --- a/src/main/resources/templates/gcc/submit-sign-name.html +++ b/src/main/resources/templates/gcc/submit-sign-name.html @@ -13,7 +13,8 @@ header=#{submit-sign-name.title}, subtext=#{submit-sign-name.subtext})}"/> + th:replace="~{fragments/form :: form(action=|/flow/${flow}/${screen}/submit|, content=~{::formContent})}"> +
+ + +
+
+
+
+
+
+ + + +
+ +
+ +
+
+
+
+
+
+ + + diff --git a/src/main/resources/templates/providerresponse/submit-complete-final.html b/src/main/resources/templates/providerresponse/submit-complete-final.html new file mode 100644 index 000000000..ce8f0e329 --- /dev/null +++ b/src/main/resources/templates/providerresponse/submit-complete-final.html @@ -0,0 +1,43 @@ + + + + +
+
+
+
+
+
+ +
+
+ + +
+
+

+

+
+
+ +
+
+
+
+
+
+ + + diff --git a/src/test/java/org/ilgcc/app/journeys/ProviderresponseFlowJourneyTest.java b/src/test/java/org/ilgcc/app/journeys/ProviderresponseFlowJourneyTest.java index 52f2dc4b7..e54736d90 100644 --- a/src/test/java/org/ilgcc/app/journeys/ProviderresponseFlowJourneyTest.java +++ b/src/test/java/org/ilgcc/app/journeys/ProviderresponseFlowJourneyTest.java @@ -18,7 +18,7 @@ public class ProviderresponseFlowJourneyTest extends AbstractBasePageTest { private static String CONF_CODE="A2123B"; @Test - void ProviderresponseWithShortLinkFlowJourneyTest() { + void ProviderresponseJourneyTest() { testPage.navigateToFlowScreen("gcc/activities-parent-intro"); saveSubmission(getSessionSubmissionTestBuilder().withDayCareProvider() @@ -74,12 +74,25 @@ void ProviderresponseWithShortLinkFlowJourneyTest() { // response assertThat(testPage.getTitle()).isEqualTo(getEnMessage("provider-response-response.title")); - testPage.clickElementById("providerResponseAgreeToCare-false-label"); + testPage.clickElementById("providerResponseAgreeToCare-true-label"); testPage.clickContinue(); // submit-complete assertThat(testPage.getTitle()).isEqualTo(getEnMessage("provider-response-submit-complete.title")); - assertThat(testPage.findElementsByClass("notice").get(0).getText()).isEqualTo(getEnMessage("provider-response-submit-complete.notice-no")); + assertThat(testPage.findElementsByClass("notice").get(0).getText()).isEqualTo(getEnMessage("provider-response-submit-complete.notice-yes")); + testPage.clickContinue(); + + //info-review + assertThat(testPage.getTitle()).isEqualTo(getEnMessage("provider-response-info-review.title")); + testPage.clickButton("Submit"); + + //submit-complete-final + assertThat(testPage.getTitle()).isEqualTo(getEnMessage("provider-response-submit-complete-final.title")); + testPage.goBack(); + assertThat(testPage.getTitle()).isEqualTo(getEnMessage("provider-response-submit-complete-final.title")); + testPage.findElementById("respond-to-another-app-button").click(); + assertThat(testPage.getTitle()).isEqualTo(getEnMessage("provider-response-submit-start.title")); + } }