add special one first calling

merge-requests/742/head
Elham Rababah 5 years ago
parent 7f3ae19fd2
commit 37e6853976

@ -65,9 +65,13 @@ class _PatientInPatientScreenState extends State<PatientInPatientScreen>
return BaseView<PatientSearchViewModel>(
onModelReady: (model) async {
model.clearPatientList();
if (widget.specialClinic != null)
await model.getSpecialClinicalCareMappingList(
widget.specialClinic.clinicID);
if (widget.specialClinic != null) {
await model
.getSpecialClinicalCareMappingList(widget.specialClinic.clinicID);
requestModel.nursingStationID =
model.specialClinicalCareMappingList[0].nursingStationID;
requestModel.clinicID = 0;
}
model.getInPatientList(requestModel);
},
builder: (_, model, w) =>
@ -101,19 +105,17 @@ class _PatientInPatientScreenState extends State<PatientInPatientScreen>
color: Color(0xFF2B353E),
),
),
if(model.specialClinicalCareMappingList.isNotEmpty &&
widget.specialClinic != null)
if (model.specialClinicalCareMappingList.isNotEmpty &&
widget.specialClinic != null &&
_activeTab != 2)
Container(
width: MediaQuery
.of(context)
.size
.width * .3,
width: MediaQuery.of(context).size.width * .3,
child: DropdownButtonHideUnderline(
child: DropdownButton(
dropdownColor: Colors.white,
iconEnabledColor: Colors.black,
isExpanded: true,
value: selectedMapId == null ? model
dropdownColor: Colors.white,
iconEnabledColor: Colors.black,
isExpanded: true,
value: selectedMapId == null ? model
.specialClinicalCareMappingList[0]
.nursingStationID : selectedMapId,
iconSize: 25,

Loading…
Cancel
Save