|
58 | 58 | import com.vaadin.v7.ui.ComboBox; |
59 | 59 | import com.vaadin.v7.ui.DateField; |
60 | 60 | import com.vaadin.v7.ui.Field; |
| 61 | +import com.vaadin.v7.ui.OptionGroup; |
61 | 62 | import com.vaadin.v7.ui.TextArea; |
62 | 63 | import com.vaadin.v7.ui.TextField; |
63 | 64 |
|
@@ -223,7 +224,7 @@ public class CaseDataForm extends AbstractEditForm<CaseDataDto> { |
223 | 224 | private CheckBox quarantineReduced; |
224 | 225 | private CheckBox quarantineOrderedVerbally; |
225 | 226 | private CheckBox quarantineOrderedOfficialDocument; |
226 | | - private NullableOptionGroup facilityOrHome; |
| 227 | + private OptionGroup facilityOrHome; |
227 | 228 | private ComboBox facilityTypeGroup; |
228 | 229 | private ComboBox facilityType; |
229 | 230 | private boolean quarantineChangedByFollowUpUntilChange = false; |
@@ -434,7 +435,7 @@ protected void addFields() { |
434 | 435 | ComboBox community = addInfrastructureField(CaseDataDto.COMMUNITY); |
435 | 436 | community.setNullSelectionAllowed(true); |
436 | 437 | community.addStyleName(SOFT_REQUIRED); |
437 | | - facilityOrHome = new NullableOptionGroup(I18nProperties.getCaption(Captions.casePlaceOfStay), TypeOfPlace.getTypesOfPlaceForCases()); |
| 438 | + facilityOrHome = new OptionGroup(I18nProperties.getCaption(Captions.casePlaceOfStay), TypeOfPlace.getTypesOfPlaceForCases()); |
438 | 439 | facilityOrHome.setId("facilityOrHome"); |
439 | 440 | facilityOrHome.setWidth(100, Unit.PERCENTAGE); |
440 | 441 | CssStyles.style(facilityOrHome, ValoTheme.OPTIONGROUP_HORIZONTAL); |
@@ -476,7 +477,7 @@ protected void addFields() { |
476 | 477 | facility)); |
477 | 478 | facilityOrHome.addValueChangeListener(e -> { |
478 | 479 | FieldHelper.removeItems(facility); |
479 | | - if (TypeOfPlace.FACILITY.equals(facilityOrHome.getNullableValue())) { |
| 480 | + if (TypeOfPlace.FACILITY.equals(facilityOrHome.getValue())) { |
480 | 481 |
|
481 | 482 | // default values |
482 | 483 | if (facilityTypeGroup.getValue() == null && !facilityTypeGroup.isReadOnly()) { |
|
0 commit comments