diff --git a/admin/manage_permission_templates.php b/admin/manage_permission_groups.php similarity index 71% rename from admin/manage_permission_templates.php rename to admin/manage_permission_groups.php index dc697006..3fd7eddc 100644 --- a/admin/manage_permission_templates.php +++ b/admin/manage_permission_groups.php @@ -39,10 +39,6 @@ if ($action = hesk_REQUEST('a')) { create(); } elseif ($action == 'delete') { deleteTemplate(); - } elseif ($action == 'addadmin') { - toggleAdmin(true); - } elseif ($action == 'deladmin') { - toggleAdmin(false); } } @@ -51,34 +47,20 @@ require_once(HESK_PATH . 'inc/headerAdmin.inc.php'); /* Print main manage users page */ require_once(HESK_PATH . 'inc/show_admin_nav.inc.php'); -?> - - -
@@ -87,9 +69,9 @@ while ($row = hesk_dbFetchAssoc($res)) {

- + + title="">

- + @@ -115,28 +97,11 @@ while ($row = hesk_dbFetchAssoc($res)) { - + ' . $hesklang['enter_valid_email'] . ''; $myuser['user'] = hesk_input(hesk_POST('user')) or $hesk_error_buffer .= '
  • ' . $hesklang['enter_username'] . '
  • '; $myuser['isadmin'] = hesk_POST('template') == '1' ? 1 : 0; - $myuser['template'] = hesk_POST('template'); + $myuser['template'] = hesk_POST('reset-permission-template') === '1' ? -1 : hesk_POST('template'); $myuser['signature'] = hesk_input(hesk_POST('signature')); $myuser['autoassign'] = hesk_POST('autoassign') == 'Y' ? 1 : 0; $myuser['active'] = empty($_POST['active']) ? 0 : 1; diff --git a/inc/profile_functions.inc.php b/inc/profile_functions.inc.php index 71b2ab45..acbad51b 100644 --- a/inc/profile_functions.inc.php +++ b/inc/profile_functions.inc.php @@ -162,9 +162,10 @@ function hesk_profile_tab($session_array = 'new', $is_profile_page = true, $acti if (!$is_profile_page) { ?>
    +
    + class="col-md-3 control-label">
    ' . htmlspecialchars($hesklang['custom']) . ''; echo ''; - outputCheckboxJavascript(); + outputCheckboxJavascript($action); ?>
    + + + +
    - - - - - - - - - - - "> + - + @@ -172,12 +137,10 @@ function createEditModal($template, $features, $categories) { global $hesklang; - $showNotice = true; $disabled = 'checked="checked" disabled'; $enabledFeatures = array(); $enabledCategories = array(); if ($template['heskprivileges'] != 'ALL') { - $showNotice = false; $disabled = ''; $enabledFeatures = explode(',', $template['heskprivileges']); $enabledCategories = explode(',', $template['categories']); @@ -187,30 +150,23 @@ function createEditModal($template, $features, $categories) aria-labelledby="myLargeModalLabel" aria-hidden="true">