summaryrefslogtreecommitdiffstats
path: root/library/Pbs/Graph.php
diff options
context:
space:
mode:
authorSimon2011-03-25 17:39:32 +0100
committerSimon2011-03-25 17:39:32 +0100
commitefa31df88b14a885ce993f682a323bd0ce3b468e (patch)
tree1bad22da0e06e712feca0c034c3ea19537aaebde /library/Pbs/Graph.php
parentgruppengraph nach einloggen in /user/ (diff)
downloadpbs2-efa31df88b14a885ce993f682a323bd0ce3b468e.tar.gz
pbs2-efa31df88b14a885ce993f682a323bd0ce3b468e.tar.xz
pbs2-efa31df88b14a885ce993f682a323bd0ce3b468e.zip
Nicht benötigte Tabellen entfernt, Diagramm wird automatisch generiert, Stats-Controller um Url für Bilder
Diffstat (limited to 'library/Pbs/Graph.php')
-rw-r--r--library/Pbs/Graph.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/library/Pbs/Graph.php b/library/Pbs/Graph.php
index 7711dce..ae3ab16 100644
--- a/library/Pbs/Graph.php
+++ b/library/Pbs/Graph.php
@@ -18,8 +18,14 @@ class Pbs_Graph{
$this->getParentGroups($groupID);
$this->getChildGroups($groupID);
$this->graphstring .= '}';
- $this->graphstring = str_replace(array("\t","\n"),"",$this->graphstring);
- return str_replace('"','\"',$this->graphstring);
+ $this->graphstring = str_replace(array("\t","\n"),"",$this->graphstring);
+ $this->graphstring = str_replace('"','\"',$this->graphstring);
+
+ $str = 'echo "';
+ $str .= $this->graphstring;
+ $str .= '" | dot -Tpng ';
+ passthru($str,$end);
+ return $end;
}
private function getGroupTitle($groupID){
$group = new Application_Model_Group();