From 4a7ec5d41d722a8e44833ba7c29cd25220f00347 Mon Sep 17 00:00:00 2001 From: Janos SUTO Date: Sun, 15 Apr 2018 18:42:34 +0200 Subject: [PATCH] gui: add support for external dashboard Signed-off-by: Janos SUTO --- config.php.in | 2 ++ webui/controller/health/health.php | 7 ++++++- webui/view/theme/default/templates/health/health.tpl | 6 +++++- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/config.php.in b/config.php.in index 56414af7..89a5c25d 100644 --- a/config.php.in +++ b/config.php.in @@ -37,6 +37,8 @@ $config['THEME'] = 'default'; $config['SITE_NAME'] = 'piler.yourdomain.com'; $config['SITE_URL'] = 'http://piler.yourdomain.com/'; +$config['EXTERNAL_DASHBOARD_URL'] = ''; + $config['SESSION_EXPIRY'] = 3600; $config['ENABLE_SAAS'] = 0; diff --git a/webui/controller/health/health.php b/webui/controller/health/health.php index 64ee754b..cb980212 100644 --- a/webui/controller/health/health.php +++ b/webui/controller/health/health.php @@ -7,7 +7,12 @@ class ControllerHealthHealth extends Controller { $this->id = "content"; $this->template = "health/health.tpl"; - $this->layout = "common/layout"; + if(EXTERNAL_DASHBOARD_URL) { + $this->layout = "common/layout-empty"; + } + else { + $this->layout = "common/layout"; + } $this->load->model('health/health'); diff --git a/webui/view/theme/default/templates/health/health.tpl b/webui/view/theme/default/templates/health/health.tpl index c407a1d8..b8715df5 100644 --- a/webui/view/theme/default/templates/health/health.tpl +++ b/webui/view/theme/default/templates/health/health.tpl @@ -1 +1,5 @@ -
+ + + +
+