Skip to content

Integration20251001#8

Open
sh1l0n wants to merge 11 commits intomainfrom
integration20251001
Open

Integration20251001#8
sh1l0n wants to merge 11 commits intomainfrom
integration20251001

Conversation

@sh1l0n
Copy link
Copy Markdown
Collaborator

@sh1l0n sh1l0n commented Oct 1, 2025

Note

Migrates to fhir_r4/fhir_r4_path with async FHIRPath evaluation, refactors types/APIs (valueX, enums, DateTime), updates UI/controllers/utils, and adjusts example and dependencies.

  • Core library (FHIR R4 migration)
    • Replace fhir/fhir_path with fhir_r4/fhir_r4_path; update imports across library and example.
    • Refactor models to new types/APIs: use valueX, *.valueString/valueInt/valueBoolean, QuestionnaireItemTypeEnum, and FhirDateTime.fromDateTime.
    • Remove internal questionnaire_response_status enum; use FHIR R4 enum directly.
  • Calculated expressions (FHIRPath) & response generation
    • Make FHIRPath evaluation and response generation async; pass resource objects instead of JSON; compute root variables and resolve calculated items asynchronously.
  • UI/controllers
    • Update enableWhen logic to new value accessors; adjust choice/open-choice handling; quantity unit/comparator and attachment icon checks updated; add reusable title rendering; QuestionnaireView.onSubmit now async.
  • Utils
    • Localization via Intl.defaultLocale; update date/time, coding/title helpers, and annotation author field (authorX).
  • Example app
    • Switch to fhir_r4, adapt attachment utils and questionnaire samples; minor UI tweaks.
  • Dependencies
    • Update pubspec.yaml to fhir_r4/fhir_r4_path and newer versions of related packages; lockfiles refreshed.

Written by Cursor Bugbot for commit 2f1543e. This will update automatically on new commits. Configure here.

@sh1l0n sh1l0n self-assigned this Oct 1, 2025
@sh1l0n sh1l0n added the enhancement New feature or request label Oct 1, 2025
@sh1l0n sh1l0n marked this pull request as ready for review October 2, 2025 06:57
@sh1l0n sh1l0n requested review from bartekwk2 and tigloo October 2, 2025 06:57
cursor[bot]

This comment was marked as outdated.

/// link ids, showing a unique id for this questionnaire [item].
String get uid =>
groupId.isNotEmpty ? '$groupId/${item.linkId}' : item.linkId;
groupId.isNotEmpty ? '$groupId/${item.linkId}' : item.linkId.valueString!;
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Bug: Bug

The fhir_r4 migration changed Questionnaire.title and QuestionnaireItem.linkId to objects, requiring .valueString for their string content. The code inconsistently accesses these, sometimes using .valueString and other times relying on implicit toString() or direct isNotEmpty checks. Also, groupId is a nullable String? but isNotEmpty is called directly, which may cause a null pointer exception.

Additional Locations (1)

Fix in Cursor Fix in Web

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants