Skip to content

[MS-1484] MFID: QR codes are no longer required to be confirmed. QR code readouts cannot be edited.#1723

Merged
alexandr-simprints merged 1 commit into
release/2026.2.1from
MS-1484-mfid-remove-confirmation-step-in-qr-workflow
Jun 25, 2026
Merged

[MS-1484] MFID: QR codes are no longer required to be confirmed. QR code readouts cannot be edited.#1723
alexandr-simprints merged 1 commit into
release/2026.2.1from
MS-1484-mfid-remove-confirmation-step-in-qr-workflow

Conversation

@alexandr-simprints

Copy link
Copy Markdown
Contributor

JIRA ticket
Will be released in: 2026.2.1

Notable changes

  • Values of the QR code readouts can no longer be edited
  • QR code readouts no longer require checkbox confirmation from the user
image

The OCR readouts still have the 'edit' icon and the 'confirmation checkbox' in place
image

Testing guidance

  • Enable QR codes in the MFID settings
  • Scan the QR code
  • Make sure that you can recapture and continue
  • Make that confirmation checkbox is hidden
  • Make that the edit icon is hidden

Additional work checklist

  • Effect on other features and security has been considered

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the MFID external-credential search UI/state so that QR-code readouts no longer require user confirmation and cannot be edited, while keeping the existing “confirm/edit” behavior for OCR-derived credentials (e.g., Ghana NHIS / Ghana ID).

Changes:

  • Added state flags to indicate whether user confirmation and manual edit are available based on ExternalCredentialType.
  • Hid the confirmation checkbox and edit icon in the search UI when those actions aren’t applicable (notably for QR codes).
  • Allowed “Continue” without confirmation when confirmation is not required.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
feature/external-credential/src/main/java/com/simprints/feature/externalcredential/screens/search/model/SearchCredentialState.kt Adds per-credential-type flags controlling whether confirmation/editing should be available.
feature/external-credential/src/main/java/com/simprints/feature/externalcredential/screens/search/ExternalCredentialSearchFragment.kt Uses the new flags to hide the checkbox/edit icon and to relax the confirm-button enablement logic for QR flows.

): SearchCredentialState {
// [MS-1484] Editing and confirming the readout value should only be available for the OCR readouts (i.e.: Ghana NHIS card)
// QR codes are not readable by humans, hence there is no point of asking the user to confirm the readout, nor to edit the readout
val isOcrReadout = when (scannedCredentialResult.credentialType) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Will there be any other non-OCR options? Maybe it would be simpler to just do val isOcrReadout = scannedCredentialResult.credentialType != ExternalCredentialType.QRCode?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

No other non-OCR options are considered in the foreseeable future as far as I can tell. I wanted to keep the explicit when for this specific case: if we agree to add a new credential type, we can refine the logic further, and not skip this condition.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What would be the benefit of that? To me it feels like simply adding more work in the future.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

  1. The explicit when makes sure we won't miss this case.
  2. If we stick to val isOcrReadout = credentialType != ExternalCredentialType.QRCode, then, if non-OCR type is added, it is easy to miss this case since it is not explicit

Thus, I'd advise to sticking to the when option

@sonarqubecloud

Copy link
Copy Markdown

@alexandr-simprints alexandr-simprints merged commit 5625cc4 into release/2026.2.1 Jun 25, 2026
15 checks passed
@alexandr-simprints alexandr-simprints deleted the MS-1484-mfid-remove-confirmation-step-in-qr-workflow branch June 25, 2026 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants