Search in sources :

Example 1 with BaseEditFragment

use of de.symeda.sormas.app.BaseEditFragment in project SORMAS-Project by hzi-braunschweig.

the class ClinicalVisitNewActivity method buildEditFragment.

@Override
protected BaseEditFragment buildEditFragment(PageMenuItem menuItem, ClinicalVisit activityRootData) {
    BaseEditFragment fragment = ClinicalVisitEditFragment.newInstance(activityRootData);
    fragment.setLiveValidationDisabled(true);
    return fragment;
}
Also used : BaseEditFragment(de.symeda.sormas.app.BaseEditFragment)

Example 2 with BaseEditFragment

use of de.symeda.sormas.app.BaseEditFragment in project SORMAS-Project by hzi-braunschweig.

the class ContactNewActivity method buildEditFragment.

@Override
protected BaseEditFragment buildEditFragment(PageMenuItem menuItem, Contact activityRootData) {
    BaseEditFragment fragment = ContactNewFragment.newInstance(activityRootData);
    fragment.setLiveValidationDisabled(true);
    return fragment;
}
Also used : BaseEditFragment(de.symeda.sormas.app.BaseEditFragment)

Example 3 with BaseEditFragment

use of de.symeda.sormas.app.BaseEditFragment in project SORMAS-Project by hzi-braunschweig.

the class EventEditActivity method buildEditFragment.

@Override
protected BaseEditFragment buildEditFragment(PageMenuItem menuItem, Event activityRootData) {
    EventSection section = EventSection.fromOrdinal(menuItem.getPosition());
    BaseEditFragment fragment;
    switch(section) {
        case EVENT_INFO:
            fragment = EventEditFragment.newInstance(activityRootData);
            break;
        case EVENT_PARTICIPANTS:
            fragment = EventEditPersonsInvolvedListFragment.newInstance(activityRootData);
            break;
        case TASKS:
            fragment = EventEditTaskListFragment.newInstance(activityRootData);
            break;
        default:
            throw new IndexOutOfBoundsException(DataHelper.toStringNullable(section));
    }
    return fragment;
}
Also used : EventSection(de.symeda.sormas.app.event.EventSection) BaseEditFragment(de.symeda.sormas.app.BaseEditFragment)

Example 4 with BaseEditFragment

use of de.symeda.sormas.app.BaseEditFragment in project SORMAS-Project by hzi-braunschweig.

the class EventParticipantEditActivity method buildEditFragment.

@Override
protected BaseEditFragment buildEditFragment(PageMenuItem menuItem, EventParticipant activityRootData) {
    EventParticipantSection section = EventParticipantSection.fromOrdinal(menuItem.getPosition());
    BaseEditFragment fragment;
    switch(section) {
        case EVENT_PARTICIPANT_INFO:
            fragment = EventParticipantEditFragment.newInstance(activityRootData);
            break;
        case IMMUNIZATIONS:
            fragment = EventParticipantEditImmunizationListFragment.newInstance(activityRootData);
            break;
        case VACCINATIONS:
            fragment = EventParticipantEditVaccinationListFragment.newInstance(activityRootData);
            break;
        default:
            throw new IndexOutOfBoundsException(DataHelper.toStringNullable(section));
    }
    return fragment;
}
Also used : EventParticipantSection(de.symeda.sormas.app.event.eventparticipant.EventParticipantSection) BaseEditFragment(de.symeda.sormas.app.BaseEditFragment)

Example 5 with BaseEditFragment

use of de.symeda.sormas.app.BaseEditFragment in project SORMAS-Project by hzi-braunschweig.

the class EventParticipantNewActivity method buildEditFragment.

@Override
protected BaseEditFragment buildEditFragment(PageMenuItem menuItem, EventParticipant activityRootData) {
    BaseEditFragment fragment = EventParticipantNewFragment.newInstance(activityRootData);
    fragment.setLiveValidationDisabled(true);
    return fragment;
}
Also used : BaseEditFragment(de.symeda.sormas.app.BaseEditFragment)

Aggregations

BaseEditFragment (de.symeda.sormas.app.BaseEditFragment)22 Context (android.content.Context)1 AsyncTask (android.os.AsyncTask)1 Disease (de.symeda.sormas.api.Disease)1 MeansOfImmunization (de.symeda.sormas.api.immunization.MeansOfImmunization)1 DataHelper (de.symeda.sormas.api.utils.DataHelper)1 ValidationException (de.symeda.sormas.api.utils.ValidationException)1 BaseActivity (de.symeda.sormas.app.BaseActivity)1 BaseEditActivity (de.symeda.sormas.app.BaseEditActivity)1 R (de.symeda.sormas.app.R)1 DaoException (de.symeda.sormas.app.backend.common.DaoException)1 DatabaseHelper (de.symeda.sormas.app.backend.common.DatabaseHelper)1 Immunization (de.symeda.sormas.app.backend.immunization.Immunization)1 ImmunizationCriteria (de.symeda.sormas.app.backend.immunization.ImmunizationCriteria)1 ImmunizationEditAuthorization (de.symeda.sormas.app.backend.immunization.ImmunizationEditAuthorization)1 ImmunizationSimilarityCriteria (de.symeda.sormas.app.backend.immunization.ImmunizationSimilarityCriteria)1 CaseSection (de.symeda.sormas.app.caze.CaseSection)1 ClinicalVisitSection (de.symeda.sormas.app.clinicalcourse.ClinicalVisitSection)1 PageMenuItem (de.symeda.sormas.app.component.menu.PageMenuItem)1 FragmentValidator (de.symeda.sormas.app.component.validation.FragmentValidator)1