Skip to content

Commit

Permalink
Fixed #2834
Browse files Browse the repository at this point in the history
  • Loading branch information
MateStrysewske committed Sep 7, 2020
1 parent 9018590 commit 98eded1
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
import de.symeda.sormas.api.caze.PlagueType;
import de.symeda.sormas.api.caze.RabiesType;
import de.symeda.sormas.api.event.TypeOfPlace;
import de.symeda.sormas.api.facility.FacilityType;
import de.symeda.sormas.api.facility.FacilityTypeGroup;
import de.symeda.sormas.api.person.PresentCondition;
import de.symeda.sormas.api.person.Sex;
Expand Down Expand Up @@ -209,6 +210,12 @@ public void onAfterLayoutBinding(final FragmentCaseNewLayoutBinding contentBindi
contentBinding.caseDataCommunity.setRequired(false);
contentBinding.caseDataHealthFacility.setEnabled(false);
contentBinding.caseDataHealthFacility.setRequired(false);
contentBinding.facilityOrHome.setValue(TypeOfPlace.FACILITY);
contentBinding.facilityOrHome.setEnabled(false);
contentBinding.facilityTypeGroup.setValue(FacilityTypeGroup.MEDICAL_FACILITY);
contentBinding.facilityTypeGroup.setEnabled(false);
contentBinding.caseDataFacilityType.setValue(FacilityType.HOSPITAL);
contentBinding.caseDataFacilityType.setEnabled(false);
}

if (user.hasUserRole(UserRole.POE_INFORMANT) && user.getPointOfEntry() != null) {
Expand Down Expand Up @@ -287,6 +294,7 @@ record = getActivityRootData();
record.setRegion(lastCase.getRegion());
record.setDistrict(lastCase.getDistrict());
record.setCommunity(lastCase.getCommunity());
record.setFacilityType(lastCase.getFacilityType());
record.setHealthFacility(lastCase.getHealthFacility());
record.setHealthFacilityDetails(lastCase.getHealthFacilityDetails());
record.setPointOfEntry(lastCase.getPointOfEntry());
Expand Down

0 comments on commit 98eded1

Please sign in to comment.