private void fillNameDetails(PersonName name) { if (name == null) return; form.ctnDemog().cmbTitle().setValue(name.getTitle()); form.ctnDemog().txtSurname().setValue(name.getSurname()); form.ctnDemog().txtForename().setValue(name.getForename()); form.ctnDemog().txtMidName().setValue(name.getMiddleName()); }
private PersonName getMosName() { PersonName name = new PersonName(); name.setTitle(form.ctnDemog().cmbTitle().getValue()); name.setSurname(form.ctnDemog().txtSurname().getValue()); name.setForename(form.ctnDemog().txtForename().getValue()); name.setMiddleName(form.ctnDemog().txtMidName().getValue()); // name.setUpperSurname(form.ctnDemog().txtSurname().getValue().toUpperCase()); // name.setUpperForename(form.ctnDemog().txtForename().getValue().toUpperCase()); return name; }
protected void onQmbAuthoringCPTextSubmited(String value) throws PresentationLogicException { form.qmbAuthoringCP().clear(); HcpFilter filter = new HcpFilter(); PersonName name = new PersonName(); name.setSurname(value); filter.setQueryName(name); HcpCollection coll = domain.listHCPs(filter); for (int i = 0; i < coll.size(); i++) { Hcp med = coll.get(i); form.qmbAuthoringCP().newRow(med, med.toString()); } if (coll.size() == 1) form.qmbAuthoringCP().setValue(coll.get(0)); else if (coll.size() > 1) form.qmbAuthoringCP().showOpened(); }
protected void onFormOpen() throws ims.framework.exceptions.FormOpenException { if (form.getGlobalContext().Core.getOtherNamesIsNotNull()) { PersonNameCollection names = form.getGlobalContext().Core.getOtherNames(); GenForm.grdNamesRow row; if (names != null) { for (int i = 0; i < names.size(); i++) { ims.core.vo.PersonName name = names.get(i); row = form.grdNames().getRows().newRow(); if (name.getNameTypeIsNotNull()) row.setcolNameType(name.getNameType().getText()); if (name.getForenameIsNotNull()) // WDEV-14050 { row.setcolName(name.getForename() + " " + name.getSurname()); } else row.setcolName(name.getSurname()); } } } // Unless using local patient registration, this form should go to view mode only if (!ConfigFlag.DOM.LOCAL_PATIENT_REGISTRATION.getValue() || form.getGlobalContext().Core.getParentFormMode().equals(FormMode.VIEW)) form.setMode(FormMode.VIEW); }
public int compare(Object ob1, Object ob2) { PersonName pdate1 = null; PersonName pdate2 = null; if (ob1 instanceof NurseVo) { NurseVo ps1 = (NurseVo) ob1; pdate1 = ps1.getMosIsNotNull() && ps1.getMos().getNameIsNotNull() ? ps1.getMos().getName() : null; } if (ob2 instanceof NurseVo) { NurseVo ps2 = (NurseVo) ob2; pdate2 = ps2.getMosIsNotNull() && ps2.getMos().getNameIsNotNull() ? ps2.getMos().getName() : null; } if (pdate1 != null) return pdate1.compareTo(pdate2) * direction; if (pdate2 != null) return (-1) * direction; return 0; }
public String getIMosName() { ims.core.vo.PersonName name = getName(); if (name != null) return name.toString(); return null; }