Skip to content
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

feat(message-queue): allow confirming and rejecting record externally #7674

Open
wants to merge 5 commits into
base: ocrvs-6208
Choose a base branch
from

Conversation

naftis
Copy link
Collaborator

@naftis naftis commented Sep 26, 2024

Country-config: opencrvs/opencrvs-countryconfig#288

Creates two new GraphQL endpoints:

  • confirmRegistration - allowing confirming a record from WAITING_VALIDATION state
  • rejectRegistration - allowing rejecting a record

This will also enable integrations such as MOSIP 'hijacking' the confirm path and only doing it when they are ready.


Todo:

  • Tests for confirm endpoint
  • Remove the old tests that refer to non-existing reason values

Copy link

Oops! Looks like you forgot to update the changelog. When updating CHANGELOG.md, please consider the following:

  • Changelog is read by country implementors who might not always be familiar with all technical details of OpenCRVS. Keep language high-level, user friendly and avoid technical references to internals.
  • Answer "What's new?", "Why was the change made?" and "Why should I care?" for each change.
  • If it's a breaking change, include a migration guide answering "What do I need to do to upgrade?".

Comment on lines 1242 to 1245
export const enum GQLRejectionReason {
other = 'other',
duplicate = 'duplicate'
}
Copy link
Collaborator Author

@naftis naftis Sep 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As far as I can see, this frontend code acts as a source of truth for the rejection reasons... we must refactor this to be stricter.

it would be the correct REST action for the state changes: chose convention for now
@@ -0,0 +1,53 @@
/*
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test required for this endpoint

@ocrvs-bot
Copy link
Collaborator

Your environment is deployed to https://ocrvs-6208-reject-registration.opencrvs.dev.

@naftis naftis force-pushed the ocrvs-6208-reject-registration branch from bd84e0e to c2db318 Compare September 30, 2024 14:42
Comment on lines -93 to -96
case 'misspelling':
return rejectMessages.rejectionReasonMisspelling
case 'missing_supporting_doc':
return rejectMessages.rejectionReasonMissingSupportingDoc
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please double-check these aren't used anywhere? I only found the strings from tests and I'm planning to remove the tests that refer to these.

@naftis naftis self-assigned this Sep 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants