From d45720b994f5901cf333ad046a5947ea01d89cd7 Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 10 Nov 2010 09:47:31 +0000 Subject: [PATCH] Updated statistics plugin git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20218 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../generic/statistics/class_statistics.inc | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/gosa-core/plugins/generic/statistics/class_statistics.inc b/gosa-core/plugins/generic/statistics/class_statistics.inc index c0937f8f3..d3b41a28b 100644 --- a/gosa-core/plugins/generic/statistics/class_statistics.inc +++ b/gosa-core/plugins/generic/statistics/class_statistics.inc @@ -61,15 +61,13 @@ class statistics extends plugin $this->graph1DatePicker2 = date('d.m.Y', time()); // First try to retrieve values via RPC - $this->rpcConfigured = FALSE; - if ($this->config->get_cfg_value("core","gosaRpcServer") != ""){ - $this->rpcConfigured = TRUE; - $this->rpcHandle = $this->config->getRpcHandle( - "http://10.3.64.59:4000", - "65717fe6-9e3e-11df-b010-5452005f1250", - "WyukwauWoid2", - TRUE); - } + $this->rpcConfigured = TRUE; + $this->rpcHandle = $this->config->getRpcHandle( + $this->config->registration->getRegistrationServer(), + $this->config->getInstanceUUID(), + $this->config->getInstancePassword(), + TRUE); + $this->initialized = TRUE; } } @@ -161,7 +159,7 @@ class statistics extends plugin // If we have an unregistered instance of GOsa, display a message which // allows to registrate GOsa - if(!$this->instanceRegistered){ + if(!$this->instanceRegistered || !$this->serverAccessible){ return($smarty->fetch(get_template_path('statistics.tpl', TRUE))); } -- 2.30.2