Browse Source

#196 Add template name to table

merge-requests/2/head
Mike Koch 7 years ago
parent
commit
cc58d84311
  1. 12
      admin/manage_users.php
  2. 1
      language/en/text.php

12
admin/manage_users.php

@ -198,7 +198,7 @@ require_once(HESK_PATH . 'inc/show_admin_nav.inc.php');
<th><b><i><?php echo $hesklang['name']; ?></i></b></th>
<th><b><i><?php echo $hesklang['email']; ?></i></b></th>
<th><b><i><?php echo $hesklang['username']; ?></i></b></th>
<th><b><i><?php echo $hesklang['administrator']; ?></i></b></th>
<th><b><i><?php echo $hesklang['permission_template']; ?></i></b></th>
<?php
/* Is user rating enabled? */
if ($hesk_settings['rating'])
@ -310,12 +310,20 @@ while ($myuser = hesk_dbFetchAssoc($res))
}
}
$templateName = $hesklang['custom'];
if ($myuser['permission_template'] != -1) {
$result = hesk_dbQuery("SELECT `name` FROM `".hesk_dbEscape($hesk_settings['db_pfix'])."permission_templates` WHERE `id` = ".intval($myuser['permission_template']));
$row = hesk_dbFetchAssoc($result);
$templateName = $row['name'];
}
echo <<<EOC
<tr>
<td>$myuser[name]</td>
<td><a href="mailto:$myuser[email]">$myuser[email]</a></td>
<td>$myuser[user]</td>
<td>$myuser[isadmin]</td>
<td>$templateName</td>
EOC;

1
language/en/text.php

@ -100,6 +100,7 @@ $hesklang['permission_tpl_man'] = 'Manage permission templates'; // Menu link
$hesklang['permission_templates'] = 'Permission Templates';
$hesklang['can_man_permission_tpl'] = 'Can manage permission templates';
$hesklang['permission_template_colon'] = 'Permission Template:';
$hesklang['permission_template'] = 'Permission Template';
$hesklang['custom'] = 'Custom';
// ADDED OR MODIFIED IN Mods for HESK 2.2.1

Loading…
Cancel
Save