private void searchVTM() { try { VTMVoCollection result = domain.searchVTMByName(form.txtName().getValue(), form.chkHotlistOnly().getValue() ? form.getLocalContext().getSpecialty() : null); form.ccDMD().setValues(result == null ? null : result.toIDMDValueArray(), DMDType.VTM); } catch (DomainInterfaceException e) { engine.showMessage(e.getMessage(), "Error", MessageButtons.OK, MessageIcon.ERROR); } }
private void searchVMP() { try { VMPVoCollection result = domain.searchVMPByName(form.txtName().getValue()); form.ccDMD().setValues(result == null ? null : result.toIDMDValueArray(), DMDType.VMP); } catch (DomainInterfaceException e) { engine.showMessage(e.getMessage(), "Error", MessageButtons.OK, MessageIcon.ERROR); } }
private void searchAMP() { try { AMPVoCollection result = domain.searchAMPByName(form.txtName().getValue()); form.ccDMD().setValues(result == null ? null : result.toIDMDValueArray(), DMDType.AMP); } catch (DomainInterfaceException e) { engine.showMessage(e.getMessage(), "Error", MessageButtons.OK, MessageIcon.ERROR); } }
public void setValue(IDMDValue value, ims.clinical.vo.enums.DMDType selectionLevel) { clearControls(); if(value != null) { setValues(new IDMDValue[] { value }, selectionLevel); } }
public void setValues(IDMDValue[] values, ims.clinical.vo.enums.DMDType selectionLevel) { clearControls(); if(values != null) { for(int x = 0; x < values.length; x++) { IDMDValue value = values[x]; if(value != null && value.getIDMDValueType() != null) { if(value.getIDMDValueType().equals(DMDType.VTM)) { addVTMItem(value); } else if(value.getIDMDValueType().equals(DMDType.VMP)) { addVMPItem(value); } else if(value.getIDMDValueType().equals(DMDType.AMP)) { addAMPItem(value); } } } } setSelectionLevel(selectionLevel); }
private void setSelectionLevel(DMDType selectionLevel) { if(selectionLevel == null) { throw new CodingRuntimeException("Invalid selection level"); } else { form.getLocalContext().setSelectionLevel(selectionLevel); if(selectionLevel == DMDType.AMP) { form.grdVTM().setSelectable(false); form.grdVMP().setSelectable(false); form.grdAMP().setSelectable(true); } else if(selectionLevel == DMDType.VMP) { form.grdVTM().setSelectable(false); form.grdVMP().setSelectable(true); form.grdAMP().setSelectable(true); } else if(selectionLevel == DMDType.VTM) { form.grdVTM().setSelectable(true); form.grdVMP().setSelectable(true); form.grdAMP().setSelectable(true); } } }
public IDMDValue[] searchAMP(IDMDValue vmp) throws DomainInterfaceException { if(vmp == null || vmp.getIDMDValueId() == null || vmp.getIDMDValueType() != DMDType.VMP) throw new DomainInterfaceException("Invalid VMP reference"); AMPVoCollection result = AMPVoAssembler.createAMPVoCollectionFromAMP(getDomainFactory().find("from AMP vm WHERE vm.vMP.id = " + vmp.getIDMDValueId())); if(result != null) return result.toIDMDValueArray(); return new IDMDValue[] {}; }
public IDMDValue[] searchVMP(IDMDValue vtm) throws DomainInterfaceException { if(vtm == null || vtm.getIDMDValueId() == null || vtm.getIDMDValueType() != DMDType.VTM) throw new DomainInterfaceException("Invalid VMP reference"); VMPVoCollection result = VMPVoAssembler.createVMPVoCollectionFromVMP(getDomainFactory().find("from VMP vm WHERE vm.vTM.id = " + vtm.getIDMDValueId())); if(result != null) return result.toIDMDValueArray(); return new IDMDValue[] {}; }