-
Notifications
You must be signed in to change notification settings - Fork 145
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13107 from SORMAS-Foundation/feature-13084_show_l…
…inked_selfReporting_on_sideComponent #13084 - Linked SelfReporting message should be shown as side compone…
- Loading branch information
Showing
23 changed files
with
471 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
57 changes: 57 additions & 0 deletions
57
sormas-api/src/main/java/de/symeda/sormas/api/selfreport/SelfReportListEntryDto.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
package de.symeda.sormas.api.selfreport; | ||
|
||
import java.io.Serializable; | ||
import java.util.Date; | ||
|
||
import de.symeda.sormas.api.Disease; | ||
import de.symeda.sormas.api.utils.pseudonymization.PseudonymizableIndexDto; | ||
|
||
public class SelfReportListEntryDto extends PseudonymizableIndexDto implements Serializable { | ||
|
||
public static final String I18N_PREFIX = "SelfReport"; | ||
|
||
private Date reportingDate; | ||
private String caseReference; | ||
private Disease disease; | ||
private Date dateOfTest; | ||
|
||
public SelfReportListEntryDto(String uuid, Date reportingDate, String caseReference, Disease disease, Date dateOfTest) { | ||
super(uuid); | ||
this.reportingDate = reportingDate; | ||
this.caseReference = caseReference; | ||
this.disease = disease; | ||
this.dateOfTest = dateOfTest; | ||
} | ||
|
||
public Date getReportingDate() { | ||
return reportingDate; | ||
} | ||
|
||
public void setReportingDate(Date reportingDate) { | ||
this.reportingDate = reportingDate; | ||
} | ||
|
||
public String getCaseReference() { | ||
return caseReference; | ||
} | ||
|
||
public void setCaseReference(String caseReference) { | ||
this.caseReference = caseReference; | ||
} | ||
|
||
public Disease getDisease() { | ||
return disease; | ||
} | ||
|
||
public void setDisease(Disease disease) { | ||
this.disease = disease; | ||
} | ||
|
||
public Date getDateOfTest() { | ||
return dateOfTest; | ||
} | ||
|
||
public void setDateOfTest(Date dateOfTest) { | ||
this.dateOfTest = dateOfTest; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
...rc/main/java/de/symeda/sormas/backend/selfreport/SelfReportEntryDtoResultTransformer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package de.symeda.sormas.backend.selfreport; | ||
|
||
import de.symeda.sormas.api.Disease; | ||
import de.symeda.sormas.api.selfreport.SelfReportListEntryDto; | ||
import org.hibernate.transform.ResultTransformer; | ||
|
||
import java.util.Date; | ||
import java.util.List; | ||
|
||
public class SelfReportEntryDtoResultTransformer implements ResultTransformer { | ||
@Override | ||
public Object transformTuple(Object[] objects, String[] strings) { | ||
|
||
boolean referred = objects[4] !=null; | ||
return new SelfReportListEntryDto((String) objects[0], (Date) objects[1], (String) objects[2], (Disease) objects[3], (Date) objects[4]); | ||
} | ||
|
||
@Override | ||
public List transformList(List list) { | ||
return list; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.