-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update admin approval process #218
base: dev
Are you sure you want to change the base?
Conversation
@@ -0,0 +1,171 @@ | |||
import Link from "next/link"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is an updated copy of the RejectReasonForm
component. It is used only for the digital wallet onboarding flow right now, given that's the only flow with the new data structure including approvalStages
@@ -0,0 +1,213 @@ | |||
import { getTranslations } from "next-intl/server"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is an updated copy of the EventsTable
component. It handles the digital walltet onboarding flow only atm given it's the only one with approvalStages
return ( | ||
<tr key={row.userId} className="govie-table__row"> | ||
<td className="govie-table__cell govie-table__cell--vertical-centralized govie-body-s"> | ||
{row.userId.slice(0, 6)} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was only to quickly demo the prototype, but an actual ID
needs to be setup for each application. Right now the user_flow_data
table doesn't have any id column.
"use server"; | ||
|
||
const url = new URL( | ||
`${headers().get("x-pathname")}/reject-new`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is just to redirect to the NewRejectReasonForm
instead of the exisrting RejectReasonForm
/> | ||
) : ( | ||
<EventTable params={props.params} searchParams={props.searchParams} /> | ||
)} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is where I check whether to show the new submissions table (when the digitalWallet
FF is enabled) or whether to show the old submissions table which handles all other workflows submissions.
@@ -1,53 +1,219 @@ | |||
import { GetObjectCommand } from "@aws-sdk/client-s3"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This component right now handles both the readonly 'view' case - where admins can just see the current status of the application - and the 'review' case - where admins can click on approve or reject. When refactored it could potentially be split into separate components, one with and one without the review form.
digitalWalletAccess: { | ||
name: "Digital Wallet Pilot Access", | ||
description: "Grant access to the digital wallet pilot", | ||
allowedReviewerRoles: [], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These fields (name, description, allowedReviewerRoles) are not used, but wanted to give an idea of the fact that each stage can have multiple properties.
Ticket:
Description
Spike into adding multiple stages of approval in the life events admin side for the digital wallet onboarding applications.
The data structure of the
GetDigitalWallet
workflow on this pr is quite different from all of the other workflows (given it has anapprovalStages
array prop). The updates I made to the admin side (creating new components not to mess with the other workflows ones) only expect and work with this new data structure, so be careful not to complete other workflows (e.g. renew driving licence) whilst you have thedigitalWallet
FF enabled on this pr, or the admin side will be broken. You can manage other workflows disabling thedigitalWallet
FF. In that case the digital wallet flow won't work, but you can still manage the other with the existing components.Type
Checklist:
Screenshots: