@SuppressWarnings("unchecked") public WaterlowAssessmentVo getLastWaterlowForCurrentAdmission(CareContextRefVo careContextRef) { // check at episode of care level that owns the current care context String hql = "select w1_1 from Waterlow as w1_1 join w1_1.careContext as cc WHERE cc.id = :CCID and w1_1.isRIE is null" + " ORDER BY w1_1.dateTimeInitiated desc"; DomainFactory factory = getDomainFactory(); List list = factory.find(hql, new String[] {"CCID"}, new Object[] {careContextRef.getID_CareContext()}); if(list.size() == 0) return null; return WaterlowAssessmentVoAssembler.create((Waterlow) list.get(0)); }
protected WaterlowAssessmentVo populateDataFromScreen() { WaterlowAssessmentVo record = super.populateDataFromScreen(); if(form.getLocalContext().getHcp() != null) record.setHcpInitiated(form.getLocalContext().getHcp()); record.setDateTimeInitiated(new DateTime(form.dteDate().getValue(), form.timTime().getValue())); record.setComment(form.txtComments().getValue()); return record; }
protected WaterlowAssessmentVo populateDataFromScreen(WaterlowAssessmentVo value) { WaterlowAssessmentVo record = super.populateDataFromScreen(value); //we keep the original HCP //if(form.getLocalContext().getHcp() != null) //record.setHcpInitiated(form.getLocalContext().getHcp()); record.setDateTimeInitiated(new DateTime(form.dteDate().getValue(), form.timTime().getValue())); record.setComment(form.txtComments().getValue()); return record; }
protected void populateScreenFromData(WaterlowAssessmentVo value) { super.populateScreenFromData(value); if(value != null) form.txtComments().setValue(value.getComment()); else form.txtComments().setValue(null); }
/** * */ public Boolean isPartOfSkinAssessment(WaterlowAssessmentVo waterRecord) throws DomainInterfaceException { WaterlowDialog impl = (WaterlowDialog)getDomainImpl(WaterlowDialogImpl.class); return impl.isPartOfSkinAssessment(waterRecord); }
/** * getRecord ==> Nursing.WaterlowAssessmentVo */ public ims.nursing.vo.WaterlowAssessmentVo getRecord(Integer recordId) throws ims.domain.exceptions.DomainInterfaceException { DomainFactory factory = getDomainFactory(); Waterlow domAssess = (Waterlow)factory.getDomainObject(Waterlow.class, recordId); return(WaterlowAssessmentVoAssembler.create(domAssess)); }
/** * true if it is Part Of SkinAssessment */ public Boolean isPartOfSkinAssessment(ims.nursing.vo.WaterlowAssessmentVo waterRecord) throws ims.domain.exceptions.DomainInterfaceException { DomainFactory factory = getDomainFactory(); Waterlow domWaterlow = WaterlowAssessmentVoAssembler.extractWaterlow(factory, waterRecord); java.util.List water = factory.find("from SkinComponent s where s.waterlow = :water", "water", domWaterlow); if(water == null || water.size() == 0) return Boolean.FALSE; return Boolean.TRUE; }
public AssessmentHeaderInfo saveRecord(WaterlowAssessmentVo waterRecord, AssessmentHeaderInfo assessment, AssessmentComponent component) throws StaleObjectException { WaterlowDialog impl = (WaterlowDialog) getDomainImpl(WaterlowDialogImpl.class); return impl.saveRecord(waterRecord, assessment, component); }