-
Notifications
You must be signed in to change notification settings - Fork 222
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
QA tool for custom data #4857
QA tool for custom data #4857
Conversation
Preview URL 🚀 : https://blurts-server-pr-4857-mgjlpikfea-uk.a.run.app |
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.
Amazing work! Verified locally that the feature works. The FE could use some extra attention, but since this is an admin tool I don't see it as a blocker since it's not user facing. Opened a ticket to enhance it later down the line here.
const qaToggles = await getQaToggleRow(sha1); | ||
let showCustomBreaches = true; | ||
let showRealBreaches = true; | ||
if (qaToggles) { | ||
showCustomBreaches = qaToggles.show_custom_breaches; | ||
showRealBreaches = qaToggles.show_real_breaches; | ||
} | ||
|
||
const qaBreaches = !showCustomBreaches | ||
? [] | ||
: await getAllQaCustomBreaches(sha1Prefix); | ||
if (!showRealBreaches) return qaBreaches as HibpLikeDbBreach[]; | ||
|
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.
Could you leave a comment about what this is doing?
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 lines of code check whether a QA toggles row exists for the current user, and if it does, either show the QA breaches or not.
@@ -37,6 +39,17 @@ export async function POST( | |||
); | |||
} | |||
|
|||
// This marks a QA broker as resolved. Collisions aren't a worry because a real user is never admin. |
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.
Praise: comment
Cleanup completed - database 'blurts-server-pr-4857' destroyed, cloud run service 'blurts-server-pr-4857' destroyed |
References:
Jira: MNTOR-3357, MNTOR-3424, MNTOR-3425
Figma:
Description
Separated from mock endpoints, and added complete customization. Admin is able to turn on/off custom and real data, and is able to adjust each field of the custom breach and broker objects.
Screenshot (if applicable)
Not applicable.
How to test
Checklist (Definition of Done)