Skip to content

Commit

Permalink
Fix alcool -> alcohol
Browse files Browse the repository at this point in the history
  • Loading branch information
mwithi committed Jan 14, 2025
1 parent 2c50854 commit 77b7e49
Show file tree
Hide file tree
Showing 7 changed files with 34 additions and 27 deletions.
2 changes: 1 addition & 1 deletion sql/data_it/disease.csv
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ E68;Sequele dell’ iperalimentazione;E;0;1;1
E73;Intolleranza al lattosio ;E;0;1;1
E86;Ipovolemia;E;0;1;1
F03;Demenza non specificata;F;0;1;1
F10;Disturbi psichici e comportamentali dovuti all'uso di alcool;F;0;1;1
F10;Disturbi psichici e comportamentali dovuti all'uso di alcol;F;0;1;1
F19;Disturbi psichici e comportamentali dovuti all’uso di sostanze psicoattive multiple e all’uso di altre sostanze psicoattive;F;0;1;1
F20;Schizofrenia;F;0;1;1
F23;Disturbi psicotici acuti e transitori;F;0;1;1
Expand Down
30 changes: 15 additions & 15 deletions sql/load_demo_data.sql

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion sql/step_04_all_following_steps.sql
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ source step_a111_add_missing_lock_columns.sql;
source step_a112_users_and_groups_soft_deletion.sql;
source step_a113_alter_table_medicalinventory.sql;
source step_a114_medical_type_soft_deletion.sql;
source step_a115_add_missing_foreign_key_for_auditable_entities.sql
source step_a115_add_missing_foreign_key_for_auditable_entities.sql;
source step_a116_fix_alcohol_column.sql;
2 changes: 2 additions & 0 deletions sql/step_a116_fix_alcohol_column.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ALTER TABLE OH_PATIENTHISTORY
CHANGE COLUMN `PAH_PHY_ALCOOL` `PAH_PHY_ALCOHOL` TINYINT(1) NULL DEFAULT 0 ;
20 changes: 12 additions & 8 deletions src/main/java/org/isf/anamnesis/model/PatientHistory.java
Original file line number Diff line number Diff line change
Expand Up @@ -234,9 +234,9 @@ public class PatientHistory extends Auditable<String> implements Comparable<Pati
@Column(name = "PAH_PHY_DIURE_ABN")
private String phyDiuresisAbnormal;

@Column(name = "PAH_PHY_ALCOOL")
@Column(name = "PAH_PHY_ALCOHOL")
@ColumnDefault("false")
private boolean phyAlcool;
private boolean phyAlcohol;

@Column(name = "PAH_PHY_SMOKE")
@ColumnDefault("false")
Expand Down Expand Up @@ -585,12 +585,12 @@ public void setPhyDiuresisAbnormal(String phyDiuresisAbnormal) {
this.phyDiuresisAbnormal = phyDiuresisAbnormal;
}

public boolean isPhyAlcool() {
return phyAlcool;
public boolean isPhyAlcohol() {
return phyAlcohol;
}

public void setPhyAlcool(boolean phyAlcool) {
this.phyAlcool = phyAlcool;
public void setPhyAlcohol(boolean phyAlcohol) {
this.phyAlcohol = phyAlcohol;
}

public boolean isPhySmoke() {
Expand Down Expand Up @@ -785,7 +785,11 @@ public void setPatOpenNote(String patOpenNote) {
this.patOpenNote = patOpenNote;
}

public int getLock() { return lock; }
public int getLock() {
return lock;
}

public void setLock(int lock) { this.lock = lock; }
public void setLock(int lock) {
this.lock = lock;
}
}
2 changes: 1 addition & 1 deletion src/test/java/org/isf/anamnesis/TestPatientHistory.java
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public PatientHistory setup() throws Exception {
patientHistory.setPhyAlvoAbnormal("Alvo Abnormal");
patientHistory.setPhyDiuresisNormal(true);
patientHistory.setPhyDiuresisAbnormal("Diuresis Abnormal");
patientHistory.setPhyAlcool(false);
patientHistory.setPhyAlcohol(false);
patientHistory.setPhySmoke(true);
patientHistory.setPhyDrug(false);
patientHistory.setPhyPeriodNormal(true);
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/org/isf/anamnesis/Tests.java
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ void testPatientHistoryGets() throws Exception {
assertThat(patientHistory.getPhyAlvoAbnormal()).isEqualTo("Alvo Abnormal");
assertThat(patientHistory.isPhyDiuresisNormal()).isTrue();
assertThat(patientHistory.getPhyDiuresisAbnormal()).isEqualTo("Diuresis Abnormal");
assertThat(patientHistory.isPhyAlcool()).isFalse();
assertThat(patientHistory.isPhyAlcohol()).isFalse();
assertThat(patientHistory.isPhySmoke()).isTrue();
assertThat(patientHistory.isPhyDrug()).isFalse();
assertThat(patientHistory.isPhyPeriodNormal()).isTrue();
Expand Down

0 comments on commit 77b7e49

Please sign in to comment.