From 9360a27f15c3615e2d85e0b00293c8b6b8bf4dba Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Wed, 13 Feb 2013 21:41:47 -0300 Subject: [PATCH] Show more rows on history. --- .../main/java/com/wisemapping/dao/MindmapManagerImpl.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/wise-webapp/src/main/java/com/wisemapping/dao/MindmapManagerImpl.java b/wise-webapp/src/main/java/com/wisemapping/dao/MindmapManagerImpl.java index 7b562f0b..281e2fb4 100644 --- a/wise-webapp/src/main/java/com/wisemapping/dao/MindmapManagerImpl.java +++ b/wise-webapp/src/main/java/com/wisemapping/dao/MindmapManagerImpl.java @@ -57,11 +57,9 @@ public class MindmapManagerImpl final Criteria hibernateCriteria = getSession().createCriteria(MindMapHistory.class); hibernateCriteria.add(Restrictions.eq("mindmapId", mindmapId)); hibernateCriteria.addOrder(Order.desc("creationTime")); - // Mientras no haya paginacion solo los 10 primeros // This line throws errors in some environments, so getting all history and taking firsts 10 records - // hibernateCriteria.setMaxResults(10); - List list = hibernateCriteria.list(); - return list.subList(0, (10 < list.size() ? 10 : list.size())); + hibernateCriteria.setMaxResults(30); + return hibernateCriteria.list(); } @Override