Skip to content

fix: allow selecting "Don't import" for lab result groups - #38

Merged
bisonbet merged 1 commit into
mainfrom
codex/enable-selection-to-skip-lab-test-import
May 29, 2026
Merged

fix: allow selecting "Don't import" for lab result groups#38
bisonbet merged 1 commit into
mainfrom
codex/enable-selection-to-skip-lab-test-import

Conversation

@bisonbet

Copy link
Copy Markdown
Owner

Motivation

  • The import review UI previously used an optional selectedIds dictionary to represent an explicit "Don't import" choice, which could drop or misrepresent the user intent to skip a group.
  • Users need the ability to explicitly skip importing a lab result when none of the candidate options are acceptable.

Description

  • Changed selection model in BloodTestImportReviewView by replacing the optional-mapped state with selectedIds: [UUID: UUID] and adding ignoredGroupIds: Set<UUID> to track explicit skip choices.
  • Hydrated state in onAppear so groups without a selectedCandidateId are added to ignoredGroupIds and header UI shows "Will Ignore" for skipped groups.
  • Made the "Don't import this result" row write to ignoredGroupIds and clear the bound group's selectedCandidateId, and updated candidate taps to clear the ignored state when a valid candidate is chosen.
  • Updated acceptSelected() to respect ignoredGroupIds by setting selectedCandidateId = nil for ignored groups and updated acceptAllRecommended() to clear ignore flags for groups it auto-selects. (File: HealthApp/HealthApp/Views/BloodTestImportReviewView.swift)

Testing

  • No automated unit/UI tests were executed in this rollout; no xcodebuild or XCTest runs were requested per project guidelines.
  • Verified code changes were staged and committed locally (git status and commit) and the updated file compiles syntactically in-editor (runtime validation not performed).

Codex Task

@bisonbet

Copy link
Copy Markdown
Owner Author

@claude please review this PR

@claude

claude Bot commented May 27, 2026

Copy link
Copy Markdown

Claude encountered an error after 0s —— View job


I'll analyze this and get back to you.

@bisonbet
bisonbet merged commit 1c5d97d into main May 29, 2026
1 check failed
@bisonbet
bisonbet deleted the codex/enable-selection-to-skip-lab-test-import branch May 29, 2026 21:57
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.

1 participant