Skip to content

Commit

Permalink
finalizing case import and export pick-merge func
Browse files Browse the repository at this point in the history
  • Loading branch information
daveotengo committed Jul 27, 2023
1 parent 24227f6 commit 329a063
Show file tree
Hide file tree
Showing 59 changed files with 8,569 additions and 6,078 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
import static de.symeda.sormas.api.CountryHelper.COUNTRY_CODE_SWITZERLAND;
import static de.symeda.sormas.api.utils.FieldConstraints.CHARACTER_LIMIT_BIG;

import java.io.Serializable;
import java.util.Date;
import java.util.List;
import java.util.Map;
Expand Down Expand Up @@ -72,7 +73,7 @@
import de.symeda.sormas.api.utils.pseudonymization.valuepseudonymizers.LongitudePseudonymizer;

@DependingOnFeatureType(featureType = FeatureType.CASE_SURVEILANCE)
public class CaseDataDto extends SormasToSormasShareableDto {
public class CaseDataDto extends SormasToSormasShareableDto implements Serializable{

private static final long serialVersionUID = 5007131477733638086L;
private static final long MILLISECONDS_30_DAYS = 30L * 24L * 60L * 60L * 1000L;
Expand Down Expand Up @@ -215,6 +216,8 @@ public class CaseDataDto extends SormasToSormasShareableDto {
public static final String DELETION_REASON = "deletionReason";
public static final String OTHER_DELETION_REASON = "otherDeletionReason";

public static final String NEW_EXISTING = "existingCase";

// Fields are declared in the order they should appear in the import template

@Outbreaks
Expand Down Expand Up @@ -580,7 +583,7 @@ public class CaseDataDto extends SormasToSormasShareableDto {

private NewExisting existingCase;

private PickMerge importUpdateCaseStatus;
//private PickMerge importUpdateCaseStatus;

public static CaseDataDto build(PersonReferenceDto person, Disease disease) {
return build(person, disease, HealthConditionsDto.build());
Expand Down Expand Up @@ -1749,11 +1752,11 @@ public String toString() {
return super.toString() + (StringUtils.isNotBlank(this.getExternalID()) ? " - " + this.getExternalID() : StringUtils.EMPTY);
}

public PickMerge getImportUpdateCaseStatus() {
return importUpdateCaseStatus;
}

public void setImportUpdateCaseStatus(PickMerge importUpdateCaseStatus) {
this.importUpdateCaseStatus = importUpdateCaseStatus;
}
// public PickMerge getImportUpdateCaseStatus() {
// return importUpdateCaseStatus;
// }
//
// public void setImportUpdateCaseStatus(PickMerge importUpdateCaseStatus) {
// this.importUpdateCaseStatus = importUpdateCaseStatus;
// }
}
17 changes: 12 additions & 5 deletions sormas-api/src/main/java/de/symeda/sormas/api/caze/CaseFacade.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,7 @@
package de.symeda.sormas.api.caze;

import java.math.BigDecimal;
import java.util.Collection;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.Random;
import java.util.*;

import javax.ejb.Remote;
import javax.validation.Valid;
Expand Down Expand Up @@ -95,8 +91,19 @@ List<CaseExportDto> getExportList(
ExportConfigurationDto exportConfiguration,
Language userLanguage);

List<CaseIndexExportDto[]> getExportListDuplicates(
CaseCriteria caseCriteria,
Collection<String> selectedRows,
CaseExportType exportType,
int first,
int max,
ExportConfigurationDto exportConfiguration,
Language userLanguage,boolean ignoreRegion);

CaseDataDto getCaseDataByUuid(String uuid);

LinkedHashMap<CaseDataDto, CaseDataDto> getCaseDataByParentAndChildUuid(String parentUuid, String childUuid);

CaseDataDto saveCase(@Valid CaseDataDto dto) throws ValidationRuntimeException;

CaseDataDto updateFollowUpComment(@Valid @NotNull CaseDataDto dto) throws ValidationRuntimeException;
Expand Down
Loading

0 comments on commit 329a063

Please sign in to comment.