Search in sources :

Example 26 with Bundler

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

the class EventParticipantEditActivity method onSaveInstanceState.

@Override
public void onSaveInstanceState(@NonNull Bundle outState) {
    super.onSaveInstanceState(outState);
    new Bundler(outState).setEventUuid(eventUuid);
}
Also used : Bundler(de.symeda.sormas.app.util.Bundler)

Example 27 with Bundler

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

the class EventParticipantNewActivity method onSaveInstanceState.

@Override
public void onSaveInstanceState(@NonNull Bundle outState) {
    super.onSaveInstanceState(outState);
    new Bundler(outState).setEventUuid(eventUuid);
}
Also used : Bundler(de.symeda.sormas.app.util.Bundler)

Example 28 with Bundler

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

the class VaccinationNewActivity method onSaveInstanceState.

@Override
public void onSaveInstanceState(@NonNull Bundle outState) {
    super.onSaveInstanceState(outState);
    new Bundler(outState).setCaseUuid(immunizationUuid);
}
Also used : Bundler(de.symeda.sormas.app.util.Bundler)

Example 29 with Bundler

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

the class PrescriptionNewActivity method onSaveInstanceState.

@Override
public void onSaveInstanceState(@NonNull Bundle outState) {
    super.onSaveInstanceState(outState);
    new Bundler(outState).setCaseUuid(caseUuid);
}
Also used : Bundler(de.symeda.sormas.app.util.Bundler)

Example 30 with Bundler

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

the class SymptomsEditFragment method prepareFragmentData.

@Override
protected void prepareFragmentData() {
    ado = getActivityRootData();
    Person person;
    if (ado instanceof Case) {
        symptomsContext = SymptomsContext.CASE;
        record = ((Case) ado).getSymptoms();
        disease = ((Case) ado).getDisease();
        person = ((Case) ado).getPerson();
    } else if (ado instanceof Visit) {
        symptomsContext = SymptomsContext.VISIT;
        record = ((Visit) ado).getSymptoms();
        disease = ((Visit) ado).getDisease();
        person = ((Visit) ado).getPerson();
    } else if (ado instanceof ClinicalVisit) {
        symptomsContext = SymptomsContext.CLINICAL_VISIT;
        record = ((ClinicalVisit) ado).getSymptoms();
        disease = ((ClinicalVisit) ado).getDisease();
        person = DatabaseHelper.getCaseDao().queryUuidBasic(new Bundler(getArguments()).getCaseUuid()).getPerson();
    } else {
        throw new UnsupportedOperationException("ActivityRootData of class " + ado.getClass().getSimpleName() + " does not support PersonReadFragment");
    }
    isInfant = person.getApproximateAge() != null && ((person.getApproximateAge() <= 12 && person.getApproximateAgeType() == ApproximateAgeType.MONTHS) || person.getApproximateAge() <= 1);
    bodyTempList = getTemperatures(true);
    tempSourceList = DataUtils.getEnumItems(TemperatureSource.class, true);
    congenitalHeartDiseaseList = DataUtils.getEnumItems(CongenitalHeartDiseaseType.class, true);
}
Also used : CongenitalHeartDiseaseType(de.symeda.sormas.api.symptoms.CongenitalHeartDiseaseType) Visit(de.symeda.sormas.app.backend.visit.Visit) ClinicalVisit(de.symeda.sormas.app.backend.clinicalcourse.ClinicalVisit) ClinicalVisit(de.symeda.sormas.app.backend.clinicalcourse.ClinicalVisit) Person(de.symeda.sormas.app.backend.person.Person) TemperatureSource(de.symeda.sormas.api.symptoms.TemperatureSource) Case(de.symeda.sormas.app.backend.caze.Case) Bundler(de.symeda.sormas.app.util.Bundler)

Aggregations

Bundler (de.symeda.sormas.app.util.Bundler)36 FacilityType (de.symeda.sormas.api.infrastructure.facility.FacilityType)2 Case (de.symeda.sormas.app.backend.caze.Case)2 Intent (android.content.Intent)1 Drawable (android.graphics.drawable.Drawable)1 GONE (android.view.View.GONE)1 VISIBLE (android.view.View.VISIBLE)1 Toolbar (androidx.appcompat.widget.Toolbar)1 CountryHelper (de.symeda.sormas.api.CountryHelper)1 Disease (de.symeda.sormas.api.Disease)1 CaseOrigin (de.symeda.sormas.api.caze.CaseOrigin)1 DengueFeverType (de.symeda.sormas.api.caze.DengueFeverType)1 PlagueType (de.symeda.sormas.api.caze.PlagueType)1 RabiesType (de.symeda.sormas.api.caze.RabiesType)1 CustomizableEnumType (de.symeda.sormas.api.customizableenum.CustomizableEnumType)1 DiseaseVariant (de.symeda.sormas.api.disease.DiseaseVariant)1 TypeOfPlace (de.symeda.sormas.api.event.TypeOfPlace)1 FacilityTypeGroup (de.symeda.sormas.api.infrastructure.facility.FacilityTypeGroup)1 PresentCondition (de.symeda.sormas.api.person.PresentCondition)1 Sex (de.symeda.sormas.api.person.Sex)1