mirror of
https://github.com/slawkens/myaac.git
synced 2025-05-02 12:19:20 +02:00
Move account_types to config, account.web_flags to common.php
This commit is contained in:
parent
b918f88776
commit
17eb5426e3
@ -31,13 +31,8 @@ if ($config['account_country']) {
|
||||
foreach ($config['countries'] as $code => $c)
|
||||
$countries[$code] = $c;
|
||||
}
|
||||
$web_acc = array("None", "Admin", "Super Admin", "(Admin + Super Admin)");
|
||||
$acc_type = array("None", "Normal", "Tutor", "Senior Tutor", "Gamemaster", "God");
|
||||
|
||||
$groups = new OTS_Groups_List();
|
||||
if ($groups->getHighestId() == 6) {
|
||||
$acc_type = array("None", "Normal", "Tutor", "Senior Tutor", "Gamemaster", "Community Manager", "God");
|
||||
}
|
||||
$web_acc = ACCOUNT_WEB_FLAGS;
|
||||
$acc_type = config('account_types');
|
||||
?>
|
||||
|
||||
<link rel="stylesheet" type="text/css" href="<?php echo BASE_URL; ?>tools/css/jquery.datetimepicker.css"/ >
|
||||
|
10
common.php
10
common.php
@ -34,8 +34,10 @@ define('MYAAC_OS', stripos(PHP_OS, 'WIN') === 0 ? 'WINDOWS' : (strtoupper(PHP_OS
|
||||
define('IS_CLI', in_array(php_sapi_name(), ['cli', 'phpdb']));
|
||||
|
||||
// account flags
|
||||
const FLAG_NONE = 0;
|
||||
const FLAG_ADMIN = 1;
|
||||
const FLAG_SUPER_ADMIN = 2;
|
||||
const FLAG_SUPER_BOTH = 3;
|
||||
const FLAG_CONTENT_PAGES = 4;
|
||||
const FLAG_CONTENT_MAILER = 8;
|
||||
const FLAG_CONTENT_NEWS = 16;
|
||||
@ -49,6 +51,14 @@ const FLAG_CONTENT_FAQ = 2048;
|
||||
const FLAG_CONTENT_MENUS = 4096;
|
||||
const FLAG_CONTENT_PLAYERS = 8192;
|
||||
|
||||
// account access types
|
||||
const ACCOUNT_WEB_FLAGS = [
|
||||
FLAG_NONE => 'None',
|
||||
FLAG_ADMIN =>'Admin',
|
||||
FLAG_SUPER_ADMIN => 'Super Admin',
|
||||
FLAG_SUPER_BOTH =>'(Admin + Super Admin)',
|
||||
];
|
||||
|
||||
// news
|
||||
const NEWS = 1;
|
||||
const TICKER = 2;
|
||||
|
12
config.php
12
config.php
@ -160,6 +160,18 @@ $config = array(
|
||||
'send_mail_when_change_password' => true, // send e-mail with new password when change password to account
|
||||
'send_mail_when_generate_reckey' => true, // send e-mail with rec key (key is displayed on page anyway when generate)
|
||||
|
||||
// you may need to adjust this for older tfs versions
|
||||
// by removing Community Manager
|
||||
'account_types' => [
|
||||
'None',
|
||||
'Normal',
|
||||
'Tutor',
|
||||
'Senior Tutor',
|
||||
'Gamemaster',
|
||||
'Community Manager',
|
||||
'God',
|
||||
],
|
||||
|
||||
// genders (aka sex)
|
||||
'genders' => array(
|
||||
0 => 'Female',
|
||||
|
Loading…
x
Reference in New Issue
Block a user