From e1ceb050e19c7574bca146a8da7047ee4ff456b5 Mon Sep 17 00:00:00 2001
From: Marius Burkard <m.burkard@pixcept.de>
Date: Sun, 10 Jul 2016 05:02:35 -0400
Subject: [PATCH] Merge branch 'stable-3.1'
---
interface/web/vm/lib/module.conf.php | 54 ++++++++++++++++++++++++++++--------------------------
1 files changed, 28 insertions(+), 26 deletions(-)
diff --git a/interface/web/vm/lib/module.conf.php b/interface/web/vm/lib/module.conf.php
index 5d0e2c8..ee5e6b6 100644
--- a/interface/web/vm/lib/module.conf.php
+++ b/interface/web/vm/lib/module.conf.php
@@ -1,39 +1,41 @@
<?php
-$module['name'] = 'vm';
-$module['title'] = 'top_menu_vm';
-$module['template'] = 'module.tpl.htm';
-$module['startpage'] = 'vm/openvz_vm_list.php';
+$module['name'] = 'vm';
+$module['title'] = 'top_menu_vm';
+$module['template'] = 'module.tpl.htm';
+$module['startpage'] = 'vm/openvz_vm_list.php';
$module['tab_width'] = '';
+$module['order'] = '50';
//**** Templates menu
$items = array();
-$items[] = array( 'title' => 'Virtual Servers',
- 'target' => 'content',
- 'link' => 'vm/openvz_vm_list.php',
- 'html_id' => 'openvz_vm_list');
+$items[] = array( 'title' => 'Virtual Servers',
+ 'target' => 'content',
+ 'link' => 'vm/openvz_vm_list.php',
+ 'html_id' => 'openvz_vm_list');
-$items[] = array( 'title' => 'OS Templates',
- 'target' => 'content',
- 'link' => 'vm/openvz_ostemplate_list.php',
- 'html_id' => 'openvz_ostemplate_list');
+if($_SESSION["s"]["user"]["typ"] == 'admin') {
+ $items[] = array( 'title' => 'OS Templates',
+ 'target' => 'content',
+ 'link' => 'vm/openvz_ostemplate_list.php',
+ 'html_id' => 'openvz_ostemplate_list');
-$items[] = array( 'title' => 'VM Templates',
- 'target' => 'content',
- 'link' => 'vm/openvz_template_list.php',
- 'html_id' => 'openvz_template_list');
-
-$items[] = array( 'title' => 'IP addresses',
- 'target' => 'content',
- 'link' => 'vm/openvz_ip_list.php',
- 'html_id' => 'openvz_ip_list');
+ $items[] = array( 'title' => 'VM Templates',
+ 'target' => 'content',
+ 'link' => 'vm/openvz_template_list.php',
+ 'html_id' => 'openvz_template_list');
+ $items[] = array( 'title' => 'IP addresses',
+ 'target' => 'content',
+ 'link' => 'vm/openvz_ip_list.php',
+ 'html_id' => 'openvz_ip_list');
+}
if(count($items))
{
- $module['nav'][] = array( 'title' => 'OpenVZ',
- 'open' => 1,
- 'items' => $items);
+ $module['nav'][] = array( 'title' => 'OpenVZ',
+ 'open' => 1,
+ 'items' => $items);
}
@@ -50,7 +52,7 @@
'target' => 'content',
'link' => 'vm/traffic_stats.php',
'html_id' => 'vm_traffic_stats');
-
+
if(count($items))
{
$module['nav'][] = array( 'title' => 'Statistics',
@@ -64,4 +66,4 @@
-?>
\ No newline at end of file
+?>
--
Gitblit v1.9.1