NFDIV-5328 - Stop citizens from accessing pages after submission#4703
NFDIV-5328 - Stop citizens from accessing pages after submission#4703pallavijustice wants to merge 7 commits intonfdiv-5200-pre-issue-service-applicationsfrom
Conversation
…ed in no respondent address journey
| urls: [...applicant1PreSubmissionSequence] | ||
| .filter(step => !PRE_SUBMISSION_ROUTES_TO_IGNORE.includes(step.url as PageLink)) | ||
| .map(step => step.url as PageLink), | ||
| condition: data => !!data?.dateSubmitted, |
There was a problem hiding this comment.
Thinking that to avoid blocking pages in both the pre and post-submission sequences, it could be safer to check directly against the post-submission sequence than to use an array of constants defined in this file.
It should make it future-proof automatically - if a dev adds a page to both the pre and post submission sequences, the validation will stop without them needing to be aware of and update PRE_SUBMISSION_ROUTES_TO_IGNORE in this file.
| app.post(step.url, errorHandler(new postController(step.form.fields).post)); | ||
| app.post( | ||
| step.url, | ||
| this.isRouteForUser as RequestHandler, |
There was a problem hiding this comment.
We'll also be applying validations to the post controllers of pages outside the main divorce journey with this page. Thinking we could add a QA note to guide their exploratory testing
There was a problem hiding this comment.
Doo you think this is an issue. Since we already had a validation for getController here, Ii do not think it would be an issue if we aren't able to submit from here either.
…ed in no respondent address journey
Change description
Enter a description.
JIRA link (if applicable)
https://tools.hmcts.net/jira/browse/NFDIV-5328