From: rkv Date: Fri, 19 Apr 2013 16:04:33 +0000 (+0000) Subject: Fix for correct search of study result document type in Postgres. X-Git-Tag: Root_Delivery2_2013_04_22~3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d57a8cca31e1ed5d341c20d2a61dd267ddec239e;p=tools%2Fsiman.git Fix for correct search of study result document type in Postgres. --- diff --git a/Workspace/Siman-Common/src/org/splat/service/StudyServiceImpl.java b/Workspace/Siman-Common/src/org/splat/service/StudyServiceImpl.java index 5657ba5..67a95e5 100644 --- a/Workspace/Siman-Common/src/org/splat/service/StudyServiceImpl.java +++ b/Workspace/Siman-Common/src/org/splat/service/StudyServiceImpl.java @@ -1563,7 +1563,8 @@ public class StudyServiceImpl implements StudyService { @Transactional(readOnly = true) public DocumentType getStudyResultType(final Study study) { DetachedCriteria query = DetachedCriteria.forClass(DocumentType.class) - .addOrder(Order.desc("result")); + .add(Restrictions.isNotNull("result")).addOrder( + Order.desc("result")); return getDocumentTypeDAO().getFirstResult(query); }