|
From: Paul S. O. <ps...@us...> - 2001-12-24 18:37:54
|
Update of /cvsroot/phpbb/phpBB2/admin
In directory usw-pr-cvs1:/tmp/cvs-serv4082/admin
Modified Files:
admin_groupauth.php admin_userauth.php
Log Message:
Minor updates + change of function name in group auth to prevent conflict.
Index: admin_groupauth.php
===================================================================
RCS file: /cvsroot/phpbb/phpBB2/admin/admin_groupauth.php,v
retrieving revision 1.22
retrieving revision 1.23
diff -C2 -r1.22 -r1.23
*** admin_groupauth.php 2001/11/30 01:28:32 1.22
--- admin_groupauth.php 2001/12/24 18:37:51 1.23
***************
*** 69,73 ****
// Start Functions
//
! function a_auth_check_user($type, $key, $u_auth, $is_admin)
{
--- 69,73 ----
// Start Functions
//
! function a_auth_check_group($type, $key, $u_auth, $is_admin)
{
***************
*** 75,79 ****
$auth_user = array();
! while( list($entry, $u_ary) = each($u_auth) )
{
if(!$single_user)
--- 75,79 ----
$auth_user = array();
! while( list($entry, $u_ary) = @each($u_auth) )
{
if(!$single_user)
***************
*** 95,99 ****
}
! $auth_user['auth'] = (!$single_user) ? ( $auth_user || $result ) : $result;
}
--- 95,99 ----
}
! $auth_user['auth'] = $auth_user || $result;
}
***************
*** 431,435 ****
// Checks complete, make updates to DB
//
! while( list($chg_forum_id, $sql) = each($valid_auth_mod_sql) )
{
if( !empty($sql) )
--- 431,435 ----
// Checks complete, make updates to DB
//
! while( list($chg_forum_id, $sql) = @each($valid_auth_mod_sql) )
{
if( !empty($sql) )
***************
*** 442,446 ****
}
! while( list($chg_forum_id, $sql) = each($valid_auth_prv_sql) )
{
if( !empty($sql) )
--- 442,446 ----
}
! while( list($chg_forum_id, $sql) = @each($valid_auth_prv_sql) )
{
if( !empty($sql) )
***************
*** 457,461 ****
//
$warning_list_mod = "";
! while( list($forum_id, $user_ary) = each($warning_mod_userid) )
{
for($i = 0; $i < count($user_ary); $i++)
--- 457,461 ----
//
$warning_list_mod = "";
! while( list($forum_id, $user_ary) = @each($warning_mod_userid) )
{
for($i = 0; $i < count($user_ary); $i++)
***************
*** 470,474 ****
$warning_list_acl = "";
! while( list($forum_id, $user_ary) = each($warning_prv_userid) )
{
for($i = 0; $i < count($user_ary); $i++)
--- 470,474 ----
$warning_list_acl = "";
! while( list($forum_id, $user_ary) = @each($warning_prv_userid) )
{
for($i = 0; $i < count($user_ary); $i++)
***************
*** 597,601 ****
if($num_forum_access[$f_forum_id])
{
! $result = a_auth_check_user(AUTH_ACL, $key, $g_access[$f_forum_id], 0);
$auth_group[$f_forum_id][$key] = $result['auth'];
$auth_field_acl[$f_forum_id][$key] = $result['auth'];
--- 597,601 ----
if($num_forum_access[$f_forum_id])
{
! $result = a_auth_check_group(AUTH_ACL, $key, $g_access[$f_forum_id], 0);
$auth_group[$f_forum_id][$key] = $result['auth'];
$auth_field_acl[$f_forum_id][$key] = $result['auth'];
***************
*** 610,614 ****
if($num_forum_access[$f_forum_id])
{
! $result = a_auth_check_user(AUTH_MOD, $key, $g_access[$f_forum_id], 0);
$auth_group[$f_forum_id][$key] = $result['auth'];
}
--- 610,614 ----
if($num_forum_access[$f_forum_id])
{
! $result = a_auth_check_group(AUTH_MOD, $key, $g_access[$f_forum_id], 0);
$auth_group[$f_forum_id][$key] = $result['auth'];
}
***************
*** 634,638 ****
if($num_forum_access[$f_forum_id])
{
! $result = a_auth_check_user(AUTH_MOD, 'auth_mod', $g_access[$f_forum_id], 0);
$auth_group[$f_forum_id]['auth_mod'] = $result['auth'];
}
--- 634,638 ----
if($num_forum_access[$f_forum_id])
{
! $result = a_auth_check_group(AUTH_MOD, 'auth_mod', $g_access[$f_forum_id], 0);
$auth_group[$f_forum_id]['auth_mod'] = $result['auth'];
}
Index: admin_userauth.php
===================================================================
RCS file: /cvsroot/phpbb/phpBB2/admin/admin_userauth.php,v
retrieving revision 1.25
retrieving revision 1.26
diff -C2 -r1.25 -r1.26
*** admin_userauth.php 2001/11/19 19:06:01 1.25
--- admin_userauth.php 2001/12/24 18:37:51 1.26
***************
*** 105,109 ****
}
! $auth_user['auth'] = (!$single_user) ? ( $auth_user || $result ) : $result;
}
--- 105,109 ----
}
! $auth_user['auth'] = $auth_user || $result;
}
***************
*** 403,407 ****
//
@reset($new_prv_ary);
! while( list($this_prv_field, $new_prv_status) = each($new_prv_ary) )
{
//
--- 403,407 ----
//
@reset($new_prv_ary);
! while( list($this_prv_field, $new_prv_status) = @each($new_prv_ary) )
{
//
***************
*** 470,474 ****
@reset($new_prv_ary);
! while( list($this_prv_field, $new_prv_status) = each($new_prv_ary) )
{
//
--- 470,474 ----
@reset($new_prv_ary);
! while( list($this_prv_field, $new_prv_status) = @each($new_prv_ary) )
{
//
***************
*** 726,734 ****
$i = 0;
! while(list($forumkey, $user_ary) = each($auth_user))
{
if( empty($adv) )
{
! if($forum_auth_level[$forumkey] == AUTH_ACL)
{
$allowed = 1;
--- 726,734 ----
$i = 0;
! while( list($forumkey, $user_ary) = @each($auth_user) )
{
if( empty($adv) )
{
! if( $forum_auth_level[$forumkey] == AUTH_ACL )
{
$allowed = 1;
***************
*** 736,740 ****
for($j = 0; $j < count($forum_auth_level_fields[$forumkey]); $j++)
{
! if(!$auth_user[$forumkey][$forum_auth_level_fields[$forumkey][$j]])
{
$allowed = 0;
--- 736,740 ----
for($j = 0; $j < count($forum_auth_level_fields[$forumkey]); $j++)
{
! if( !$auth_user[$forumkey][$forum_auth_level_fields[$forumkey][$j]] )
{
$allowed = 0;
***************
*** 744,752 ****
$optionlist_acl = "<select name=\"private[$forumkey]\">";
! if($is_admin || $user_ary['auth_mod'])
{
$optionlist_acl .= "<option value=\"1\">" . $lang['Allowed_Access'] . "</option>";
}
! else if($allowed)
{
$optionlist_acl .= "<option value=\"1\" selected=\"selected\">" . $lang['Allowed_Access'] . "</option><option value=\"0\">". $lang['Disallowed_Access'] . "</option>";
--- 744,752 ----
$optionlist_acl = "<select name=\"private[$forumkey]\">";
! if( $is_admin || $user_ary['auth_mod'] )
{
$optionlist_acl .= "<option value=\"1\">" . $lang['Allowed_Access'] . "</option>";
}
! else if( $allowed )
{
$optionlist_acl .= "<option value=\"1\" selected=\"selected\">" . $lang['Allowed_Access'] . "</option><option value=\"0\">". $lang['Disallowed_Access'] . "</option>";
***************
*** 767,771 ****
{
@reset($forum_access);
! while(list($key, $forum_row) = each($forum_access))
{
$forum_id = $forum_row['forum_id'];
--- 767,771 ----
{
@reset($forum_access);
! while( list($key, $forum_row) = @each($forum_access) )
{
$forum_id = $forum_row['forum_id'];
***************
*** 781,785 ****
if( isset($auth_field_acl[$forum_id][$field_name]) && !($is_admin || $user_ary['auth_mod']) )
{
! if(!$auth_field_acl[$forum_id][$field_name])
{
$optionlist_acl_adv[$forum_id][$j] .= "<option value=\"1\">" . $lang['ON'] . "</option><option value=\"0\" selected=\"selected\">" . $lang['OFF'] . "</option>";
--- 781,785 ----
if( isset($auth_field_acl[$forum_id][$field_name]) && !($is_admin || $user_ary['auth_mod']) )
{
! if( !$auth_field_acl[$forum_id][$field_name] )
{
$optionlist_acl_adv[$forum_id][$j] .= "<option value=\"1\">" . $lang['ON'] . "</option><option value=\"0\" selected=\"selected\">" . $lang['OFF'] . "</option>";
***************
*** 792,796 ****
else
{
! if($is_admin || $user_ary['auth_mod'])
{
$optionlist_acl_adv[$forum_id][$j] .= "<option value=\"1\">" . $lang['ON'] . "</option>";
--- 792,796 ----
else
{
! if( $is_admin || $user_ary['auth_mod'] )
{
$optionlist_acl_adv[$forum_id][$j] .= "<option value=\"1\">" . $lang['ON'] . "</option>";
***************
*** 810,814 ****
$optionlist_mod = "<select name=\"moderator[$forumkey]\">";
! if($user_ary['auth_mod'])
{
$optionlist_mod .= "<option value=\"1\" selected=\"selected\">" . $lang['Is_Moderator'] . "</option><option value=\"0\">" . $lang['Not_Moderator'] . "</option>";
--- 810,814 ----
$optionlist_mod = "<select name=\"moderator[$forumkey]\">";
! if( $user_ary['auth_mod'] )
{
$optionlist_mod .= "<option value=\"1\" selected=\"selected\">" . $lang['Is_Moderator'] . "</option><option value=\"0\">" . $lang['Not_Moderator'] . "</option>";
***************
*** 833,837 ****
);
! if(!$adv)
{
$template->assign_block_vars("forums.aclvalues", array(
--- 833,837 ----
);
! if( !$adv )
{
$template->assign_block_vars("forums.aclvalues", array(
***************
*** 858,862 ****
for($i = 0; $i < count($userinf); $i++)
{
! if(!$userinf[$i]['group_single_user'])
{
$group_name[] = $userinf[$i]['group_name'];
--- 858,862 ----
for($i = 0; $i < count($userinf); $i++)
{
! if( !$userinf[$i]['group_single_user'] )
{
$group_name[] = $userinf[$i]['group_name'];
***************
*** 865,869 ****
}
! if(count($group_name))
{
$t_usergroup_list = "";
--- 865,869 ----
}
! if( count($group_name) )
{
$t_usergroup_list = "";
***************
*** 886,890 ****
$s_column_span = 2; // Two columns always present
! if(!$adv)
{
$template->assign_block_vars("acltype", array(
--- 886,890 ----
$s_column_span = 2; // Two columns always present
! if( !$adv )
{
$template->assign_block_vars("acltype", array(
|