Skip to content

Commit 37157dd

Browse files
authored
Merge pull request #13564 from SORMAS-Foundation/feature-13544-rsv_update-symptoms
#13533 - Updated RSV symptoms
2 parents 997f366 + 0e6595c commit 37157dd

File tree

7 files changed

+186
-12
lines changed

7 files changed

+186
-12
lines changed

sormas-api/src/main/java/de/symeda/sormas/api/i18n/Captions.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2850,6 +2850,7 @@ public interface Captions {
28502850
String Symptoms_diagnosis = "Symptoms.diagnosis";
28512851
String Symptoms_diarrhea = "Symptoms.diarrhea";
28522852
String Symptoms_difficultyBreathing = "Symptoms.difficultyBreathing";
2853+
String Symptoms_difficultyBreathingDuringMeals = "Symptoms.difficultyBreathingDuringMeals";
28532854
String Symptoms_digestedBloodVomit = "Symptoms.digestedBloodVomit";
28542855
String Symptoms_dizzinessStandingUp = "Symptoms.dizzinessStandingUp";
28552856
String Symptoms_dysphagia = "Symptoms.dysphagia";
@@ -2954,7 +2955,9 @@ public interface Captions {
29542955
String Symptoms_palpableLiver = "Symptoms.palpableLiver";
29552956
String Symptoms_palpableSpleen = "Symptoms.palpableSpleen";
29562957
String Symptoms_palpitations = "Symptoms.palpitations";
2958+
String Symptoms_paradoxicalBreathing = "Symptoms.paradoxicalBreathing";
29572959
String Symptoms_paralysis = "Symptoms.paralysis";
2960+
String Symptoms_parentTimeOffWork = "Symptoms.parentTimeOffWork";
29582961
String Symptoms_paresis = "Symptoms.paresis";
29592962
String Symptoms_paresthesiaAroundWound = "Symptoms.paresthesiaAroundWound";
29602963
String Symptoms_patientIllLocation = "Symptoms.patientIllLocation";
@@ -2968,6 +2971,7 @@ public interface Captions {
29682971
String Symptoms_redBloodVomit = "Symptoms.redBloodVomit";
29692972
String Symptoms_refusalFeedorDrink = "Symptoms.refusalFeedorDrink";
29702973
String Symptoms_respiratoryDiseaseVentilation = "Symptoms.respiratoryDiseaseVentilation";
2974+
String Symptoms_respiratoryFatigue = "Symptoms.respiratoryFatigue";
29712975
String Symptoms_respiratoryRate = "Symptoms.respiratoryRate";
29722976
String Symptoms_runnyNose = "Symptoms.runnyNose";
29732977
String Symptoms_seizures = "Symptoms.seizures";
@@ -2993,6 +2997,7 @@ public interface Captions {
29932997
String Symptoms_temperature = "Symptoms.temperature";
29942998
String Symptoms_temperatureSource = "Symptoms.temperatureSource";
29952999
String Symptoms_throbocytopenia = "Symptoms.throbocytopenia";
3000+
String Symptoms_timeOffWorkDays = "Symptoms.timeOffWorkDays";
29963001
String Symptoms_tremor = "Symptoms.tremor";
29973002
String Symptoms_unexplainedBleeding = "Symptoms.unexplainedBleeding";
29983003
String Symptoms_unilateralCataracts = "Symptoms.unilateralCataracts";

sormas-api/src/main/java/de/symeda/sormas/api/symptoms/SymptomsDto.java

Lines changed: 82 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -308,12 +308,17 @@ public class SymptomsDto extends PseudonymizableDto {
308308
public static final String SEPSIS = "sepsis";
309309
public static final String SHOCK = "shock";
310310
// clinical
311-
public static final String ASYMPTOMATIC = "asymptomatic";
311+
public static final String ASYMPTOMATIC = "asymptomatic";
312312
public static final String HEMORRHAGIC_RASH = "hemorrhagicRash";
313313
public static final String ARTHRITIS = "arthritis";
314314
public static final String MENINGITIS = "meningitis";
315315
public static final String SEPTICAEMIA = "septicaemia";
316316
public static final String UNKNOWN_SYMPTOM = "unknownSymptom";
317+
public static final String DIFFICULTY_BREATHING_DURING_MEALS = "difficultyBreathingDuringMeals";
318+
public static final String PARADOXICAL_BREATHING = "paradoxicalBreathing";
319+
public static final String RESPIRATORY_FATIGUE = "respiratoryFatigue";
320+
public static final String PARENT_TIME_OFF_WORK = "parentTimeOffWork";
321+
public static final String TIME_OFF_WORK_DAYS = "timeOffWorkDays";
317322
public static final String OTHER_CLINICAL_PRESENTATION = "otherClinicalPresentation";
318323
public static final String OTHER_CLINICAL_PRESENTATION_TEXT = "otherClinicalPresentationText";
319324

@@ -362,6 +367,7 @@ public static SymptomsDto build() {
362367
CHOLERA,
363368
POLIO,
364369
YELLOW_FEVER,
370+
RESPIRATORY_SYNCYTIAL_VIRUS,
365371
UNSPECIFIED_VHF,
366372
UNDEFINED,
367373
OTHER })
@@ -549,6 +555,7 @@ public static SymptomsDto build() {
549555
ANTHRAX,
550556
UNSPECIFIED_VHF,
551557
CORONAVIRUS,
558+
RESPIRATORY_SYNCYTIAL_VIRUS,
552559
UNDEFINED,
553560
OTHER })
554561
@Outbreaks
@@ -740,6 +747,7 @@ public static SymptomsDto build() {
740747
RABIES,
741748
ANTHRAX,
742749
CORONAVIRUS,
750+
RESPIRATORY_SYNCYTIAL_VIRUS,
743751
UNDEFINED,
744752
PERTUSSIS,
745753
OTHER })
@@ -1318,9 +1326,9 @@ public static SymptomsDto build() {
13181326
POST_IMMUNIZATION_ADVERSE_EVENTS_MILD,
13191327
POST_IMMUNIZATION_ADVERSE_EVENTS_SEVERE,
13201328
FHA,
1321-
INVASIVE_MENINGOCOCCAL_INFECTION,
1322-
INVASIVE_PNEUMOCOCCAL_INFECTION,
1323-
PERTUSSIS})
1329+
INVASIVE_MENINGOCOCCAL_INFECTION,
1330+
INVASIVE_PNEUMOCOCCAL_INFECTION,
1331+
PERTUSSIS })
13241332
@HideForCountries
13251333
@Outbreaks
13261334
private Date onsetDate;
@@ -1385,7 +1393,7 @@ public static SymptomsDto build() {
13851393
INVASIVE_MENINGOCOCCAL_INFECTION,
13861394
INVASIVE_PNEUMOCOCCAL_INFECTION,
13871395
FHA,
1388-
PERTUSSIS})
1396+
PERTUSSIS })
13891397
@HideForCountries
13901398
@Size(max = FieldConstraints.CHARACTER_LIMIT_DEFAULT, message = Validations.textTooLong)
13911399
private String onsetSymptom;
@@ -1576,6 +1584,7 @@ public static SymptomsDto build() {
15761584
DENGUE,
15771585
GUINEA_WORM,
15781586
POLIO,
1587+
RESPIRATORY_SYNCYTIAL_VIRUS,
15791588
UNSPECIFIED_VHF,
15801589
UNDEFINED,
15811590
OTHER })
@@ -1622,6 +1631,7 @@ public static SymptomsDto build() {
16221631
MEASLES,
16231632
POLIO,
16241633
CORONAVIRUS,
1634+
RESPIRATORY_SYNCYTIAL_VIRUS,
16251635
UNDEFINED,
16261636
OTHER })
16271637
@SymptomGrouping(SymptomGroup.RESPIRATORY)
@@ -2140,7 +2150,7 @@ public static SymptomsDto build() {
21402150
private SymptomState whoopSound;
21412151

21422152
@Diseases({
2143-
PERTUSSIS })
2153+
PERTUSSIS })
21442154
@HideForCountries
21452155
@SymptomGrouping(SymptomGroup.RESPIRATORY)
21462156
private SymptomState nocturnalCough;
@@ -2161,6 +2171,7 @@ public static SymptomsDto build() {
21612171

21622172
@Diseases({
21632173
CORONAVIRUS,
2174+
RESPIRATORY_SYNCYTIAL_VIRUS,
21642175
UNDEFINED,
21652176
OTHER })
21662177
@HideForCountries(countries = {
@@ -2546,9 +2557,10 @@ public static SymptomsDto build() {
25462557
@SymptomGrouping(SymptomGroup.GENERAL)
25472558
private SymptomState shivering;
25482559

2549-
@Diseases({INVASIVE_MENINGOCOCCAL_INFECTION,
2550-
INVASIVE_PNEUMOCOCCAL_INFECTION,
2551-
PERTUSSIS})
2560+
@Diseases({
2561+
INVASIVE_MENINGOCOCCAL_INFECTION,
2562+
INVASIVE_PNEUMOCOCCAL_INFECTION,
2563+
PERTUSSIS })
25522564
private SymptomState asymptomatic;
25532565
@Diseases({
25542566
INVASIVE_MENINGOCOCCAL_INFECTION })
@@ -2581,6 +2593,27 @@ public static SymptomsDto build() {
25812593
INVASIVE_MENINGOCOCCAL_INFECTION })
25822594
private SymptomState unknownSymptom;
25832595

2596+
// RSV-specific symptoms
2597+
@Diseases(RESPIRATORY_SYNCYTIAL_VIRUS)
2598+
@SymptomGrouping(SymptomGroup.RESPIRATORY)
2599+
private SymptomState difficultyBreathingDuringMeals;
2600+
2601+
@Diseases(RESPIRATORY_SYNCYTIAL_VIRUS)
2602+
@SymptomGrouping(SymptomGroup.RESPIRATORY)
2603+
private SymptomState paradoxicalBreathing;
2604+
2605+
@Diseases(RESPIRATORY_SYNCYTIAL_VIRUS)
2606+
@SymptomGrouping(SymptomGroup.RESPIRATORY)
2607+
private SymptomState respiratoryFatigue;
2608+
2609+
@Diseases(RESPIRATORY_SYNCYTIAL_VIRUS)
2610+
private YesNoUnknown parentTimeOffWork;
2611+
2612+
@Diseases(RESPIRATORY_SYNCYTIAL_VIRUS)
2613+
@DependantOn("parentTimeOffWork")
2614+
@Size(max = 50, message = Validations.textTooLong)
2615+
private String timeOffWorkDays;
2616+
25842617
private DiagnosisType diagnosis;
25852618
private InfectionSite majorSite;
25862619
private String otherMajorSiteDetails;
@@ -4363,4 +4396,44 @@ public SymptomState getUnknownSymptom() {
43634396
public void setUnknownSymptom(SymptomState unknownSymptom) {
43644397
this.unknownSymptom = unknownSymptom;
43654398
}
4399+
4400+
public SymptomState getDifficultyBreathingDuringMeals() {
4401+
return difficultyBreathingDuringMeals;
4402+
}
4403+
4404+
public void setDifficultyBreathingDuringMeals(SymptomState difficultyBreathingDuringMeals) {
4405+
this.difficultyBreathingDuringMeals = difficultyBreathingDuringMeals;
4406+
}
4407+
4408+
public SymptomState getParadoxicalBreathing() {
4409+
return paradoxicalBreathing;
4410+
}
4411+
4412+
public void setParadoxicalBreathing(SymptomState paradoxicalBreathing) {
4413+
this.paradoxicalBreathing = paradoxicalBreathing;
4414+
}
4415+
4416+
public SymptomState getRespiratoryFatigue() {
4417+
return respiratoryFatigue;
4418+
}
4419+
4420+
public void setRespiratoryFatigue(SymptomState respiratoryFatigue) {
4421+
this.respiratoryFatigue = respiratoryFatigue;
4422+
}
4423+
4424+
public YesNoUnknown getParentTimeOffWork() {
4425+
return parentTimeOffWork;
4426+
}
4427+
4428+
public void setParentTimeOffWork(YesNoUnknown parentTimeOffWork) {
4429+
this.parentTimeOffWork = parentTimeOffWork;
4430+
}
4431+
4432+
public String getTimeOffWorkDays() {
4433+
return timeOffWorkDays;
4434+
}
4435+
4436+
public void setTimeOffWorkDays(String timeOffWorkDays) {
4437+
this.timeOffWorkDays = timeOffWorkDays;
4438+
}
43664439
}

sormas-api/src/main/resources/captions.properties

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2922,6 +2922,11 @@ Symptoms.otherMinorSiteDetails=Other minor site
29222922
Symptoms.dateOfOnsetKnown=Date of onset known
29232923
Symptoms.clinicalPresentationStatus=Signs and symptoms
29242924
Symptoms.unknownSymptom=Unknown
2925+
Symptoms.difficultyBreathingDuringMeals=Difficulty breathing during meals
2926+
Symptoms.paradoxicalBreathing=Paradoxical (abdominal) breathing
2927+
Symptoms.respiratoryFatigue=Respiratory fatigue
2928+
Symptoms.parentTimeOffWork=Parent's time off work
2929+
Symptoms.timeOffWorkDays=Days off work
29252930
# Task
29262931
taskMyTasks=My tasks
29272932
taskNewTask=New task

sormas-backend/src/main/java/de/symeda/sormas/backend/symptoms/Symptoms.java

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,13 @@ public class Symptoms extends AbstractDomainObject {
263263
// Added in case, enrolling person is not known about the symptoms, but sure of the case.
264264
private SymptomState unknownSymptom;
265265

266+
// RSV-specific symptoms
267+
private SymptomState difficultyBreathingDuringMeals;
268+
private SymptomState paradoxicalBreathing;
269+
private SymptomState respiratoryFatigue;
270+
private YesNoUnknown parentTimeOffWork;
271+
private String timeOffWorkDays;
272+
266273
// when adding new fields make sure to extend toHumanString
267274

268275
@Temporal(TemporalType.TIMESTAMP)
@@ -2036,4 +2043,49 @@ public SymptomState getUnknownSymptom() {
20362043
public void setUnknownSymptom(SymptomState unknownSymptom) {
20372044
this.unknownSymptom = unknownSymptom;
20382045
}
2046+
2047+
@Enumerated(EnumType.STRING)
2048+
public SymptomState getDifficultyBreathingDuringMeals() {
2049+
return difficultyBreathingDuringMeals;
2050+
}
2051+
2052+
public void setDifficultyBreathingDuringMeals(SymptomState difficultyBreathingDuringMeals) {
2053+
this.difficultyBreathingDuringMeals = difficultyBreathingDuringMeals;
2054+
}
2055+
2056+
@Enumerated(EnumType.STRING)
2057+
public SymptomState getParadoxicalBreathing() {
2058+
return paradoxicalBreathing;
2059+
}
2060+
2061+
public void setParadoxicalBreathing(SymptomState paradoxicalBreathing) {
2062+
this.paradoxicalBreathing = paradoxicalBreathing;
2063+
}
2064+
2065+
@Enumerated(EnumType.STRING)
2066+
public SymptomState getRespiratoryFatigue() {
2067+
return respiratoryFatigue;
2068+
}
2069+
2070+
public void setRespiratoryFatigue(SymptomState respiratoryFatigue) {
2071+
this.respiratoryFatigue = respiratoryFatigue;
2072+
}
2073+
2074+
@Enumerated(EnumType.STRING)
2075+
public YesNoUnknown getParentTimeOffWork() {
2076+
return parentTimeOffWork;
2077+
}
2078+
2079+
public void setParentTimeOffWork(YesNoUnknown parentTimeOffWork) {
2080+
this.parentTimeOffWork = parentTimeOffWork;
2081+
}
2082+
2083+
@Column(length = CHARACTER_LIMIT_DEFAULT)
2084+
public String getTimeOffWorkDays() {
2085+
return timeOffWorkDays;
2086+
}
2087+
2088+
public void setTimeOffWorkDays(String timeOffWorkDays) {
2089+
this.timeOffWorkDays = timeOffWorkDays;
2090+
}
20392091
}

sormas-backend/src/main/java/de/symeda/sormas/backend/symptoms/SymptomsFacadeEjb.java

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,11 @@ public Symptoms fillOrBuildEntity(SymptomsDto source, Symptoms target, boolean c
230230
target.setOtherMinorSiteDetails(source.getOtherMinorSiteDetails());
231231
target.setDateOfOnsetKnown(source.getDateOfOnsetKnown());
232232
target.setClinicalPresentationStatus(source.getClinicalPresentationStatus());
233-
target.setUnknownSymptom(source.getUnknownSymptom());
233+
target.setUnknownSymptom(source.getUnknownSymptom()); target.setDifficultyBreathingDuringMeals(source.getDifficultyBreathingDuringMeals());
234+
target.setParadoxicalBreathing(source.getParadoxicalBreathing());
235+
target.setRespiratoryFatigue(source.getRespiratoryFatigue());
236+
target.setParentTimeOffWork(source.getParentTimeOffWork());
237+
target.setTimeOffWorkDays(source.getTimeOffWorkDays());
234238
target.setNocturnalCough(source.getNocturnalCough());
235239
return target;
236240
}
@@ -445,6 +449,11 @@ public static SymptomsDto toSymptomsDto(Symptoms symptoms) {
445449
target.setDateOfOnsetKnown(source.getDateOfOnsetKnown());
446450
target.setClinicalPresentationStatus(source.getClinicalPresentationStatus());
447451
target.setUnknownSymptom(source.getUnknownSymptom());
452+
target.setDifficultyBreathingDuringMeals(source.getDifficultyBreathingDuringMeals());
453+
target.setParadoxicalBreathing(source.getParadoxicalBreathing());
454+
target.setRespiratoryFatigue(source.getRespiratoryFatigue());
455+
target.setParentTimeOffWork(source.getParentTimeOffWork());
456+
target.setTimeOffWorkDays(source.getTimeOffWorkDays());
448457

449458
target.setNocturnalCough(source.getNocturnalCough());
450459
return target;

sormas-backend/src/main/resources/sql/sormas_schema.sql

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14490,4 +14490,19 @@ ALTER TABLE testreport_history ADD COLUMN testTypeDetails varchar(255);
1449014490

1449114491
INSERT INTO schema_version (version_number, comment) VALUES (582, 'Added missing fields for external message #13294');
1449214492

14493+
-- 2025-07-29 RSV Symptoms #13544
14494+
ALTER TABLE symptoms ADD COLUMN IF NOT EXISTS difficultyBreathingDuringMeals varchar(255);
14495+
ALTER TABLE symptoms ADD COLUMN IF NOT EXISTS paradoxicalBreathing varchar(255);
14496+
ALTER TABLE symptoms ADD COLUMN IF NOT EXISTS respiratoryFatigue varchar(255);
14497+
ALTER TABLE symptoms ADD COLUMN IF NOT EXISTS parentTimeOffWork varchar(255);
14498+
ALTER TABLE symptoms ADD COLUMN IF NOT EXISTS timeOffWorkDays varchar(255);
14499+
14500+
ALTER TABLE symptoms_history ADD COLUMN IF NOT EXISTS difficultyBreathingDuringMeals varchar(255);
14501+
ALTER TABLE symptoms_history ADD COLUMN IF NOT EXISTS paradoxicalBreathing varchar(255);
14502+
ALTER TABLE symptoms_history ADD COLUMN IF NOT EXISTS respiratoryFatigue varchar(255);
14503+
ALTER TABLE symptoms_history ADD COLUMN IF NOT EXISTS parentTimeOffWork varchar(255);
14504+
ALTER TABLE symptoms_history ADD COLUMN IF NOT EXISTS timeOffWorkDays varchar(255);
14505+
14506+
INSERT INTO schema_version (version_number, comment) VALUES (583, 'Update symptoms for RSV #13544');
14507+
1449314508
-- *** Insert new sql commands BEFORE this line. Remember to always consider _history tables. ***

sormas-ui/src/main/java/de/symeda/sormas/ui/symptoms/SymptomsForm.java

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ public class SymptomsForm extends AbstractEditForm<SymptomsDto> {
127127
private static final String TUBERCULOSIS_ONSET_DATE_LOC = "tuberculosisOnsetDateLoc";
128128
private static final String TUBERCULOSIS_CLINICAL_PRESENTATION_DETAILS_LOC = "tuberculosisClinicalPresentationDetailsLoc";
129129

130-
private static Map<String, List<String>> symptomGroupMap = new HashMap();
130+
private static Map<String, List<String>> symptomGroupMap = new HashMap<>();
131131

132132
//@formatter:off
133133
private static final String HTML_LAYOUT =
@@ -167,6 +167,7 @@ public class SymptomsForm extends AbstractEditForm<SymptomsDto> {
167167
loc(CLINICAL_PRESENTATION_HEADING)+
168168
fluidRowLocs(DATE_OF_ONSET_KNOWN, TUBERCULOSIS_ONSET_DATE_LOC, "") +
169169
fluidRowLocs(CLINICAL_PRESENTATION_STATUS, TUBERCULOSIS_CLINICAL_PRESENTATION_DETAILS_LOC) +
170+
fluidRowLocs(PARENT_TIME_OFF_WORK, TIME_OFF_WORK_DAYS) +
170171
fluidRow(
171172
fluidColumn(6, 0,
172173
locsCss(VSPACE_3,
@@ -494,7 +495,10 @@ public String getFormattedHtmlMessage() {
494495
DIZZINESS_STANDING_UP,
495496
HIGH_OR_LOW_BLOOD_PRESSURE,
496497
URINARY_RETENTION,
497-
FEVER);
498+
FEVER,
499+
DIFFICULTY_BREATHING_DURING_MEALS,
500+
PARADOXICAL_BREATHING,
501+
RESPIRATORY_FATIGUE);
498502

499503
addField(SYMPTOMS_COMMENTS, TextField.class).setDescription(
500504
I18nProperties.getPrefixDescription(I18N_PREFIX, SYMPTOMS_COMMENTS, "") + "\n" + I18nProperties.getDescription(Descriptions.descGdpr));
@@ -982,6 +986,17 @@ public String getFormattedHtmlMessage() {
982986
.setItemCaption(ClinicalPresentationStatus.COMPATIBLE, ClinicalPresentationStatus.COMPATIBLE.buildCaption(disease.toShortString()));
983987
getFieldGroup().getField(OTHER_CLINICAL_PRESENTATION_TEXT).setVisible(true);
984988
}
989+
990+
final Field<?> parentTimeOffWorkField = addField(PARENT_TIME_OFF_WORK);
991+
final TextField timeOffWorkDaysField = addField(TIME_OFF_WORK_DAYS, TextField.class);
992+
parentTimeOffWorkField.addValueChangeListener(e -> {
993+
if (!parentTimeOffWorkField.isVisible()) {
994+
return;
995+
}
996+
final boolean isParentTimeOffWorkYes = YesNoUnknown.YES.equals(FieldHelper.getNullableSourceFieldValue(parentTimeOffWorkField));
997+
timeOffWorkDaysField.setVisible(isParentTimeOffWorkYes);
998+
timeOffWorkDaysField.setValue(isParentTimeOffWorkYes ? timeOffWorkDaysField.getValue() : null);
999+
});
9851000
}
9861001

9871002
private void toggleFeverComponentError(NullableOptionGroup feverField, ComboBox temperatureField) {

0 commit comments

Comments
 (0)