Changeset 2473
- Timestamp:
- Jul 31, 2006, 9:11:09 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/www/my_base/index.jsp
r2425 r2473 122 122 Expression today = Expressions.parameter("today"); 123 123 newsQuery.restrict(Restrictions.lteq(Hql.property("startDate"), today)); 124 newsQuery.restrict(Restrictions.gteq(Hql.property("endDate"), today)); 124 newsQuery.restrict( 125 Restrictions.or( 126 Restrictions.gteq(Hql.property("endDate"), today), 127 Restrictions.eq(Hql.property("endDate"), null) 128 ) 129 ); 125 130 newsQuery.order(Orders.desc(Hql.property("newsDate"))); 126 131 newsQuery.setParameter("today", new Date(), Type.DATE);
Note: See TracChangeset
for help on using the changeset viewer.