1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

- add additional auth check to the permission roles modules

- added new function to return globally used expressions (get_preg_expression($mode)). This should be very helpful in getting wide spread similar checks (regular expressions) to one place reducing the risk of forgetting to change every location if you fix one. ;) We will add additional ones later, at the moment only the email check is retrieved...
- added "active module" var to the module class returning the current active module
- changed call to image magick
- add administrator to global moderators group by default
- extend auth_option column a little bit
- other bugfixes


git-svn-id: file:///svn/phpbb/trunk@6135 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Meik Sievertsen
2006-07-01 19:11:52 +00:00
parent 7ad5db1856
commit 6df6eb0e60
29 changed files with 256 additions and 131 deletions

View File

@@ -701,7 +701,7 @@ class acp_attachments
$sql = 'SELECT forum_id, forum_name, parent_id, forum_type, left_id, right_id
FROM ' . FORUMS_TABLE . '
ORDER BY left_id ASC';
$result = $db->sql_query($sql);
$result = $db->sql_query($sql, 600);
$right = $cat_right = $padding_inc = 0;
$padding = $forum_list = $holding = '';

View File

@@ -439,7 +439,7 @@ class acp_main
if ($auth->acl_get('a_user'))
{
$sql = 'SELECT user_id, username, user_regdate
$sql = 'SELECT user_id, username, user_regdate, user_lastvisit
FROM ' . USERS_TABLE . '
WHERE user_type = ' . USER_INACTIVE . '
ORDER BY user_regdate ASC';
@@ -449,6 +449,7 @@ class acp_main
{
$template->assign_block_vars('inactive', array(
'DATE' => $user->format_date($row['user_regdate']),
'LAST_VISIT' => (!$row['user_lastvisit']) ? ' - ' : $user->format_date($row['user_lastvisit']),
'USER_ID' => $row['user_id'],
'USERNAME' => $row['username'],
'U_USER_ADMIN' => append_sid("{$phpbb_admin_path}index.$phpEx", "i=users&mode=overview&u={$row['user_id']}"))

View File

@@ -130,7 +130,7 @@ class acp_ranks
{
foreach ($img_ary as $img)
{
$img = substr($path, 1) . (($path != '') ? '/' : '') . $img;
$img = $path . $img;
if (!in_array($img, $existing_imgs) || $action == 'edit')
{

View File

@@ -485,9 +485,6 @@ class acp_search
{
global $db;
/**
* @todo what is faster, doing a MAX() or an ORDER BY post_id and LIMIT 1?
*/
$sql = 'SELECT MAX(post_id) as max_post_id
FROM '. POSTS_TABLE;
$result = $db->sql_query($sql);

View File

@@ -736,6 +736,9 @@ class acp_users
user_update_name($user_row['username'], $update_username);
}
// Let the users permissions being updated
$auth->acl_clear_prefetch($user_id);
add_log('admin', 'LOG_USER_USER_UPDATE', $data['username']);
trigger_error($user->lang['USER_OVERVIEW_UPDATED'] . adm_back_link($this->u_action . '&u=' . $user_id));

View File

@@ -20,10 +20,10 @@ class acp_permission_roles_info
'title' => 'ACP_PERMISSION_ROLES',
'version' => '1.0.0',
'modes' => array(
'admin_roles' => array('title' => 'ACP_ADMIN_ROLES', 'auth' => 'acl_a_roles', 'cat' => array('ACP_PERMISSION_ROLES')),
'user_roles' => array('title' => 'ACP_USER_ROLES', 'auth' => 'acl_a_roles', 'cat' => array('ACP_PERMISSION_ROLES')),
'mod_roles' => array('title' => 'ACP_MOD_ROLES', 'auth' => 'acl_a_roles', 'cat' => array('ACP_PERMISSION_ROLES')),
'forum_roles' => array('title' => 'ACP_FORUM_ROLES', 'auth' => 'acl_a_roles', 'cat' => array('ACP_PERMISSION_ROLES')),
'admin_roles' => array('title' => 'ACP_ADMIN_ROLES', 'auth' => 'acl_a_roles && acl_a_aauth', 'cat' => array('ACP_PERMISSION_ROLES')),
'user_roles' => array('title' => 'ACP_USER_ROLES', 'auth' => 'acl_a_roles && acl_a_uauth', 'cat' => array('ACP_PERMISSION_ROLES')),
'mod_roles' => array('title' => 'ACP_MOD_ROLES', 'auth' => 'acl_a_roles && acl_a_mauth', 'cat' => array('ACP_PERMISSION_ROLES')),
'forum_roles' => array('title' => 'ACP_FORUM_ROLES', 'auth' => 'acl_a_roles && acl_a_fauth', 'cat' => array('ACP_PERMISSION_ROLES')),
),
);
}