Skip to content

#13972 - Enhance Yersiniosis health conditions form and person form - #14253

Merged
raulbob merged 2 commits into
developmentfrom
feature-13972-yersiniosis_enhance_person_and_health_conditions_form
Jul 30, 2026
Merged

#13972 - Enhance Yersiniosis health conditions form and person form#14253
raulbob merged 2 commits into
developmentfrom
feature-13972-yersiniosis_enhance_person_and_health_conditions_form

Conversation

@raulbob

@raulbob raulbob commented Jul 30, 2026

Copy link
Copy Markdown
Contributor
  • added HealthConditions highIronLevel fields
  • added Student occupation for person enable for Yersiniosis

Fixes #13972

Summary by CodeRabbit

  • New Features

    • Added a “high iron level” health condition for Yersiniosis cases in Luxembourg.
    • Added “Student” as an occupation option for Yersiniosis, including occupation details.
    • Updated health condition forms to show the new field when applicable.
  • Bug Fixes

    • Improved occupation detail field visibility and captions during initial load and when changing the selected occupation/disease.
  • Style

    • Added visual styling for Yersiniosis disease coloring in the UI.

- added HealthConditions highIronLevel fields
- added Student occupation for person enable for Yersiniosis
@raulbob
raulbob requested a review from KarnaiahPesula July 30, 2026 11:43
@raulbob raulbob linked an issue Jul 30, 2026 that may be closed by this pull request
4 tasks
@coderabbitai

coderabbitai Bot commented Jul 30, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The change adds Yersiniosis-specific health-condition storage and display, including a Luxembourg-only high iron level field. It also adds Student occupation handling, updates occupation-detail behavior, and adds Yersiniosis disease styling.

Changes

Yersiniosis enhancements

Layer / File(s) Summary
Health-condition contract and persistence
sormas-api/.../HealthConditionsDto.java, sormas-backend/.../HealthConditions.java, sormas-backend/.../HealthConditionsMapper.java, sormas-backend/.../sormas_schema.sql
Adds the Yersiniosis-specific highIronLevel field, maps it between DTO and entity, persists it in current and history tables, and updates disease-specific condition metadata.
Health-condition form integration
sormas-ui/.../clinicalcourse/HealthConditionsForm.java
Registers and displays HIGH_IRON_LEVEL in the health-conditions form.
Student occupation details
sormas-api/.../enum.properties, sormas-ui/.../person/PersonEditForm.java
Adds the Student occupation and updates occupation-details visibility and captions for Luxembourg Yersiniosis cases.
Yersiniosis disease styling
sormas-ui/.../CssStyles.java, sormas-ui/.../disease.scss
Maps Yersiniosis to its CSS class and defines its disease color styles.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related PRs

Suggested reviewers: karnaiahpesula, roldy

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR adds Student and High iron level, but it also makes Down syndrome visible for Yersiniosis instead of hiding it. Remove Yersiniosis from the Down syndrome flow and verify the occupation detail field shows School/nursery name for Student in Luxembourg.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main Yersiniosis person and health-condition updates.
Description check ✅ Passed The description includes a useful summary and links the PR to issue #13972 as required.
Out of Scope Changes check ✅ Passed The changes are centered on Yersiniosis support, with only minor formatting and style updates beyond the main feature work.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature-13972-yersiniosis_enhance_person_and_health_conditions_form

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@sormas-ui/src/main/java/de/symeda/sormas/ui/person/PersonEditForm.java`:
- Around line 410-428: Restrict the occupation options populated by
getEnumValues in PersonEditForm so STUDENT is available for YERSINIOSIS only on
Luxembourg-configured servers. Apply the filtering before or during
occupationTypeField item setup, while preserving all other occupation values and
existing caption behavior.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 371decb3-3894-46ba-b038-aee1718ce67e

📥 Commits

Reviewing files that changed from the base of the PR and between b4607d9 and c65564a.

📒 Files selected for processing (7)
  • sormas-api/src/main/java/de/symeda/sormas/api/clinicalcourse/HealthConditionsDto.java
  • sormas-api/src/main/resources/enum.properties
  • sormas-backend/src/main/java/de/symeda/sormas/backend/clinicalcourse/HealthConditions.java
  • sormas-backend/src/main/java/de/symeda/sormas/backend/clinicalcourse/HealthConditionsMapper.java
  • sormas-backend/src/main/resources/sql/sormas_schema.sql
  • sormas-ui/src/main/java/de/symeda/sormas/ui/clinicalcourse/HealthConditionsForm.java
  • sormas-ui/src/main/java/de/symeda/sormas/ui/person/PersonEditForm.java

@raulbob
raulbob merged commit bde6dcb into development Jul 30, 2026
4 of 5 checks passed
@raulbob
raulbob deleted the feature-13972-yersiniosis_enhance_person_and_health_conditions_form branch July 30, 2026 13:04

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@sormas-ui/src/main/webapp/VAADIN/themes/sormas/views/disease.scss`:
- Around line 683-691: Update the background-disease-yersiniosis palette to use
an approved color with sufficient contrast against the existing white labels,
and validate that both its default and background-darker variants remain
readable. If retaining `#ddef07` is required, update DiseaseTileComponent to
render dark text for Yersiniosis instead.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: be825a65-b5ab-4f2b-9202-2dbb6829d62b

📥 Commits

Reviewing files that changed from the base of the PR and between c65564a and 4af2ad4.

📒 Files selected for processing (2)
  • sormas-ui/src/main/java/de/symeda/sormas/ui/utils/CssStyles.java
  • sormas-ui/src/main/webapp/VAADIN/themes/sormas/views/disease.scss

Comment thread sormas-ui/src/main/webapp/VAADIN/themes/sormas/views/disease.scss
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Yersiniosis - Enhance person and health conditions form

2 participants