← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 20956: minor fix

 

------------------------------------------------------------
revno: 20956
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2015-11-05 10:38:05 +0700
message:
  minor fix
modified:
  dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/query/QueryUtils.java


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/query/QueryUtils.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/query/QueryUtils.java	2015-11-05 03:16:36 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/query/QueryUtils.java	2015-11-05 03:38:05 +0000
@@ -125,49 +125,6 @@
         return null;
     }
 
-    public static List<org.hibernate.criterion.Order> getHibernateOrders( List<Order> order )
-    {
-        List<org.hibernate.criterion.Order> orders = new ArrayList<>();
-
-        for ( Order o : order )
-        {
-            org.hibernate.criterion.Order hibernateOrder = getHibernateOrder( o );
-
-            if ( hibernateOrder != null )
-            {
-                orders.add( hibernateOrder );
-            }
-        }
-
-        return orders;
-    }
-
-    public static org.hibernate.criterion.Order getHibernateOrder( Order order )
-    {
-        if ( order.getProperty() == null || !order.getProperty().isPersisted() || !order.getProperty().isSimple() )
-        {
-            return null;
-        }
-
-        org.hibernate.criterion.Order criteriaOrder;
-
-        if ( order.isAscending() )
-        {
-            criteriaOrder = org.hibernate.criterion.Order.asc( order.getProperty().getFieldName() );
-        }
-        else
-        {
-            criteriaOrder = org.hibernate.criterion.Order.desc( order.getProperty().getFieldName() );
-        }
-
-        if ( order.isIgnoreCase() )
-        {
-            criteriaOrder.ignoreCase();
-        }
-
-        return criteriaOrder;
-    }
-
     private QueryUtils()
     {
     }