Commit 86cdd1fb authored by Franco Fichtner's avatar Franco Fichtner

users: convert tabs to submenu for #402

parent 99516c07
...@@ -55,15 +55,21 @@ ...@@ -55,15 +55,21 @@
<System_Tunables VisibleName="System Tunables" url="/system_advanced_sysctl.php"/> <System_Tunables VisibleName="System Tunables" url="/system_advanced_sysctl.php"/>
<Notifications url="/system_advanced_notifications.php"/> <Notifications url="/system_advanced_notifications.php"/>
</Settings> </Settings>
<SetupWizard VisibleName="Wizard" url="/wizard.php" cssClass="fa fa-magic"> <Wizard url="/wizard.php" cssClass="fa fa-magic">
<Step url="/wizard.php*"/> <Step url="/wizard.php*"/>
</SetupWizard> </Wizard>
<UserManager VisibleName="Users" url="/system_usermanager.php" cssClass="fa fa-users"> <Users cssClass="fa fa-users">
<Users url="/system_usermanager.php"/> <All url="/system_usermanager.php">
<Groups url="/system_groupmanager.php"/> <Privileges url="/system_usermanager_addprivs.php*"/>
</All>
<Groups url="/system_groupmanager.php">
<Privileges url="/system_groupmanager_addprivs.php*"/>
</Groups>
<Servers url="/system_authservers.php">
<Edit url="/system_authservers.php*"/>
</Servers>
<Settings url="/system_usermanager_settings.php"/> <Settings url="/system_usermanager_settings.php"/>
<Servers url="/system_authservers.php*"/> </Users>
</UserManager>
</System> </System>
<Interfaces order="2" cssClass="glyphicon glyphicon-wrench"> <Interfaces order="2" cssClass="glyphicon glyphicon-wrench">
<Assign VisibleName="(Assign)" order="999" url="/interfaces_assign.php"> <Assign VisibleName="(Assign)" order="999" url="/interfaces_assign.php">
......
...@@ -71,7 +71,7 @@ $radius_srvcs = array( ...@@ -71,7 +71,7 @@ $radius_srvcs = array(
$pgtitle = array(gettext("System"), gettext("Authentication Servers")); $pgtitle = array(gettext('System'), gettext('Users'), gettext('Servers'));
$shortcut_section = "authentication"; $shortcut_section = "authentication";
if (isset($_GET['id']) && is_numericint($_GET['id'])) { if (isset($_GET['id']) && is_numericint($_GET['id'])) {
...@@ -479,15 +479,6 @@ endif; ?> ...@@ -479,15 +479,6 @@ endif; ?>
<section class="col-xs-12"> <section class="col-xs-12">
<?php
$tab_array = array();
$tab_array[] = array(gettext("Users"), false, "system_usermanager.php");
$tab_array[] = array(gettext("Groups"), false, "system_groupmanager.php");
$tab_array[] = array(gettext("Settings"), false, "system_usermanager_settings.php");
$tab_array[] = array(gettext("Servers"), true, "system_authservers.php");
display_top_tabs($tab_array);
?>
<div class="tab-content content-box col-xs-12 table-responsive"> <div class="tab-content content-box col-xs-12 table-responsive">
<?php if ($act == "new" || $act == "edit") : <?php if ($act == "new" || $act == "edit") :
......
<?php <?php
/* /*
Copyright (C) 2014-2015 Deciso B.V. Copyright (C) 2014-2015 Deciso B.V.
Copyright (C) 2008 Shrew Soft Inc. Copyright (C) 2008 Shrew Soft Inc.
...@@ -30,9 +31,9 @@ ...@@ -30,9 +31,9 @@
require_once("guiconfig.inc"); require_once("guiconfig.inc");
$pgtitle = array(gettext("System"), gettext("Group manager")); $pgtitle = array(gettext('System'), gettext('Groups'));
if (!is_array($config['system']['group'])) { if (!isset($config['system']['group'])) {
$config['system']['group'] = array(); $config['system']['group'] = array();
} }
...@@ -250,17 +251,6 @@ function presubmit() { ...@@ -250,17 +251,6 @@ function presubmit() {
?> ?>
<section class="col-xs-12"> <section class="col-xs-12">
<?php
$tab_array = array();
$tab_array[] = array(gettext("Users"), false, "system_usermanager.php");
$tab_array[] = array(gettext("Groups"), true, "system_groupmanager.php");
$tab_array[] = array(gettext("Settings"), false, "system_usermanager_settings.php");
$tab_array[] = array(gettext("Servers"), false, "system_authservers.php");
display_top_tabs($tab_array);
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<?php <?php
......
<?php <?php
/* /*
Copyright (C) 2014-2015 Deciso B.V. Copyright (C) 2014-2015 Deciso B.V.
Copyright (C) 2006 Daniel S. Haischt. Copyright (C) 2006 Daniel S. Haischt.
...@@ -44,7 +45,7 @@ function admin_groups_sort() ...@@ -44,7 +45,7 @@ function admin_groups_sort()
require_once("guiconfig.inc"); require_once("guiconfig.inc");
$pgtitle = array(gettext("System"),gettext("Group manager"),gettext("Add privileges")); $pgtitle = array(gettext('System'), gettext('Groups'), gettext('Privileges'));
if (is_numericint($_GET['groupid'])) { if (is_numericint($_GET['groupid'])) {
$groupid = $_GET['groupid']; $groupid = $_GET['groupid'];
...@@ -163,15 +164,6 @@ function update_description() { ...@@ -163,15 +164,6 @@ function update_description() {
} }
?> ?>
<section class="col-xs-12"> <section class="col-xs-12">
<?php
$tab_array = array();
$tab_array[] = array(gettext("Users"), false, "system_usermanager.php");
$tab_array[] = array(gettext("Groups"), true, "system_groupmanager.php");
$tab_array[] = array(gettext("Settings"), false, "system_usermanager_settings.php");
$tab_array[] = array(gettext("Servers"), false, "system_authservers.php");
display_top_tabs($tab_array);
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<form action="system_groupmanager_addprivs.php" method="post" name="iform" id="iform"> <form action="system_groupmanager_addprivs.php" method="post" name="iform" id="iform">
......
...@@ -75,7 +75,7 @@ function get_user_privdesc(& $user) ...@@ -75,7 +75,7 @@ function get_user_privdesc(& $user)
// start admin user code // start admin user code
$pgtitle = array(gettext("System"),gettext("User Manager")); $pgtitle = array(gettext('System'), gettext('Users'));
// find web ui authentication method // find web ui authentication method
$authcfg_type = auth_get_authserver($config['system']['webgui']['authmode'])['type']; $authcfg_type = auth_get_authserver($config['system']['webgui']['authmode'])['type'];
...@@ -492,16 +492,6 @@ function import_ldap_users() { ...@@ -492,16 +492,6 @@ function import_ldap_users() {
<section class="col-xs-12"> <section class="col-xs-12">
<?php
$tab_array = array();
$tab_array[] = array(gettext("Users"), true, "system_usermanager.php");
$tab_array[] = array(gettext("Groups"), false, "system_groupmanager.php");
$tab_array[] = array(gettext("Settings"), false, "system_usermanager_settings.php");
$tab_array[] = array(gettext("Servers"), false, "system_authservers.php");
display_top_tabs($tab_array);
?>
<div class="tab-content content-box col-xs-12 table-responsive"> <div class="tab-content content-box col-xs-12 table-responsive">
<?php <?php
......
<?php <?php
/* /*
Copyright (C) 2014-2015 Deciso B.V. Copyright (C) 2014-2015 Deciso B.V.
Copyright (C) 2006 Daniel S. Haischt. Copyright (C) 2006 Daniel S. Haischt.
...@@ -44,7 +45,7 @@ function sort_user_privs($privs) { ...@@ -44,7 +45,7 @@ function sort_user_privs($privs) {
} }
$pgtitle = array("System","User manager","Add privileges"); $pgtitle = array(gettext('System'), gettext('Users'),gettext('Privileges'));
if (is_numericint($_GET['userid'])) { if (is_numericint($_GET['userid'])) {
$userid = $_GET['userid']; $userid = $_GET['userid'];
...@@ -155,15 +156,6 @@ function update_description() { ...@@ -155,15 +156,6 @@ function update_description() {
} }
?> ?>
<section class="col-xs-12"> <section class="col-xs-12">
<?php
$tab_array = array();
$tab_array[] = array(gettext("Users"), true, "system_usermanager.php");
$tab_array[] = array(gettext("Groups"), false, "system_groupmanager.php");
$tab_array[] = array(gettext("Settings"), false, "system_usermanager_settings.php");
$tab_array[] = array(gettext("Servers"), false, "system_authservers.php");
display_top_tabs($tab_array);
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<form action="system_usermanager_addprivs.php" method="post" name="iform" id="iform"> <form action="system_usermanager_addprivs.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0" summary="main area" class="table table-striped"> <table width="100%" border="0" cellpadding="6" cellspacing="0" summary="main area" class="table table-striped">
......
<?php <?php
/* /*
Copyright (C) 2014-2015 Deciso B.V. Copyright (C) 2014-2015 Deciso B.V.
Copyright (C) 2007 Scott Ullrich <sullrich@gmail.com> Copyright (C) 2007 Scott Ullrich <sullrich@gmail.com>
...@@ -34,7 +35,7 @@ $pconfig['authmode'] = &$config['system']['webgui']['authmode']; ...@@ -34,7 +35,7 @@ $pconfig['authmode'] = &$config['system']['webgui']['authmode'];
$pconfig['backend'] = &$config['system']['webgui']['backend']; $pconfig['backend'] = &$config['system']['webgui']['backend'];
// Page title for main admin // Page title for main admin
$pgtitle = array(gettext("System"),gettext("User manager settings")); $pgtitle = array(gettext('System'), gettext('Users'), gettext('Settings'));
$save_and_test = false; $save_and_test = false;
if ($_POST) { if ($_POST) {
...@@ -109,16 +110,7 @@ if ($save_and_test) { ...@@ -109,16 +110,7 @@ if ($save_and_test) {
}?> }?>
<section class="col-xs-12"> <section class="col-xs-12">
<?php <?php
$tab_array = array();
$tab_array[] = array(gettext("Users"), false, "system_usermanager.php");
$tab_array[] = array(gettext("Groups"), false, "system_groupmanager.php");
$tab_array[] = array(gettext("Settings"), true, "system_usermanager_settings.php");
$tab_array[] = array(gettext("Servers"), false, "system_authservers.php");
display_top_tabs($tab_array);
/* Default to pfsense backend type if none is defined */ /* Default to pfsense backend type if none is defined */
if (!$pconfig['backend']) { if (!$pconfig['backend']) {
$pconfig['backend'] = "pfsense"; $pconfig['backend'] = "pfsense";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment