.
This commit is contained in:
@@ -262,6 +262,11 @@ public class CgGeoFencingActivity extends AppCompatActivity implements OnMapRead
|
||||
}
|
||||
|
||||
private void saveGeoFence() {
|
||||
if (careGiverData == null) {
|
||||
Toast.makeText(this, "Couldn't add Fence.", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
Float radius = getRadius();
|
||||
|
||||
if (radius == null) {
|
||||
@@ -290,6 +295,8 @@ public class CgGeoFencingActivity extends AppCompatActivity implements OnMapRead
|
||||
geoFenceDetails.location_name = geofence_bs_binding.location.getText().toString();
|
||||
geoFenceDetails.radius = "" + radius;
|
||||
geoFenceDetails.type = geofence_bs_binding.unitSpinner.getSelectedIndex() == 0?KMS:MILES;
|
||||
geoFenceDetails.patient_xid = "" + careGiverData.patientId;
|
||||
geoFenceDetails.caregiver_xid = "" + careGiverData.caregiver_xid;
|
||||
|
||||
progressDialog.setTitle("Please wait...");
|
||||
progressDialog.setMessage("while we set Geofence for you.");
|
||||
|
||||
@@ -484,8 +484,9 @@ public class CreateContactFragment extends Fragment implements WelcomeContracts.
|
||||
binding.caregiverCheckView.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
boolean default_contact_set = false;
|
||||
if (contactData.phone_number != null){
|
||||
addContactView(contactData.phone_number, true);
|
||||
addContactView(contactData.phone_number, default_contact_set = true);
|
||||
}
|
||||
|
||||
// adding contacts to Contact_rv
|
||||
@@ -493,7 +494,7 @@ public class CreateContactFragment extends Fragment implements WelcomeContracts.
|
||||
String[] phone_numbers = contactData.extra_phone_numbers.split(",");
|
||||
|
||||
for (String phone_number : phone_numbers) {
|
||||
addContactView(phone_number, phone_numbers.length == 1);
|
||||
addContactView(phone_number, phone_numbers.length == 1 && !default_contact_set);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user