1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-03 15:27:42 +02:00

- Automatically add users/groups to the PM recipient list, if entered or selected.

- Reply to PM now includes all previous recipients and not only the original sender.
- Added 'max_recipients' setting for private messages. This setting allows admins to define the maximum number of recipients per private message with a board-wide setting and a group-specific setting.
- Added new permission setting for sending private messages to groups. Now there are two permissions to define sending private messages to multiple recipients and private messages to groups.



git-svn-id: file:///svn/phpbb/trunk@8914 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Meik Sievertsen
2008-09-23 13:11:34 +00:00
parent b486710ea1
commit ce6b87ccec
16 changed files with 166 additions and 54 deletions

View File

@@ -314,8 +314,6 @@ function user_delete($mode, $user_id, $post_username = false)
return false;
}
$db->sql_transaction('begin');
// Before we begin, we will remove the reports the user issued.
$sql = 'SELECT r.post_id, p.topic_id
FROM ' . REPORTS_TABLE . ' r, ' . POSTS_TABLE . ' p
@@ -384,6 +382,8 @@ function user_delete($mode, $user_id, $post_username = false)
{
case 'retain':
$db->sql_transaction('begin');
if ($post_username === false)
{
$post_username = $user->lang['GUEST'];
@@ -431,6 +431,9 @@ function user_delete($mode, $user_id, $post_username = false)
$db->sql_query($sql);
}
}
$db->sql_transaction('commit');
break;
case 'remove':
@@ -484,6 +487,8 @@ function user_delete($mode, $user_id, $post_username = false)
break;
}
$db->sql_transaction('begin');
$table_ary = array(USERS_TABLE, USER_GROUP_TABLE, TOPICS_WATCH_TABLE, FORUMS_WATCH_TABLE, ACL_USERS_TABLE, TOPICS_TRACK_TABLE, TOPICS_POSTED_TABLE, FORUMS_TRACK_TABLE, PROFILE_FIELDS_DATA_TABLE, MODERATOR_CACHE_TABLE, DRAFTS_TABLE, BOOKMARKS_TABLE);
foreach ($table_ary as $table)
@@ -552,6 +557,8 @@ function user_delete($mode, $user_id, $post_username = false)
$db->sql_query($sql);
}
$db->sql_transaction('commit');
// Reset newest user info if appropriate
if ($config['newest_user_id'] == $user_id)
{
@@ -564,8 +571,6 @@ function user_delete($mode, $user_id, $post_username = false)
set_config('num_users', $config['num_users'] - 1, true);
}
$db->sql_transaction('commit');
return false;
}
@@ -2274,12 +2279,13 @@ function group_create(&$group_id, $type, $name, $desc, $group_attributes, $allow
'group_receive_pm' => 'int',
'group_legend' => 'int',
'group_message_limit' => 'int',
'group_max_recipients' => 'int',
'group_founder_manage' => 'int',
);
// Those are group-only attributes
$group_only_ary = array('group_receive_pm', 'group_legend', 'group_message_limit', 'group_founder_manage');
$group_only_ary = array('group_receive_pm', 'group_legend', 'group_message_limit', 'group_max_recipients', 'group_founder_manage');
// Check data. Limit group name length.
if (!utf8_strlen($name) || utf8_strlen($name) > 60)