public HistoryOfPatientMedsVo getHistoryOfPatientMedsVo(String nHSNumber) { if( nHSNumber == null ) return null; DomainFactory factory = getDomainFactory(); StringBuffer hql = new StringBuffer(); hql.append("select h1_1 from HistoryOfPatientMeds as h1_1 where (h1_1.nHSNumber = :nhsnumber) order by h1_1.systemInformation.creationDateTime desc"); List<?> list = factory.find(hql.toString(), new String[] {"nhsnumber"}, new Object[] {nHSNumber}); if( list != null && list.size() > 0) { HistoryOfPatientMedsVoCollection tempColl = HistoryOfPatientMedsVoAssembler.createHistoryOfPatientMedsVoCollectionFromHistoryOfPatientMeds(list); if( tempColl != null && tempColl.size() == 1) return tempColl.get(0); } return null; }
public HistoryOfPatientMedsVo getHistoryOfPatientMedsVo(String nHSNumber) { if( nHSNumber == null ) return null; DomainFactory factory = getDomainFactory(); StringBuffer hql = new StringBuffer(); hql.append("select h1_1 from HistoryOfPatientMeds as h1_1 where (h1_1.nHSNumber = :nhsnumber) order by h1_1.systemInformation.creationDateTime desc"); List<?> list = factory.find(hql.toString(), new String[] {"nhsnumber"}, new Object[] {nHSNumber}); if( list != null && list.size() > 0) { HistoryOfPatientMedsVoCollection tempColl = HistoryOfPatientMedsVoAssembler.createHistoryOfPatientMedsVoCollectionFromHistoryOfPatientMeds(list); if( tempColl != null && tempColl.size() == 1) //wdev-17117 return tempColl.get(0); } return null; }
public HistoryOfPatientMedsVoCollection getHistoryOfPatientMeds(String nHSNumber) { if( nHSNumber == null ) return null; DomainFactory factory = getDomainFactory(); StringBuffer hql = new StringBuffer(); hql.append("select h1_1 from HistoryOfPatientMeds as h1_1 where (h1_1.nHSNumber = :nhsnumber)"); List<?> list = factory.find(hql.toString(), new String[] {"nhsnumber"}, new Object[] {nHSNumber}); if( list != null && list.size() > 0) return HistoryOfPatientMedsVoAssembler.createHistoryOfPatientMedsVoCollectionFromHistoryOfPatientMeds(list); return null; }