use of org.openmrs.module.registrationapp.model.DropdownWidget in project openmrs-module-mirebalais by PIH.
the class PatientRegistrationApp method getCivilStatusQuestion.
public Question getCivilStatusQuestion() {
Question q = new Question();
q.setId("civilStatusLabel");
q.setHeader("zl.registration.patient.civilStatus.question");
q.setLegend("zl.registration.patient.civilStatus.label");
Field f = new Field();
f.setFormFieldName("obs.PIH:CIVIL STATUS");
f.setType("obs");
DropdownWidget w = new DropdownWidget();
w.getConfig().setExpanded(true);
w.getConfig().addOption("PIH:SINGLE OR A CHILD", "zl.registration.patient.civilStatus.single.label");
w.getConfig().addOption("PIH:MARRIED", "zl.registration.patient.civilStatus.married.label");
w.getConfig().addOption("PIH:LIVING WITH PARTNER", "zl.registration.patient.civilStatus.livingWithPartner.label");
w.getConfig().addOption("PIH:SEPARATED", "zl.registration.patient.civilStatus.separated.label");
w.getConfig().addOption("PIH:DIVORCED", "zl.registration.patient.civilStatus.divorced.label");
w.getConfig().addOption("PIH:WIDOWED", "zl.registration.patient.civilStatus.widowed.label");
f.setWidget(toObjectNode(w));
q.addField(f);
return q;
}
use of org.openmrs.module.registrationapp.model.DropdownWidget in project openmrs-module-mirebalais by PIH.
the class PatientRegistrationApp method getReligionQuestion.
public Question getReligionQuestion() {
Question q = new Question();
q.setId("religionLabel");
q.setLegend("zl.registration.patient.religion.label");
q.setHeader("zl.registration.patient.religion.question");
Field f = new Field();
f.setFormFieldName("obs.PIH:Religion");
f.setType("obs");
DropdownWidget w = new DropdownWidget();
w.getConfig().setExpanded(true);
w.getConfig().addOption("PIH:Voodoo", "zl.registration.patient.religion.voodoo.label");
w.getConfig().addOption("PIH:Catholic", "zl.registration.patient.religion.catholic.label");
w.getConfig().addOption("PIH:Baptist", "zl.registration.patient.religion.baptist.label");
w.getConfig().addOption("PIH:Islam", "zl.registration.patient.religion.islam.label");
w.getConfig().addOption("PIH:Pentecostal", "zl.registration.patient.religion.pentecostal.label");
w.getConfig().addOption("PIH:Seventh Day Adventist", "zl.registration.patient.religion.adventist.label");
w.getConfig().addOption("PIH:Jehovah's Witness", "zl.registration.patient.religion.jehovahsWitness.label");
w.getConfig().addOption("PIH:OTHER NON-CODED", "zl.registration.patient.religion.other.label");
f.setWidget(toObjectNode(w));
q.addField(f);
return q;
}
use of org.openmrs.module.registrationapp.model.DropdownWidget in project openmrs-module-mirebalais by PIH.
the class PatientRegistrationApp method getOccupationQuestion.
public Question getOccupationQuestion(Config config) {
Question q = new Question();
q.setId("occupationLabel");
q.setLegend("zl.registration.patient.occupation.label");
q.setHeader("zl.registration.patient.occupation.question");
Field f = new Field();
f.setFormFieldName("obs.PIH:Occupation");
f.setType("obs");
DropdownWidget w = new DropdownWidget();
if (config.getCountry().equals(ConfigDescriptor.Country.HAITI)) {
// ordered alphabetically in French, with Unemployed and Other last
w.getConfig().addOption("PIH:SHEPHERD", "zl.registration.patient.occupation.shepherd.label");
w.getConfig().addOption("PIH:DRIVER", "zl.registration.patient.occupation.driver.label");
w.getConfig().addOption("PIH:COMMERCE", "zl.registration.patient.occupation.commerce.label");
w.getConfig().addOption("PIH:FARMER", "zl.registration.patient.occupation.farmer.label");
w.getConfig().addOption("CIEL:162944", "zl.registration.patient.occupation.civilServant.label");
w.getConfig().addOption("PIH:MANUAL LABORER", "zl.registration.patient.occupation.manualLaborer.label");
w.getConfig().addOption("PIH:HEALTH CARE WORKER", "zl.registration.patient.occupation.healthCareWorker.label");
w.getConfig().addOption("PIH:Zanmi Lasante employee", "zl.registration.patient.occupation.zlStaff.label");
w.getConfig().addOption("PIH:MINER", "zl.registration.patient.occupation.miner.label");
w.getConfig().addOption("PIH:1404", "zl.registration.patient.occupation.housework.label");
w.getConfig().addOption("PIH:HOUSEWORK/FIELDWORK", "zl.registration.patient.occupation.houseworkFieldwork.label");
w.getConfig().addOption("PIH:FACTORY WORKER", "zl.registration.patient.occupation.factoryWorker.label");
w.getConfig().addOption("PIH:Teacher", "zl.registration.patient.occupation.teacher.label");
w.getConfig().addOption("PIH:PROFESSIONAL", "zl.registration.patient.occupation.professional.label");
w.getConfig().addOption("PIH:SHOP OWNER", "zl.registration.patient.occupation.shopOwner.label");
w.getConfig().addOption("CIEL:159674", "zl.registration.patient.occupation.fisherman.label");
w.getConfig().addOption("PIH:RETIRED", "zl.registration.patient.occupation.retired.label");
w.getConfig().addOption("PIH:FRUIT OR VEGETABLE SELLER", "zl.registration.patient.occupation.fruitOrVegetableVendor.label");
w.getConfig().addOption("CIEL:162945", "zl.registration.patient.occupation.marketVendor.label");
w.getConfig().addOption("PIH:STUDENT", "zl.registration.patient.occupation.student.label");
w.getConfig().addOption("PIH:UNEMPLOYED", "zl.registration.patient.occupation.unemployed.label");
w.getConfig().addOption("PIH:OTHER NON-CODED", "zl.registration.patient.occupation.other.label");
} else if (config.getCountry().equals(ConfigDescriptor.Country.LIBERIA) || (config.getCountry().equals(ConfigDescriptor.Country.SIERRA_LEONE))) {
// ordered alphabetically in English, with Unemployed and Other last
w.getConfig().addOption("PIH:BREWER", "zl.registration.patient.occupation.brewer.label");
w.getConfig().addOption("CIEL:162944", "zl.registration.patient.occupation.civilServant.label");
w.getConfig().addOption("PIH:COMMERCE", "zl.registration.patient.occupation.commerce.label");
w.getConfig().addOption("PIH:DRIVER", "zl.registration.patient.occupation.driver.label");
w.getConfig().addOption("PIH:FACTORY WORKER", "zl.registration.patient.occupation.factoryWorker.label");
w.getConfig().addOption("PIH:FARMER", "zl.registration.patient.occupation.farmer.label");
w.getConfig().addOption("CIEL:159674", "zl.registration.patient.occupation.fisherman.label");
w.getConfig().addOption("PIH:FRUIT OR VEGETABLE SELLER", "zl.registration.patient.occupation.fruitOrVegetableVendor.label");
w.getConfig().addOption("PIH:HEALTH CARE WORKER", "zl.registration.patient.occupation.healthCareWorker.label");
w.getConfig().addOption("PIH:1404", "zl.registration.patient.occupation.housework.label");
w.getConfig().addOption("PIH:HOUSEWORK/FIELDWORK", "zl.registration.patient.occupation.houseworkFieldwork.label");
w.getConfig().addOption("PIH:MANUAL LABORER", "zl.registration.patient.occupation.manualLaborer.label");
w.getConfig().addOption("CIEL:162945", "zl.registration.patient.occupation.marketVendor.label");
w.getConfig().addOption("PIH:MINER", "zl.registration.patient.occupation.miner.label");
w.getConfig().addOption("PIH:PROFESSIONAL", "zl.registration.patient.occupation.professional.label");
w.getConfig().addOption("PIH:RETIRED", "zl.registration.patient.occupation.retired.label");
w.getConfig().addOption("PIH:SHEPHERD", "zl.registration.patient.occupation.shepherd.label");
w.getConfig().addOption("PIH:SHOP OWNER", "zl.registration.patient.occupation.shopOwner.label");
w.getConfig().addOption("PIH:STUDENT", "zl.registration.patient.occupation.student.label");
w.getConfig().addOption("PIH:Teacher", "zl.registration.patient.occupation.teacher.label");
w.getConfig().addOption("PIH:UNEMPLOYED", "zl.registration.patient.occupation.unemployed.label");
w.getConfig().addOption("PIH:OTHER NON-CODED", "zl.registration.patient.occupation.other.label");
}
w.getConfig().setExpanded(true);
f.setWidget(toObjectNode(w));
q.addField(f);
return q;
}
use of org.openmrs.module.registrationapp.model.DropdownWidget in project openmrs-module-pihcore by PIH.
the class SectionsHaiti method getOccupationQuestion.
@Override
public Question getOccupationQuestion() {
Question q = new Question();
q.setId("occupationLabel");
q.setLegend("zl.registration.patient.occupation.label");
q.setHeader("zl.registration.patient.occupation.question");
Field f = new Field();
f.setFormFieldName("obs.PIH:Occupation");
f.setType("obs");
DropdownWidget w = new DropdownWidget();
// ordered alphabetically in French, with Unemployed and Other last
w.getConfig().addOption("PIH:Stockbroker", "zl.registration.patient.occupation.stockbroker.label");
w.getConfig().addOption("PIH:Guard", "zl.registration.patient.occupation.guard.label");
w.getConfig().addOption("PIH:Agronomist", "zl.registration.patient.occupation.agronomist.label");
w.getConfig().addOption("PIH:VILLAGE HEALTH WORKER", "zl.registration.patient.occupation.villageHealthWorker.label");
w.getConfig().addOption("PIH:Assistant driver", "zl.registration.patient.occupation.assistantDriver.label");
w.getConfig().addOption("PIH:Archivist", "zl.registration.patient.occupation.archivist.label");
w.getConfig().addOption("PIH:Surveyor", "zl.registration.patient.occupation.surveyor.label");
w.getConfig().addOption("PIH:Artisan", "zl.registration.patient.occupation.artisan.label");
w.getConfig().addOption("PIH:Artist", "zl.registration.patient.occupation.artist.label");
w.getConfig().addOption("PIH:Secretary", "zl.registration.patient.occupation.secretary.label");
w.getConfig().addOption("PIH:LPN", "zl.registration.patient.occupation.licensedPracticalNurse.label");
w.getConfig().addOption("PIH:Lawyer", "zl.registration.patient.occupation.lawyer.label");
w.getConfig().addOption("PIH:SHEPHERD", "zl.registration.patient.occupation.shepherd.label");
w.getConfig().addOption("PIH:Librarian", "zl.registration.patient.occupation.librarian.label");
w.getConfig().addOption("PIH:Lottery worker", "zl.registration.patient.occupation.lotteryWorker.label");
w.getConfig().addOption("PIH:Welder", "zl.registration.patient.occupation.welder.label");
w.getConfig().addOption("PIH:Cashier", "zl.registration.patient.occupation.cashier.label");
w.getConfig().addOption("PIH:Singer", "zl.registration.patient.occupation.singer.label");
w.getConfig().addOption("PIH:Hunter", "zl.registration.patient.occupation.hunter.label");
w.getConfig().addOption("PIH:DRIVER", "zl.registration.patient.occupation.driver.label");
w.getConfig().addOption("PIH:Cook", "zl.registration.patient.occupation.cook.label");
w.getConfig().addOption("PIH:Shoeshiner", "zl.registration.patient.occupation.shoeshiner.label");
w.getConfig().addOption("PIH:COMMERCE", "zl.registration.patient.occupation.commerce.label");
w.getConfig().addOption("PIH:Accountant", "zl.registration.patient.occupation.accountant.label");
w.getConfig().addOption("PIH:Shoemaker", "zl.registration.patient.occupation.shoemaker.label");
w.getConfig().addOption("PIH:Fashion designer", "zl.registration.patient.occupation.fashionDesigner.label");
w.getConfig().addOption("PIH:FARMER", "zl.registration.patient.occupation.farmer.label");
w.getConfig().addOption("PIH:DOCTOR", "zl.registration.patient.occupation.doctor.label");
w.getConfig().addOption("PIH:Cabinetmaker", "zl.registration.patient.occupation.cabinetmaker.label");
w.getConfig().addOption("PIH:Teacher", "zl.registration.patient.occupation.teacher.label");
w.getConfig().addOption("PIH:Electrician", "zl.registration.patient.occupation.electrician.label");
w.getConfig().addOption("PIH:Electronics technician", "zl.registration.patient.occupation.electronicsTechnician.label");
w.getConfig().addOption("PIH:Animal breeder", "zl.registration.patient.occupation.animalBreeder.label");
w.getConfig().addOption("PIH:STUDENT", "zl.registration.patient.occupation.student.label");
w.getConfig().addOption("PIH:Beautician", "zl.registration.patient.occupation.beautician.label");
w.getConfig().addOption("PIH:Florist", "zl.registration.patient.occupation.florist.label");
w.getConfig().addOption("PIH:Football player", "zl.registration.patient.occupation.footballPlayer.label");
w.getConfig().addOption("PIH:Foreman", "zl.registration.patient.occupation.foreman.label");
w.getConfig().addOption("CIEL:162944", "zl.registration.patient.occupation.civilServant.label");
w.getConfig().addOption("PIH:Bodyguard", "zl.registration.patient.occupation.bodyguard.label");
w.getConfig().addOption("PIH:Manager", "zl.registration.patient.occupation.manager.label");
w.getConfig().addOption("PIH:Clerk", "zl.registration.patient.occupation.clerk.label");
w.getConfig().addOption("PIH:Bailiff", "zl.registration.patient.occupation.bailiff.label");
w.getConfig().addOption("PIH:NURSE", "zl.registration.patient.occupation.nurse.label");
w.getConfig().addOption("PIH:Informatician", "zl.registration.patient.occupation.informatician.label");
w.getConfig().addOption("PIH:Electrical engineer", "zl.registration.patient.occupation.electricalEngineer.label");
w.getConfig().addOption("PIH:Customs inspector", "zl.registration.patient.occupation.customsInspector.label");
w.getConfig().addOption("PIH:Journalist", "zl.registration.patient.occupation.journalist.label");
w.getConfig().addOption("PIH:Judge", "zl.registration.patient.occupation.judge.label");
w.getConfig().addOption("PIH:Community leader", "zl.registration.patient.occupation.communityLeader.label");
w.getConfig().addOption("PIH:Laundry worker", "zl.registration.patient.occupation.laundryWorker.label");
w.getConfig().addOption("PIH:Construction worker", "zl.registration.patient.occupation.constructionWorker.label");
w.getConfig().addOption("PIH:Butler", "zl.registration.patient.occupation.butler.label");
w.getConfig().addOption("PIH:FACTORY WORKER", "zl.registration.patient.occupation.factoryWorker.label");
w.getConfig().addOption("PIH:Warehouse worker", "zl.registration.patient.occupation.materialHandler.label");
w.getConfig().addOption("PIH:Matron", "zl.registration.patient.occupation.matron.label");
w.getConfig().addOption("PIH:Mechanic", "zl.registration.patient.occupation.mechanic.label");
w.getConfig().addOption("PIH:Cleaner", "zl.registration.patient.occupation.cleaner.label");
w.getConfig().addOption("PIH:HOUSEWORK/FIELDWORK", "zl.registration.patient.occupation.houseworkFieldwork.label");
w.getConfig().addOption("PIH:Carpenter", "zl.registration.patient.occupation.carpenter.label");
w.getConfig().addOption("PIH:Messenger", "zl.registration.patient.occupation.messenger.label");
w.getConfig().addOption("PIH:MINER", "zl.registration.patient.occupation.miner.label");
w.getConfig().addOption("PIH:Musician", "zl.registration.patient.occupation.musician.label");
w.getConfig().addOption("PIH:MANUAL LABORER", "zl.registration.patient.occupation.manualLaborer.label");
w.getConfig().addOption("PIH:Pastry chef", "zl.registration.patient.occupation.pastryChef.label");
w.getConfig().addOption("PIH:Fisherman", "zl.registration.patient.occupation.fisherman.label");
w.getConfig().addOption("PIH:Personal assistant", "zl.registration.patient.occupation.personalAssistant.label");
w.getConfig().addOption("PIH:HEALTH CARE WORKER", "zl.registration.patient.occupation.healthCareWorker.label");
w.getConfig().addOption("PIH:Photographer", "zl.registration.patient.occupation.photographer.label");
w.getConfig().addOption("PIH:Plumber", "zl.registration.patient.occupation.plumber.label");
w.getConfig().addOption("PIH:Police", "zl.registration.patient.occupation.police.label");
w.getConfig().addOption("PIH:PROFESSIONAL", "zl.registration.patient.occupation.professional.label");
w.getConfig().addOption("PIH:SHOP OWNER", "zl.registration.patient.occupation.shopOwner.label");
w.getConfig().addOption("PIH:Radiologist", "zl.registration.patient.occupation.radiologist.label");
w.getConfig().addOption("PIH:Refrigeration manager", "zl.registration.patient.occupation.refrigerationManager.label");
w.getConfig().addOption("PIH:Waiter", "zl.registration.patient.occupation.waiter.label");
w.getConfig().addOption("PIH:Tailor", "zl.registration.patient.occupation.tailor.label");
w.getConfig().addOption("PIH:Laboratory technician", "zl.registration.patient.occupation.laboratoryTechnician.label");
w.getConfig().addOption("PIH:Bookkeeper", "zl.registration.patient.occupation.bookkeeper.label");
w.getConfig().addOption("PIH:Sex worker", "zl.registration.patient.occupation.sexWorker.label");
w.getConfig().addOption("PIH:Vendor", "zl.registration.patient.occupation.vendor.label");
w.getConfig().addOption("PIH:Zanmi Lasante employee", "zl.registration.patient.occupation.zlStaff.label");
w.getConfig().addOption("PIH:RETIRED", "zl.registration.patient.occupation.retired.label");
w.getConfig().addOption("PIH:UNEMPLOYED", "zl.registration.patient.occupation.unemployed.label");
w.getConfig().addOption("PIH:OTHER NON-CODED", "zl.registration.patient.occupation.other.label");
w.getConfig().setExpanded(true);
w.getConfig().setAutocomplete(true);
f.setWidget(toObjectNode(w));
q.addField(f);
return q;
}
use of org.openmrs.module.registrationapp.model.DropdownWidget in project openmrs-module-pihcore by PIH.
the class SectionsHaiti method getReligionQuestion.
private Question getReligionQuestion() {
Question q = new Question();
q.setId("religionLabel");
q.setLegend("zl.registration.patient.religion.label");
q.setHeader("zl.registration.patient.religion.question");
Field f = new Field();
f.setFormFieldName("obs.PIH:Religion");
f.setType("obs");
DropdownWidget w = new DropdownWidget();
w.getConfig().setExpanded(true);
w.getConfig().addOption("PIH:Voodoo", "zl.registration.patient.religion.voodoo.label");
w.getConfig().addOption("PIH:Catholic", "zl.registration.patient.religion.catholic.label");
w.getConfig().addOption("PIH:Baptist", "zl.registration.patient.religion.baptist.label");
w.getConfig().addOption("PIH:Islam", "zl.registration.patient.religion.islam.label");
w.getConfig().addOption("PIH:Pentecostal", "zl.registration.patient.religion.pentecostal.label");
w.getConfig().addOption("PIH:Seventh Day Adventist", "zl.registration.patient.religion.adventist.label");
w.getConfig().addOption("PIH:Jehovah's Witness", "zl.registration.patient.religion.jehovahsWitness.label");
w.getConfig().addOption("PIH:OTHER NON-CODED", "zl.registration.patient.religion.other.label");
f.setWidget(toObjectNode(w));
q.addField(f);
return q;
}
Aggregations