Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- * Returns the appointment blocks corresponding to the given date and location.
- *
- * @param date the date to filter by.
- * @param location the location to filter by.
- * @return the appointment blocks that is on the given date and location.
- */
- @Override
- @Transactional(readOnly = true)
- public List<AppointmentBlock> getAppointmentBlocks(String date,Location location) {
- Criteria criteria = sessionFactory.getCurrentSession().createCriteria(AppointmentBlock.class);
- criteria.add(Restrictions.eq("location", location));
- criteria.add(Restrictions.ilike("startDate", date, MatchMode.START));
- return criteria.list();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement