Skip to content

Commit

Permalink
#158: Updated positioning of fields at case create
Browse files Browse the repository at this point in the history
  • Loading branch information
Flava177 committed Oct 7, 2024
1 parent 6c4adfe commit 0fd90de
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ public void onLayoutBinding(FragmentCaseNewLayoutBinding contentBinding) {
() -> Boolean.TRUE.equals(contentBinding.caseDataDifferentPlaceOfStayJurisdiction.getValue()));

contentBinding.caseDataCaseTransmissionClassification.initializeSpinner(caseTransmissionClassificationsList);
contentBinding.caseDataCaseTransmissionClassification.setVisibility(GONE);
// InfrastructureDaoHelper.initializeFacilityFields(
InfrastructureFieldsDependencyHandler.instance.initializeFacilityFields(
record,
Expand Down
44 changes: 22 additions & 22 deletions sormas-app/app/src/main/res/layout/fragment_case_new_layout.xml
Original file line number Diff line number Diff line change
Expand Up @@ -51,21 +51,6 @@

<requestFocus />

<de.symeda.sormas.app.component.controls.ControlSwitchField
android:id="@+id/caseData_caseOrigin"
android:tag="case_origin_tag"
style="@style/ControlSingleColumnStyle"
app:enumClass="@{caseOriginClass}"
app:nullable="false"
app:required="true"
app:value="@={data.caseOrigin}" />

<de.symeda.sormas.app.component.controls.ControlSpinnerField
android:id="@+id/caseData_caseTransmissionClassification"
style="@style/ControlSingleColumnStyle"
app:required="true"
app:value="@={data.caseTransmissionClassification}" />

<de.symeda.sormas.app.component.controls.ControlSpinnerField
android:id="@+id/caseData_disease"
android:tag="disease_tag"
Expand Down Expand Up @@ -123,6 +108,28 @@
app:customizableEnumValue="@{Boolean.TRUE}"
style="@style/ControlSingleColumnStyle" />

<de.symeda.sormas.app.component.controls.ControlSwitchField
android:id="@+id/caseData_caseOrigin"
android:tag="case_origin_tag"
style="@style/ControlSingleColumnStyle"
app:enumClass="@{caseOriginClass}"
app:nullable="false"
app:required="true"
app:value="@={data.caseOrigin}" />

<de.symeda.sormas.app.component.controls.ControlSpinnerField
android:id="@+id/caseData_caseTransmissionClassification"
style="@style/ControlSingleColumnStyle"
app:required="true"
app:value="@={data.caseTransmissionClassification}" />

<de.symeda.sormas.app.component.controls.ControlTextEditField
android:id="@+id/caseData_epidNumber"
android:tag="epid_number_tag"
app:value="@={data.epidNumber}"
app:userViewRight="@{UserRight.CASE_CHANGE_EPID_NUMBER}"
style="@style/ControlSingleColumnStyle" />

<TextView
android:id="@+id/caseData_headingCaseResponsibleJurisidction"
android:layout_width="match_parent"
Expand Down Expand Up @@ -255,13 +262,6 @@
app:required="true"
app:value="@={data.pointOfEntryDetails}" />

<de.symeda.sormas.app.component.controls.ControlTextEditField
android:id="@+id/caseData_epidNumber"
android:tag="epid_number_tag"
app:value="@={data.epidNumber}"
app:userViewRight="@{UserRight.CASE_CHANGE_EPID_NUMBER}"
style="@style/ControlSingleColumnStyle" />

<LinearLayout
android:id="@+id/token_fields_layout"
android:layout_width="match_parent"
Expand Down

0 comments on commit 0fd90de

Please sign in to comment.