Merge pull request #4198 from sunilpawar/CRM-15332
[civicrm-core.git] / CRM / Case / XMLProcessor / Report.php
index 13d40f6f52e20d9c5e1cb698906866b95892ab72..bdfc9c4ca1c1c6477d2cf5831850fd89f2763385 100644 (file)
@@ -628,7 +628,7 @@ AND    cg.extends = 'Activity'";
       else {
         $query .= "AND cg.extends_entity_column_value IS NULL";
       }
-      $query .= "ORDER BY cf.weight";
+      $query .= "ORDER BY cg.weight, cf.weight";
       $params = array(
         1 => array($activityTypeID,
           'Integer',