Search in sources :

Example 86 with ComboBox

use of com.vaadin.v7.ui.ComboBox in project SORMAS-Project by hzi-braunschweig.

the class CaseFilterForm method addFields.

@Override
protected void addFields() {
    if (!UserRole.isPortHealthUser(UserProvider.getCurrent().getUserRoles())) {
        addField(getContent(), FieldConfiguration.pixelSized(CaseDataDto.CASE_ORIGIN, 140));
    }
    addFields(FieldConfiguration.pixelSized(CaseDataDto.OUTCOME, 140), FieldConfiguration.pixelSized(CaseDataDto.DISEASE, 140));
    addField(FieldConfiguration.pixelSized(CaseDataDto.DISEASE_VARIANT, 140), ComboBox.class);
    if (isConfiguredServer(CountryHelper.COUNTRY_CODE_GERMANY)) {
        addField(FieldConfiguration.pixelSized(CaseDataDto.CASE_CLASSIFICATION, 140));
    } else {
        final ComboBox caseClassification = addField(CaseDataDto.CASE_CLASSIFICATION, ComboBox.class);
        caseClassification.setWidth(140, Sizeable.Unit.PIXELS);
        caseClassification.removeItem(CaseClassification.CONFIRMED_NO_SYMPTOMS);
        caseClassification.removeItem(CaseClassification.CONFIRMED_UNKNOWN_SYMPTOMS);
    }
    addFields(FieldConfiguration.pixelSized(CaseDataDto.FOLLOW_UP_STATUS, 140));
    TextField searchField = addField(FieldConfiguration.withCaptionAndPixelSized(CaseCriteria.CASE_LIKE, I18nProperties.getString(Strings.promptCasesSearchField), 200));
    searchField.setNullRepresentation("");
    TextField personLikeField = addField(FieldConfiguration.withCaptionAndPixelSized(CaseCriteria.PERSON_LIKE, I18nProperties.getString(Strings.promptRelatedPersonLikeField), 200));
    personLikeField.setNullRepresentation("");
    TextField eventSearchField = addField(FieldConfiguration.withCaptionAndPixelSized(CaseCriteria.EVENT_LIKE, I18nProperties.getString(Strings.promptCaseOrContactEventSearchField), 200));
    eventSearchField.setNullRepresentation("");
}
Also used : ComboBox(com.vaadin.v7.ui.ComboBox) TextField(com.vaadin.v7.ui.TextField)

Example 87 with ComboBox

use of com.vaadin.v7.ui.ComboBox in project SORMAS-Project by hzi-braunschweig.

the class SymptomsForm method addFields.

@Override
protected void addFields() {
    if (disease == null || symptomsContext == null) {
        // workaround to stop initialization until disease is set
        return;
    }
    // Add fields
    Label clinicalMeasurementsHeadingLabel = createLabel(I18nProperties.getString(Strings.headingClinicalMeasurements), H3, CLINICAL_MEASUREMENTS_HEADING_LOC);
    Label signsAndSymptomsHeadingLabel = createLabel(I18nProperties.getString(Strings.headingSignsAndSymptoms), H3, SIGNS_AND_SYMPTOMS_HEADING_LOC);
    final Label generalSymptomsHeadingLabel = createLabel(SymptomGroup.GENERAL.toString(), H4, GENERAL_SIGNS_AND_SYMPTOMS_HEADING_LOC);
    final Label respiratorySymptomsHeadingLabel = createLabel(SymptomGroup.RESPIRATORY.toString(), H4, RESPIRATORY_SIGNS_AND_SYMPTOMS_HEADING_LOC);
    final Label cardiovascularSymptomsHeadingLabel = createLabel(SymptomGroup.CARDIOVASCULAR.toString(), H4, CARDIOVASCULAR_SIGNS_AND_SYMPTOMS_HEADING_LOC);
    final Label gastrointestinalSymptomsHeadingLabel = createLabel(SymptomGroup.GASTROINTESTINAL.toString(), H4, GASTROINTESTINAL_SIGNS_AND_SYMPTOMS_HEADING_LOC);
    final Label urinarySymptomsHeadingLabel = createLabel(SymptomGroup.URINARY.toString(), H4, URINARY_SIGNS_AND_SYMPTOMS_HEADING_LOC);
    final Label nervousSystemSymptomsHeadingLabel = createLabel(SymptomGroup.NERVOUS_SYSTEM.toString(), H4, NERVOUS_SYSTEM_SIGNS_AND_SYMPTOMS_HEADING_LOC);
    final Label skinSymptomsHeadingLabel = createLabel(SymptomGroup.SKIN.toString(), H4, SKIN_SIGNS_AND_SYMPTOMS_HEADING_LOC);
    final Label otherSymptomsHeadingLabel = createLabel(SymptomGroup.OTHER.toString(), H4, OTHER_SIGNS_AND_SYMPTOMS_HEADING_LOC);
    DateField onsetDateField = addField(ONSET_DATE, DateField.class);
    ComboBox onsetSymptom = addField(ONSET_SYMPTOM, ComboBox.class);
    if (symptomsContext == SymptomsContext.CASE) {
        // If the symptom onset date is after the hospital admission date, show a warning but don't prevent the user from saving
        onsetDateField.addValueChangeListener(event -> {
            if (caze.getHospitalization().getAdmissionDate() != null && DateTimeComparator.getDateOnlyInstance().compare(caze.getHospitalization().getAdmissionDate(), onsetDateField.getValue()) < 0) {
                onsetDateField.setComponentError(new ErrorMessage() {

                    @Override
                    public ErrorLevel getErrorLevel() {
                        return ErrorLevel.INFO;
                    }

                    @Override
                    public String getFormattedHtmlMessage() {
                        return I18nProperties.getValidationError(Validations.beforeDateSoft, onsetDateField.getCaption(), I18nProperties.getPrefixCaption(HospitalizationDto.I18N_PREFIX, HospitalizationDto.ADMISSION_DATE));
                    }
                });
            } else if (onsetDateField.isValid()) {
                onsetDateField.setComponentError(null);
            }
        });
    }
    ComboBox temperature = addField(TEMPERATURE, ComboBox.class);
    temperature.setImmediate(true);
    for (Float temperatureValue : SymptomsHelper.getTemperatureValues()) {
        temperature.addItem(temperatureValue);
        temperature.setItemCaption(temperatureValue, SymptomsHelper.getTemperatureString(temperatureValue));
    }
    if (symptomsContext == SymptomsContext.CASE) {
        temperature.setCaption(I18nProperties.getCaption(Captions.symptomsMaxTemperature));
    }
    addField(TEMPERATURE_SOURCE);
    ComboBox bloodPressureSystolic = addField(BLOOD_PRESSURE_SYSTOLIC, ComboBox.class);
    bloodPressureSystolic.addItems(SymptomsHelper.getBloodPressureValues());
    ComboBox bloodPressureDiastolic = addField(BLOOD_PRESSURE_DIASTOLIC, ComboBox.class);
    bloodPressureDiastolic.addItems(SymptomsHelper.getBloodPressureValues());
    ComboBox heartRate = addField(HEART_RATE, ComboBox.class);
    heartRate.addItems(SymptomsHelper.getHeartRateValues());
    ComboBox respiratoryRate = addField(RESPIRATORY_RATE, ComboBox.class);
    respiratoryRate.addItems(SymptomsHelper.getRespiratoryRateValues());
    ComboBox weight = addField(WEIGHT, ComboBox.class);
    for (Integer weightValue : SymptomsHelper.getWeightValues()) {
        weight.addItem(weightValue);
        weight.setItemCaption(weightValue, SymptomsHelper.getDecimalString(weightValue));
    }
    ComboBox height = addField(HEIGHT, ComboBox.class);
    height.addItems(SymptomsHelper.getHeightValues());
    ComboBox midUpperArmCircumference = addField(MID_UPPER_ARM_CIRCUMFERENCE, ComboBox.class);
    for (Integer circumferenceValue : SymptomsHelper.getMidUpperArmCircumferenceValues()) {
        midUpperArmCircumference.addItem(circumferenceValue);
        midUpperArmCircumference.setItemCaption(circumferenceValue, SymptomsHelper.getDecimalString(circumferenceValue));
    }
    ComboBox glasgowComaScale = addField(GLASGOW_COMA_SCALE, ComboBox.class);
    glasgowComaScale.addItems(SymptomsHelper.getGlasgowComaScaleValues());
    addFields(VOMITING, DIARRHEA, BLOOD_IN_STOOL, NAUSEA, ABDOMINAL_PAIN, HEADACHE, MUSCLE_PAIN, FATIGUE_WEAKNESS, SKIN_RASH, NECK_STIFFNESS, SORE_THROAT, COUGH, COUGH_WITH_SPUTUM, COUGH_WITH_HEAMOPTYSIS, RUNNY_NOSE, DIFFICULTY_BREATHING, CHEST_PAIN, CONJUNCTIVITIS, EYE_PAIN_LIGHT_SENSITIVE, KOPLIKS_SPOTS, THROBOCYTOPENIA, OTITIS_MEDIA, HEARINGLOSS, DEHYDRATION, ANOREXIA_APPETITE_LOSS, REFUSAL_FEEDOR_DRINK, JOINT_PAIN, HICCUPS, BACKACHE, EYES_BLEEDING, JAUNDICE, DARK_URINE, STOMACH_BLEEDING, RAPID_BREATHING, SWOLLEN_GLANDS, UNEXPLAINED_BLEEDING, GUMS_BLEEDING, INJECTION_SITE_BLEEDING, NOSE_BLEEDING, BLOODY_BLACK_STOOL, RED_BLOOD_VOMIT, DIGESTED_BLOOD_VOMIT, COUGHING_BLOOD, BLEEDING_VAGINA, SKIN_BRUISING, BLOOD_URINE, OTHER_HEMORRHAGIC_SYMPTOMS, OTHER_HEMORRHAGIC_SYMPTOMS_TEXT, OTHER_NON_HEMORRHAGIC_SYMPTOMS, OTHER_NON_HEMORRHAGIC_SYMPTOMS_TEXT, LESIONS, LESIONS_THAT_ITCH, LESIONS_SAME_STATE, LESIONS_SAME_SIZE, LESIONS_DEEP_PROFOUND, LESIONS_FACE, LESIONS_LEGS, LESIONS_SOLES_FEET, LESIONS_PALMS_HANDS, LESIONS_THORAX, LESIONS_ARMS, LESIONS_GENITALS, LESIONS_ALL_OVER_BODY, LYMPHADENOPATHY, LYMPHADENOPATHY_AXILLARY, LYMPHADENOPATHY_CERVICAL, LYMPHADENOPATHY_INGUINAL, CHILLS_SWEATS, BEDRIDDEN, ORAL_ULCERS, PAINFUL_LYMPHADENITIS, BLACKENING_DEATH_OF_TISSUE, BUBOES_GROIN_ARMPIT_NECK, BULGING_FONTANELLE, PHARYNGEAL_ERYTHEMA, PHARYNGEAL_EXUDATE, OEDEMA_FACE_NECK, OEDEMA_LOWER_EXTREMITY, LOSS_SKIN_TURGOR, PALPABLE_LIVER, PALPABLE_SPLEEN, MALAISE, SUNKEN_EYES_FONTANELLE, SIDE_PAIN, FLUID_IN_LUNG_CAVITY, TREMOR, BILATERAL_CATARACTS, UNILATERAL_CATARACTS, CONGENITAL_GLAUCOMA, CONGENITAL_HEART_DISEASE, PIGMENTARY_RETINOPATHY, RADIOLUCENT_BONE_DISEASE, SPLENOMEGALY, MICROCEPHALY, MENINGOENCEPHALITIS, PURPURIC_RASH, DEVELOPMENTAL_DELAY, CONGENITAL_HEART_DISEASE_TYPE, CONGENITAL_HEART_DISEASE_DETAILS, JAUNDICE_WITHIN_24_HOURS_OF_BIRTH, PATIENT_ILL_LOCATION, HYDROPHOBIA, OPISTHOTONUS, ANXIETY_STATES, DELIRIUM, UPROARIOUSNESS, PARASTHESIA_AROUND_WOUND, EXCESS_SALIVATION, INSOMNIA, PARALYSIS, EXCITATION, DYSPHAGIA, AEROPHOBIA, HYPERACTIVITY, PARESIS, AGITATION, ASCENDING_FLACCID_PARALYSIS, ERRATIC_BEHAVIOUR, COMA, CONVULSION, FLUID_IN_LUNG_CAVITY_AUSCULTATION, FLUID_IN_LUNG_CAVITY_XRAY, ABNORMAL_LUNG_XRAY_FINDINGS, CONJUNCTIVAL_INJECTION, ACUTE_RESPIRATORY_DISTRESS_SYNDROME, PNEUMONIA_CLINICAL_OR_RADIOLOGIC, LOSS_OF_TASTE, LOSS_OF_SMELL, WHEEZING, SKIN_ULCERS, INABILITY_TO_WALK, IN_DRAWING_OF_CHEST_WALL, FEELING_ILL, SHIVERING, RESPIRATORY_DISEASE_VENTILATION, FAST_HEART_RATE, OXYGEN_SATURATION_LOWER_94, FEVERISHFEELING, WEAKNESS, FATIGUE, COUGH_WITHOUT_SPUTUM, BREATHLESSNESS, CHEST_PRESSURE, BLUE_LIPS, BLOOD_CIRCULATION_PROBLEMS, PALPITATIONS, DIZZINESS_STANDING_UP, HIGH_OR_LOW_BLOOD_PRESSURE, URINARY_RETENTION, FEVER);
    addField(SYMPTOMS_COMMENTS, TextField.class).setDescription(I18nProperties.getPrefixDescription(I18N_PREFIX, SYMPTOMS_COMMENTS, "") + "\n" + I18nProperties.getDescription(Descriptions.descGdpr));
    addField(LESIONS_ONSET_DATE, DateField.class);
    // complications
    addFields(ALTERED_CONSCIOUSNESS, CONFUSED_DISORIENTED, OTHER_COMPLICATIONS, OTHER_COMPLICATIONS_TEXT, HEMORRHAGIC_SYNDROME, HYPERGLYCEMIA, HYPOGLYCEMIA, MENINGEAL_SIGNS, SEIZURES, SEPSIS, SHOCK);
    monkeypoxImageFieldIds = Arrays.asList(LESIONS_RESEMBLE_IMG1, LESIONS_RESEMBLE_IMG2, LESIONS_RESEMBLE_IMG3, LESIONS_RESEMBLE_IMG4);
    for (String propertyId : monkeypoxImageFieldIds) {
        @SuppressWarnings("rawtypes") Field monkeypoxImageField = addField(propertyId);
        CssStyles.style(monkeypoxImageField, VSPACE_NONE);
    }
    // Set initial visibilities
    initializeVisibilitiesAndAllowedVisibilities();
    initializeAccessAndAllowedAccesses();
    if (symptomsContext != SymptomsContext.CLINICAL_VISIT) {
        setVisible(false, BLOOD_PRESSURE_SYSTOLIC, BLOOD_PRESSURE_DIASTOLIC, HEART_RATE, RESPIRATORY_RATE, WEIGHT, HEIGHT, MID_UPPER_ARM_CIRCUMFERENCE, GLASGOW_COMA_SCALE);
    } else {
        setVisible(false, ONSET_SYMPTOM, ONSET_DATE);
    }
    // Initialize lists
    conditionalBleedingSymptomFieldIds = Arrays.asList(GUMS_BLEEDING, INJECTION_SITE_BLEEDING, NOSE_BLEEDING, BLOODY_BLACK_STOOL, RED_BLOOD_VOMIT, DIGESTED_BLOOD_VOMIT, EYES_BLEEDING, COUGHING_BLOOD, BLEEDING_VAGINA, SKIN_BRUISING, STOMACH_BLEEDING, BLOOD_URINE, OTHER_HEMORRHAGIC_SYMPTOMS);
    lesionsFieldIds = Arrays.asList(LESIONS_SAME_STATE, LESIONS_SAME_SIZE, LESIONS_DEEP_PROFOUND, LESIONS_THAT_ITCH);
    lesionsLocationFieldIds = Arrays.asList(LESIONS_FACE, LESIONS_LEGS, LESIONS_SOLES_FEET, LESIONS_PALMS_HANDS, LESIONS_THORAX, LESIONS_ARMS, LESIONS_GENITALS, LESIONS_ALL_OVER_BODY);
    unconditionalSymptomFieldIds = Arrays.asList(FEVER, ABNORMAL_LUNG_XRAY_FINDINGS, CONJUNCTIVAL_INJECTION, ACUTE_RESPIRATORY_DISTRESS_SYNDROME, PNEUMONIA_CLINICAL_OR_RADIOLOGIC, VOMITING, DIARRHEA, BLOOD_IN_STOOL, NAUSEA, ABDOMINAL_PAIN, HEADACHE, MUSCLE_PAIN, FATIGUE_WEAKNESS, SKIN_RASH, NECK_STIFFNESS, SORE_THROAT, COUGH, COUGH_WITH_SPUTUM, COUGH_WITH_HEAMOPTYSIS, RUNNY_NOSE, DIFFICULTY_BREATHING, CHEST_PAIN, CONJUNCTIVITIS, EYE_PAIN_LIGHT_SENSITIVE, KOPLIKS_SPOTS, THROBOCYTOPENIA, OTITIS_MEDIA, HEARINGLOSS, DEHYDRATION, ANOREXIA_APPETITE_LOSS, REFUSAL_FEEDOR_DRINK, JOINT_PAIN, HICCUPS, BACKACHE, JAUNDICE, DARK_URINE, RAPID_BREATHING, SWOLLEN_GLANDS, UNEXPLAINED_BLEEDING, OTHER_NON_HEMORRHAGIC_SYMPTOMS, LESIONS, LYMPHADENOPATHY, LYMPHADENOPATHY_AXILLARY, LYMPHADENOPATHY_CERVICAL, LYMPHADENOPATHY_INGUINAL, CHILLS_SWEATS, BEDRIDDEN, ORAL_ULCERS, PAINFUL_LYMPHADENITIS, BLACKENING_DEATH_OF_TISSUE, BUBOES_GROIN_ARMPIT_NECK, BULGING_FONTANELLE, PHARYNGEAL_ERYTHEMA, PHARYNGEAL_EXUDATE, OEDEMA_FACE_NECK, OEDEMA_LOWER_EXTREMITY, LOSS_SKIN_TURGOR, PALPABLE_LIVER, PALPABLE_SPLEEN, MALAISE, SUNKEN_EYES_FONTANELLE, SIDE_PAIN, FLUID_IN_LUNG_CAVITY, FLUID_IN_LUNG_CAVITY_AUSCULTATION, FLUID_IN_LUNG_CAVITY_XRAY, TREMOR, BILATERAL_CATARACTS, UNILATERAL_CATARACTS, CONGENITAL_GLAUCOMA, CONGENITAL_HEART_DISEASE, RADIOLUCENT_BONE_DISEASE, SPLENOMEGALY, MICROCEPHALY, MENINGOENCEPHALITIS, DEVELOPMENTAL_DELAY, PURPURIC_RASH, PIGMENTARY_RETINOPATHY, CONVULSION, AEROPHOBIA, AGITATION, ANXIETY_STATES, ASCENDING_FLACCID_PARALYSIS, COMA, DELIRIUM, DYSPHAGIA, ERRATIC_BEHAVIOUR, EXCESS_SALIVATION, EXCITATION, HYDROPHOBIA, HYPERACTIVITY, INSOMNIA, OPISTHOTONUS, PARALYSIS, PARASTHESIA_AROUND_WOUND, PARESIS, UPROARIOUSNESS, LOSS_OF_TASTE, LOSS_OF_SMELL, WHEEZING, SKIN_ULCERS, INABILITY_TO_WALK, IN_DRAWING_OF_CHEST_WALL, OTHER_COMPLICATIONS, FEELING_ILL, SHIVERING, RESPIRATORY_DISEASE_VENTILATION, FAST_HEART_RATE, OXYGEN_SATURATION_LOWER_94, FEVERISHFEELING, WEAKNESS, FATIGUE, COUGH_WITHOUT_SPUTUM, BREATHLESSNESS, CHEST_PRESSURE, BLUE_LIPS, BLOOD_CIRCULATION_PROBLEMS, PALPITATIONS, DIZZINESS_STANDING_UP, HIGH_OR_LOW_BLOOD_PRESSURE, URINARY_RETENTION, // complications
    ALTERED_CONSCIOUSNESS, CONFUSED_DISORIENTED, HEMORRHAGIC_SYNDROME, HYPERGLYCEMIA, HYPOGLYCEMIA, MENINGEAL_SIGNS, SEIZURES, SEPSIS, SHOCK);
    // Set visibilities
    NullableOptionGroup feverField = (NullableOptionGroup) getFieldGroup().getField(FEVER);
    feverField.setImmediate(true);
    FieldHelper.setVisibleWhen(getFieldGroup(), conditionalBleedingSymptomFieldIds, UNEXPLAINED_BLEEDING, Arrays.asList(SymptomState.YES), true);
    FieldHelper.setVisibleWhen(getFieldGroup(), OTHER_HEMORRHAGIC_SYMPTOMS_TEXT, OTHER_HEMORRHAGIC_SYMPTOMS, Arrays.asList(SymptomState.YES), true);
    FieldHelper.setVisibleWhen(getFieldGroup(), OTHER_NON_HEMORRHAGIC_SYMPTOMS_TEXT, OTHER_NON_HEMORRHAGIC_SYMPTOMS, Arrays.asList(SymptomState.YES), true);
    FieldHelper.setVisibleWhen(getFieldGroup(), OTHER_COMPLICATIONS_TEXT, OTHER_COMPLICATIONS, Arrays.asList(SymptomState.YES), true);
    FieldHelper.setVisibleWhen(getFieldGroup(), lesionsFieldIds, LESIONS, Arrays.asList(SymptomState.YES), true);
    FieldHelper.setVisibleWhen(getFieldGroup(), lesionsLocationFieldIds, LESIONS, Arrays.asList(SymptomState.YES), true);
    FieldHelper.setVisibleWhen(getFieldGroup(), LESIONS_ONSET_DATE, LESIONS, Arrays.asList(SymptomState.YES), true);
    FieldHelper.setVisibleWhen(getFieldGroup(), CONGENITAL_HEART_DISEASE_TYPE, CONGENITAL_HEART_DISEASE, Arrays.asList(SymptomState.YES), true);
    FieldHelper.setVisibleWhen(getFieldGroup(), CONGENITAL_HEART_DISEASE_DETAILS, CONGENITAL_HEART_DISEASE_TYPE, Arrays.asList(CongenitalHeartDiseaseType.OTHER), true);
    if (isVisibleAllowed(getFieldGroup().getField(JAUNDICE_WITHIN_24_HOURS_OF_BIRTH))) {
        FieldHelper.setVisibleWhen(getFieldGroup(), JAUNDICE_WITHIN_24_HOURS_OF_BIRTH, JAUNDICE, Arrays.asList(SymptomState.YES), true);
    }
    FieldHelper.addSoftRequiredStyle(getField(LESIONS_ONSET_DATE));
    boolean isInfant = person != null && person.getApproximateAge() != null && ((person.getApproximateAge() <= 12 && person.getApproximateAgeType() == ApproximateAgeType.MONTHS) || person.getApproximateAge() <= 1);
    if (!isInfant) {
        getFieldGroup().getField(BULGING_FONTANELLE).setVisible(false);
    }
    // Handle visibility of lesions locations caption
    Label lesionsLocationsCaption = new Label(I18nProperties.getCaption(Captions.symptomsLesionsLocations));
    CssStyles.style(lesionsLocationsCaption, VSPACE_3);
    getContent().addComponent(lesionsLocationsCaption, LESIONS_LOCATIONS_LOC);
    getContent().getComponent(LESIONS_LOCATIONS_LOC).setVisible(FieldHelper.getNullableSourceFieldValue(getFieldGroup().getField(LESIONS)) == SymptomState.YES);
    getFieldGroup().getField(LESIONS).addValueChangeListener(e -> {
        getContent().getComponent(LESIONS_LOCATIONS_LOC).setVisible(FieldHelper.getNullableSourceFieldValue((Field) e.getProperty()) == SymptomState.YES);
    });
    // Symptoms hint text
    Label symptomsHint = new Label(I18nProperties.getString(symptomsContext == SymptomsContext.CASE ? Strings.messageSymptomsHint : Strings.messageSymptomsVisitHint), ContentMode.HTML);
    symptomsHint.setWidth(100, Unit.PERCENTAGE);
    getContent().addComponent(symptomsHint, SYMPTOMS_HINT_LOC);
    if (disease == Disease.MONKEYPOX) {
        setUpMonkeypoxVisibilities();
    }
    if (symptomsContext != SymptomsContext.CASE) {
        getFieldGroup().getField(PATIENT_ILL_LOCATION).setVisible(false);
    }
    symptomGroupMap.forEach((location, strings) -> {
        final Component groupLabel = getContent().getComponent(location);
        final Optional<String> groupHasVisibleSymptom = strings.stream().filter(s -> getFieldGroup().getField(s).isVisible()).findAny();
        if (!groupHasVisibleSymptom.isPresent()) {
            groupLabel.setVisible(false);
        }
    });
    if (isEditableAllowed(OTHER_HEMORRHAGIC_SYMPTOMS_TEXT)) {
        FieldHelper.setRequiredWhen(getFieldGroup(), getFieldGroup().getField(OTHER_HEMORRHAGIC_SYMPTOMS), Arrays.asList(OTHER_HEMORRHAGIC_SYMPTOMS_TEXT), Arrays.asList(SymptomState.YES), disease);
    }
    if (isEditableAllowed(OTHER_NON_HEMORRHAGIC_SYMPTOMS_TEXT)) {
        FieldHelper.setRequiredWhen(getFieldGroup(), getFieldGroup().getField(OTHER_NON_HEMORRHAGIC_SYMPTOMS), Arrays.asList(OTHER_NON_HEMORRHAGIC_SYMPTOMS_TEXT), Arrays.asList(SymptomState.YES), disease);
    }
    if (isEditableAllowed(OTHER_COMPLICATIONS_TEXT)) {
        FieldHelper.setRequiredWhen(getFieldGroup(), getFieldGroup().getField(OTHER_COMPLICATIONS), Arrays.asList(OTHER_COMPLICATIONS_TEXT), Arrays.asList(SymptomState.YES), disease);
    }
    FieldHelper.setRequiredWhen(getFieldGroup(), getFieldGroup().getField(LESIONS), lesionsFieldIds, Arrays.asList(SymptomState.YES), disease);
    FieldHelper.setRequiredWhen(getFieldGroup(), getFieldGroup().getField(LESIONS), monkeypoxImageFieldIds, Arrays.asList(SymptomState.YES), disease);
    addListenerForOnsetFields(onsetSymptom, onsetDateField);
    Button clearAllButton = ButtonHelper.createButton(Captions.actionClearAll, event -> {
        for (Object symptomId : unconditionalSymptomFieldIds) {
            getFieldGroup().getField(symptomId).setValue(null);
        }
        for (Object symptomId : conditionalBleedingSymptomFieldIds) {
            getFieldGroup().getField(symptomId).setValue(null);
        }
        for (Object symptomId : lesionsFieldIds) {
            getFieldGroup().getField(symptomId).setValue(null);
        }
        for (Object symptomId : lesionsLocationFieldIds) {
            getFieldGroup().getField(symptomId).setValue(null);
        }
        for (Object symptomId : monkeypoxImageFieldIds) {
            getFieldGroup().getField(symptomId).setValue(null);
        }
    }, ValoTheme.BUTTON_LINK);
    Button setEmptyToNoButton = createButtonSetClearedToSymptomState(Captions.symptomsSetClearedToNo, SymptomState.NO);
    Button setEmptyToUnknownButton = createButtonSetClearedToSymptomState(Captions.symptomsSetClearedToUnknown, SymptomState.UNKNOWN);
    // Complications heading - not displayed for Rubella (dirty, should be made generic)
    Label complicationsHeading = new Label(I18nProperties.getString(Strings.headingComplications));
    CssStyles.style(complicationsHeading, CssStyles.H3);
    if (disease != Disease.CONGENITAL_RUBELLA && !isConfiguredServer("de")) {
        getContent().addComponent(complicationsHeading, COMPLICATIONS_HEADING);
    }
    HorizontalLayout buttonsLayout = new HorizontalLayout();
    buttonsLayout.addComponent(clearAllButton);
    buttonsLayout.addComponent(setEmptyToNoButton);
    buttonsLayout.addComponent(setEmptyToUnknownButton);
    buttonsLayout.setDefaultComponentAlignment(Alignment.MIDDLE_CENTER);
    buttonsLayout.setMargin(new MarginInfo(true, false, true, true));
    getContent().addComponent(buttonsLayout, BUTTONS_LOC);
    if (feverField.isVisible()) {
        temperature.addValueChangeListener(e -> {
            toggleFeverComponentError(feverField, temperature);
        });
        feverField.addValueChangeListener(e -> {
            toggleFeverComponentError(feverField, temperature);
        });
    }
}
Also used : NullableOptionGroup(de.symeda.sormas.ui.utils.NullableOptionGroup) ThemeResource(com.vaadin.server.ThemeResource) AbstractEditForm(de.symeda.sormas.ui.utils.AbstractEditForm) H3(de.symeda.sormas.ui.utils.CssStyles.H3) Arrays(java.util.Arrays) ApproximateAgeType(de.symeda.sormas.api.person.ApproximateAgeType) H4(de.symeda.sormas.ui.utils.CssStyles.H4) ConversionException(com.vaadin.v7.data.util.converter.Converter.ConversionException) AbstractField(com.vaadin.v7.ui.AbstractField) Date(java.util.Date) I18nProperties(de.symeda.sormas.api.i18n.I18nProperties) VisitStatus(de.symeda.sormas.api.visit.VisitStatus) Alignment(com.vaadin.ui.Alignment) PersonDto(de.symeda.sormas.api.person.PersonDto) CssStyles(de.symeda.sormas.ui.utils.CssStyles) Map(java.util.Map) VSPACE_3(de.symeda.sormas.ui.utils.CssStyles.VSPACE_3) LayoutUtil.fluidRow(de.symeda.sormas.ui.utils.LayoutUtil.fluidRow) ValoTheme(com.vaadin.ui.themes.ValoTheme) ViewMode(de.symeda.sormas.ui.utils.ViewMode) Predicate(java.util.function.Predicate) ComboBox(com.vaadin.v7.ui.ComboBox) Set(java.util.Set) CaseDataDto(de.symeda.sormas.api.caze.CaseDataDto) Field(com.vaadin.v7.ui.Field) FieldHelper(de.symeda.sormas.ui.utils.FieldHelper) Collectors(java.util.stream.Collectors) MarginInfo(com.vaadin.shared.ui.MarginInfo) DateTimeComparator(org.joda.time.DateTimeComparator) LayoutUtil.locsCss(de.symeda.sormas.ui.utils.LayoutUtil.locsCss) List(java.util.List) Stream(java.util.stream.Stream) Optional(java.util.Optional) TextField(com.vaadin.v7.ui.TextField) Descriptions(de.symeda.sormas.api.i18n.Descriptions) UiFieldAccessCheckers(de.symeda.sormas.api.utils.fieldaccess.UiFieldAccessCheckers) LayoutUtil.fluidRowLocsCss(de.symeda.sormas.ui.utils.LayoutUtil.fluidRowLocsCss) LayoutUtil.fluidRowCss(de.symeda.sormas.ui.utils.LayoutUtil.fluidRowCss) FacadeProvider(de.symeda.sormas.api.FacadeProvider) OutbreakFieldVisibilityChecker(de.symeda.sormas.ui.utils.OutbreakFieldVisibilityChecker) HashMap(java.util.HashMap) ErrorLevel(com.vaadin.shared.ui.ErrorLevel) SymptomsContext(de.symeda.sormas.api.symptoms.SymptomsContext) ArrayList(java.util.ArrayList) SymptomGrouping(de.symeda.sormas.api.utils.SymptomGrouping) LayoutUtil.loc(de.symeda.sormas.ui.utils.LayoutUtil.loc) Image(com.vaadin.ui.Image) SymptomState(de.symeda.sormas.api.symptoms.SymptomState) LayoutUtil.locCss(de.symeda.sormas.ui.utils.LayoutUtil.locCss) Label(com.vaadin.ui.Label) SymptomsDto(de.symeda.sormas.api.symptoms.SymptomsDto) NullableOptionGroup(de.symeda.sormas.ui.utils.NullableOptionGroup) LayoutUtil.fluidRowLocs(de.symeda.sormas.ui.utils.LayoutUtil.fluidRowLocs) DateField(com.vaadin.v7.ui.DateField) ButtonHelper(de.symeda.sormas.ui.utils.ButtonHelper) ContentMode(com.vaadin.shared.ui.ContentMode) Validations(de.symeda.sormas.api.i18n.Validations) VSPACE_NONE(de.symeda.sormas.ui.utils.CssStyles.VSPACE_NONE) SymptomGroup(de.symeda.sormas.api.utils.SymptomGroup) ErrorMessage(com.vaadin.server.ErrorMessage) SymptomsHelper(de.symeda.sormas.api.symptoms.SymptomsHelper) Captions(de.symeda.sormas.api.i18n.Captions) FieldGroup(com.vaadin.v7.data.fieldgroup.FieldGroup) Button(com.vaadin.ui.Button) Disease(de.symeda.sormas.api.Disease) HorizontalLayout(com.vaadin.ui.HorizontalLayout) LayoutUtil.fluidColumn(de.symeda.sormas.ui.utils.LayoutUtil.fluidColumn) HospitalizationDto(de.symeda.sormas.api.hospitalization.HospitalizationDto) CongenitalHeartDiseaseType(de.symeda.sormas.api.symptoms.CongenitalHeartDiseaseType) FieldVisibilityCheckers(de.symeda.sormas.api.utils.fieldvisibility.FieldVisibilityCheckers) Comparator(java.util.Comparator) Strings(de.symeda.sormas.api.i18n.Strings) Component(com.vaadin.ui.Component) ComboBox(com.vaadin.v7.ui.ComboBox) Label(com.vaadin.ui.Label) HorizontalLayout(com.vaadin.ui.HorizontalLayout) AbstractField(com.vaadin.v7.ui.AbstractField) Field(com.vaadin.v7.ui.Field) TextField(com.vaadin.v7.ui.TextField) DateField(com.vaadin.v7.ui.DateField) Button(com.vaadin.ui.Button) MarginInfo(com.vaadin.shared.ui.MarginInfo) ErrorLevel(com.vaadin.shared.ui.ErrorLevel) TextField(com.vaadin.v7.ui.TextField) DateField(com.vaadin.v7.ui.DateField) ErrorMessage(com.vaadin.server.ErrorMessage) Component(com.vaadin.ui.Component)

Example 88 with ComboBox

use of com.vaadin.v7.ui.ComboBox in project SORMAS-Project by hzi-braunschweig.

the class TaskEditForm method updateObserversList.

private void updateObserversList() {
    ComboBox assigneeField = getField(TaskDto.ASSIGNEE_USER);
    MultiSelect<UserReferenceDto> observersField = getField(TaskDto.OBSERVER_USERS);
    Collection<UserReferenceDto> selectedObservers = (Collection<UserReferenceDto>) observersField.getValue();
    if (selectedObservers == null) {
        selectedObservers = Collections.emptyList();
    } else {
        // Let's ensure that the collection won't be touched by the following "observersField.removeAllItems()"
        selectedObservers = new ArrayList<>(selectedObservers);
    }
    // Let's ensure that every available users is a choice into the observers field (except the assignee user)
    observersField.removeAllItems();
    for (UserReferenceDto user : availableUsers) {
        if (user.equals(assigneeField.getValue())) {
            // If a user has been assigned to a task, do not make it available for observers field
            continue;
        }
        observersField.addItem(user);
        observersField.setItemCaption(user, user.getCaption());
    }
    // As we removed everything from observers field, let's apply again its value
    Set<UserReferenceDto> filteredObservers = selectedObservers.stream().filter(userReferenceDto -> !userReferenceDto.equals(assigneeField.getValue())).collect(Collectors.toSet());
    observersField.setValue(filteredObservers, true);
}
Also used : UserReferenceDto(de.symeda.sormas.api.user.UserReferenceDto) FeatureType(de.symeda.sormas.api.feature.FeatureType) AbstractEditForm(de.symeda.sormas.ui.utils.AbstractEditForm) DateComparisonValidator(de.symeda.sormas.ui.utils.DateComparisonValidator) FacadeProvider(de.symeda.sormas.api.FacadeProvider) I18nProperties(de.symeda.sormas.api.i18n.I18nProperties) ReferenceDto(de.symeda.sormas.api.ReferenceDto) LayoutUtil.locs(de.symeda.sormas.ui.utils.LayoutUtil.locs) TaskStatusValidator(de.symeda.sormas.ui.utils.TaskStatusValidator) StringUtils(org.apache.commons.lang3.StringUtils) ArrayList(java.util.ArrayList) LayoutUtil.loc(de.symeda.sormas.ui.utils.LayoutUtil.loc) CssStyles(de.symeda.sormas.ui.utils.CssStyles) Map(java.util.Map) Label(com.vaadin.ui.Label) VaadinIcons(com.vaadin.icons.VaadinIcons) UserRole(de.symeda.sormas.api.user.UserRole) NullableOptionGroup(de.symeda.sormas.ui.utils.NullableOptionGroup) UserProvider(de.symeda.sormas.ui.UserProvider) LayoutUtil.fluidRowLocs(de.symeda.sormas.ui.utils.LayoutUtil.fluidRowLocs) LayoutUtil.fluidRow(de.symeda.sormas.ui.utils.LayoutUtil.fluidRow) TaskContext(de.symeda.sormas.api.task.TaskContext) ContentMode(com.vaadin.shared.ui.ContentMode) TaskDto(de.symeda.sormas.api.task.TaskDto) Validations(de.symeda.sormas.api.i18n.Validations) ComboBox(com.vaadin.v7.ui.ComboBox) UserDto(de.symeda.sormas.api.user.UserDto) Collection(java.util.Collection) Set(java.util.Set) FieldHelper(de.symeda.sormas.ui.utils.FieldHelper) Collectors(java.util.stream.Collectors) MultiSelect(de.symeda.sormas.ui.utils.components.MultiSelect) MarginInfo(com.vaadin.shared.ui.MarginInfo) ItemCaptionMode(com.vaadin.v7.ui.AbstractSelect.ItemCaptionMode) TaskType(de.symeda.sormas.api.task.TaskType) UserReferenceDto(de.symeda.sormas.api.user.UserReferenceDto) UserRight(de.symeda.sormas.api.user.UserRight) List(java.util.List) Disease(de.symeda.sormas.api.Disease) HorizontalLayout(com.vaadin.ui.HorizontalLayout) TextArea(com.vaadin.v7.ui.TextArea) DateTimeField(de.symeda.sormas.ui.utils.DateTimeField) FeatureTypeProperty(de.symeda.sormas.api.feature.FeatureTypeProperty) FieldVisibilityCheckers(de.symeda.sormas.api.utils.fieldvisibility.FieldVisibilityCheckers) Strings(de.symeda.sormas.api.i18n.Strings) JurisdictionLevel(de.symeda.sormas.api.user.JurisdictionLevel) Collections(java.util.Collections) ComboBox(com.vaadin.v7.ui.ComboBox) Collection(java.util.Collection)

Example 89 with ComboBox

use of com.vaadin.v7.ui.ComboBox in project SORMAS-Project by hzi-braunschweig.

the class TaskEditForm method addFields.

@Override
protected void addFields() {
    addField(TaskDto.CAZE, ComboBox.class);
    addField(TaskDto.EVENT, ComboBox.class);
    addField(TaskDto.CONTACT, ComboBox.class);
    DateTimeField startDate = addDateField(TaskDto.SUGGESTED_START, DateTimeField.class, -1);
    DateTimeField dueDate = addDateField(TaskDto.DUE_DATE, DateTimeField.class, -1);
    dueDate.setImmediate(true);
    addField(TaskDto.PRIORITY, ComboBox.class);
    NullableOptionGroup taskStatus = addField(TaskDto.TASK_STATUS, NullableOptionGroup.class);
    NullableOptionGroup taskContext = addField(TaskDto.TASK_CONTEXT, NullableOptionGroup.class);
    taskContext.setImmediate(true);
    taskContext.addValueChangeListener(event -> updateByTaskContext());
    ComboBox taskTypeField = addField(TaskDto.TASK_TYPE, ComboBox.class);
    taskTypeField.setItemCaptionMode(ItemCaptionMode.ID_TOSTRING);
    taskTypeField.setImmediate(true);
    taskTypeField.addValueChangeListener(e -> {
        TaskType taskType = (TaskType) e.getProperty().getValue();
        if (taskType != null) {
            setRequired(taskType.isCreatorCommentRequired(), TaskDto.CREATOR_COMMENT);
        }
    });
    ComboBox assigneeUser = addField(TaskDto.ASSIGNEE_USER, ComboBox.class);
    assigneeUser.addValueChangeListener(e -> {
        updateObserversList();
        updateByCreatingAndAssignee();
        checkIfUserEmailOrPhoneIsProvided((UserReferenceDto) e.getProperty().getValue(), Strings.infoAssigneeMissingEmail, Strings.infoAssigneeMissingEmailOrPhoneNumber, ASSIGNEE_MISSING_INFO);
    });
    assigneeUser.setImmediate(true);
    TextArea creatorComment = addField(TaskDto.CREATOR_COMMENT, TextArea.class);
    creatorComment.setRows(2);
    creatorComment.setImmediate(true);
    addField(TaskDto.ASSIGNEE_REPLY, TextArea.class).setRows(4);
    MultiSelect<UserReferenceDto> observerUsers = addField(TaskDto.OBSERVER_USERS, MultiSelect.class);
    observerUsers.addValueChangeListener(e -> {
        Collection<UserReferenceDto> userReferences = (Collection<UserReferenceDto>) e.getProperty().getValue();
        for (UserReferenceDto userReference : userReferences) {
            checkIfUserEmailOrPhoneIsProvided(userReference, Strings.infoObserverMissingEmail, Strings.infoObserverMissingEmailOrPhoneNumber, OBSERVER_MISSING_INFO);
        }
    });
    observerUsers.setImmediate(true);
    CssStyles.style(observerUsers, CssStyles.OPTIONGROUP_MAX_HEIGHT_150);
    setRequired(true, TaskDto.TASK_CONTEXT, TaskDto.TASK_TYPE, TaskDto.ASSIGNEE_USER, TaskDto.DUE_DATE, TaskDto.TASK_STATUS);
    setReadOnly(true, TaskDto.TASK_CONTEXT, TaskDto.CAZE, TaskDto.CONTACT, TaskDto.EVENT);
    addValueChangeListener(e -> {
        TaskDto taskDto = getValue();
        if (taskDto.getTaskType() == TaskType.CASE_INVESTIGATION && taskDto.getCaze() != null) {
            taskStatus.addValidator(new TaskStatusValidator(taskDto.getCaze().getUuid(), I18nProperties.getValidationError(Validations.investigationStatusUnclassifiedCase)));
            if (!editedFromTaskGrid) {
                final HorizontalLayout saveInfoLayout = new HorizontalLayout(new Label(VaadinIcons.INFO_CIRCLE.getHtml() + " " + I18nProperties.getString(Strings.infoSaveOfTask), ContentMode.HTML));
                saveInfoLayout.setSpacing(true);
                saveInfoLayout.setMargin(new MarginInfo(true, false, true, false));
                getContent().addComponent(saveInfoLayout, SAVE_INFO);
            }
        }
        final UserDto userDto = UserProvider.getCurrent().getUser();
        availableUsers = new ArrayList<>();
        if (taskDto.getCaze() != null) {
            availableUsers.addAll(FacadeProvider.getUserFacade().getUsersHavingCaseInJurisdiction(taskDto.getCaze()));
        } else if (taskDto.getContact() != null) {
            availableUsers.addAll(FacadeProvider.getUserFacade().getUsersHavingContactInJurisdiction(taskDto.getContact()));
        } else if (taskDto.getEvent() != null) {
            availableUsers.addAll(FacadeProvider.getUserFacade().getUsersHavingEventInJurisdiction(taskDto.getEvent()));
        } else if (taskDto.getTravelEntry() != null) {
            availableUsers.addAll(FacadeProvider.getUserFacade().getUsersHavingTravelEntryInJurisdiction(taskDto.getTravelEntry()));
        } else {
            availableUsers.addAll(FacadeProvider.getUserFacade().getAllUserRefs(false));
        }
        // For national users, there is no higher level
        if (FacadeProvider.getFeatureConfigurationFacade().isFeatureEnabled(FeatureType.ASSIGN_TASKS_TO_HIGHER_LEVEL) && UserRole.getJurisdictionLevel(userDto.getUserRoles()) != JurisdictionLevel.NATION) {
            List<UserReferenceDto> superordinateUsers = FacadeProvider.getUserFacade().getUsersWithSuperiorJurisdiction(userDto);
            if (superordinateUsers != null) {
                availableUsers.addAll(superordinateUsers);
            }
        }
        // Validation
        startDate.addValidator(new DateComparisonValidator(startDate, dueDate, true, false, I18nProperties.getValidationError(Validations.beforeDate, startDate.getCaption(), dueDate.getCaption())));
        dueDate.addValidator(new DateComparisonValidator(dueDate, startDate, false, false, I18nProperties.getValidationError(Validations.afterDate, dueDate.getCaption(), startDate.getCaption())));
        Map<String, Long> userTaskCounts = FacadeProvider.getTaskFacade().getPendingTaskCountPerUser(availableUsers.stream().map(ReferenceDto::getUuid).collect(Collectors.toList()));
        for (UserReferenceDto user : availableUsers) {
            assigneeUser.addItem(user);
            Long userTaskCount = userTaskCounts.get(user.getUuid());
            assigneeUser.setItemCaption(user, user.getCaption() + " (" + (userTaskCount != null ? userTaskCount.toString() : "0") + ")");
            if (!user.equals(assigneeUser.getValue())) {
                // If a user has been assigned to the task, do not make it available for observers field
                observerUsers.addItem(user);
                observerUsers.setItemCaption(user, user.getCaption());
            }
        }
    });
}
Also used : NullableOptionGroup(de.symeda.sormas.ui.utils.NullableOptionGroup) ReferenceDto(de.symeda.sormas.api.ReferenceDto) UserReferenceDto(de.symeda.sormas.api.user.UserReferenceDto) TextArea(com.vaadin.v7.ui.TextArea) ComboBox(com.vaadin.v7.ui.ComboBox) UserDto(de.symeda.sormas.api.user.UserDto) Label(com.vaadin.ui.Label) DateTimeField(de.symeda.sormas.ui.utils.DateTimeField) TaskDto(de.symeda.sormas.api.task.TaskDto) HorizontalLayout(com.vaadin.ui.HorizontalLayout) DateComparisonValidator(de.symeda.sormas.ui.utils.DateComparisonValidator) UserReferenceDto(de.symeda.sormas.api.user.UserReferenceDto) MarginInfo(com.vaadin.shared.ui.MarginInfo) TaskType(de.symeda.sormas.api.task.TaskType) TaskStatusValidator(de.symeda.sormas.ui.utils.TaskStatusValidator) Collection(java.util.Collection)

Example 90 with ComboBox

use of com.vaadin.v7.ui.ComboBox in project SORMAS-Project by hzi-braunschweig.

the class TaskGridFilterForm method addFields.

@Override
protected void addFields() {
    addField(FieldConfiguration.pixelSized(TaskIndexDto.TASK_CONTEXT, 140));
    addField(FieldConfiguration.pixelSized(TaskIndexDto.TASK_STATUS, 140));
    final UserDto user = currentUserDto();
    if (user.getDistrict() == null) {
        if (user.getRegion() == null) {
            final ComboBox regionField = addField(FieldConfiguration.pixelSized(TaskIndexDto.REGION, 200));
            regionField.addItems(FacadeProvider.getRegionFacade().getAllActiveByServerCountry());
            final ComboBox districtField = addDistrictField();
            districtField.setEnabled(false);
            regionField.addValueChangeListener(e -> {
                RegionReferenceDto region = (RegionReferenceDto) e.getProperty().getValue();
                boolean hasRegion = null != region;
                districtField.setEnabled(hasRegion);
                if (hasRegion) {
                    FieldHelper.updateItems(districtField, FacadeProvider.getDistrictFacade().getAllActiveByRegion(region.getUuid()));
                } else {
                    districtField.setValue(null);
                }
            });
        } else {
            FieldHelper.updateItems(addDistrictField(), FacadeProvider.getDistrictFacade().getAllActiveByRegion(user.getRegion().getUuid()));
        }
    }
    addField(FieldConfiguration.withCaptionAndPixelSized(TaskCriteria.FREE_TEXT, I18nProperties.getString(Strings.promptTaskSearchField), 200));
}
Also used : RegionReferenceDto(de.symeda.sormas.api.infrastructure.region.RegionReferenceDto) ComboBox(com.vaadin.v7.ui.ComboBox) UserDto(de.symeda.sormas.api.user.UserDto)

Aggregations

ComboBox (com.vaadin.v7.ui.ComboBox)113 TextField (com.vaadin.v7.ui.TextField)43 RegionReferenceDto (de.symeda.sormas.api.infrastructure.region.RegionReferenceDto)31 DistrictReferenceDto (de.symeda.sormas.api.infrastructure.district.DistrictReferenceDto)28 Label (com.vaadin.ui.Label)24 Disease (de.symeda.sormas.api.Disease)24 TextArea (com.vaadin.v7.ui.TextArea)19 UserDto (de.symeda.sormas.api.user.UserDto)19 NullableOptionGroup (de.symeda.sormas.ui.utils.NullableOptionGroup)19 DateField (com.vaadin.v7.ui.DateField)18 List (java.util.List)18 CheckBox (com.vaadin.v7.ui.CheckBox)17 FacadeProvider (de.symeda.sormas.api.FacadeProvider)17 I18nProperties (de.symeda.sormas.api.i18n.I18nProperties)17 DateComparisonValidator (de.symeda.sormas.ui.utils.DateComparisonValidator)17 CommunityReferenceDto (de.symeda.sormas.api.infrastructure.community.CommunityReferenceDto)16 AbstractEditForm (de.symeda.sormas.ui.utils.AbstractEditForm)16 Field (com.vaadin.v7.ui.Field)15 FieldVisibilityCheckers (de.symeda.sormas.api.utils.fieldvisibility.FieldVisibilityCheckers)15 Captions (de.symeda.sormas.api.i18n.Captions)14