Code

Updated stats for management classes
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 2 Aug 2010 15:25:09 +0000 (15:25 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 2 Aug 2010 15:25:09 +0000 (15:25 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@19347 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-core/include/class_management.inc
gosa-core/include/class_stats.inc

index 05070256b419b37265c6fecf83aae4ceebc3c737..e4b9c9ac500e193cba50ab45f3ca0b6622eba106 100644 (file)
@@ -203,7 +203,11 @@ class management
 
       $this->snapHandler->setSnapshotBases($bases);
     }
-  
+    // Create statistic table entry 
+    stats::log('management', $class = get_class($this), $this->getAclCategories(),  $action = 'view',
+            $amount = 1, $duration = (microtime(TRUE) - $this->initTime));
     // Display list
     return($this->renderList());
   }
index 2ae68eaf85fe6173773247dcb06e556555a1bdaf..09f9f9726330a35264fe659d50d90a632ea4a3bc 100644 (file)
@@ -568,6 +568,8 @@ class stats
             SELECT PLUGIN, RENDER_TIME AS RM
             FROM {$TABLE_NAME}
             GROUP BY PLUGIN
+            ORDER BY RM DESC
+            LIMIT 10
             ";
         $ret = sqlite_query($query, $res);