mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-11 22:08:54 +00:00
Merge branch 'develop-olympus' into develop
* develop-olympus: [ticket/9712] Future dates can be formatted as 'less than one minute ago' [ticket/9659] Signature options in set_user_options [ticket/9703] Correct database leak where deleting user did not rm some PM data [ticket/9697] Backlink broken when the select parent forum does not exist. [ticket/9695] Correct the improper display of user input in mcp_ban.php [ticket/9628] _add_module 'after'-parameter does not work correctly. [ticket/9578] ACP Posting tab is missing "Post settings" module.
This commit is contained in:
commit
31b221ae91
8 changed files with 26 additions and 11 deletions
|
@ -31,9 +31,9 @@
|
|||
|
||||
function display_details(option)
|
||||
{
|
||||
document.getElementById('acp_unban').unbangivereason.value = ban_give_reason[option];
|
||||
document.getElementById('acp_unban').unbanreason.value = ban_reason[option];
|
||||
document.getElementById('acp_unban').unbanlength.value = ban_length[option];
|
||||
document.getElementById('acp_unban').unbangivereason.innerHTML = ban_give_reason[option];
|
||||
document.getElementById('acp_unban').unbanreason.innerHTML = ban_reason[option];
|
||||
document.getElementById('acp_unban').unbanlength.innerHTML = ban_length[option];
|
||||
}
|
||||
|
||||
// ]]>
|
||||
|
|
|
@ -224,7 +224,7 @@ class acp_ban
|
|||
$template->assign_block_vars('ban_reason', array(
|
||||
'BAN_ID' => $ban_id,
|
||||
'REASON' => $reason,
|
||||
'A_REASON' => addslashes(htmlspecialchars_decode($reason)),
|
||||
'A_REASON' => addslashes($reason),
|
||||
));
|
||||
}
|
||||
}
|
||||
|
@ -236,7 +236,7 @@ class acp_ban
|
|||
$template->assign_block_vars('ban_give_reason', array(
|
||||
'BAN_ID' => $ban_id,
|
||||
'REASON' => $reason,
|
||||
'A_REASON' => addslashes(htmlspecialchars_decode($reason)),
|
||||
'A_REASON' => addslashes($reason),
|
||||
));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -983,7 +983,7 @@ class acp_forums
|
|||
|
||||
if (!$row)
|
||||
{
|
||||
trigger_error($user->lang['PARENT_NOT_EXIST'] . adm_back_link($this->u_action . '&' . $this->parent_id), E_USER_WARNING);
|
||||
trigger_error($user->lang['PARENT_NOT_EXIST'] . adm_back_link($this->u_action . '&parent_id=' . $this->parent_id), E_USER_WARNING);
|
||||
}
|
||||
|
||||
if ($row['forum_type'] == FORUM_LINK)
|
||||
|
|
|
@ -24,7 +24,7 @@ class acp_board_info
|
|||
'features' => array('title' => 'ACP_BOARD_FEATURES', 'auth' => 'acl_a_board', 'cat' => array('ACP_BOARD_CONFIGURATION')),
|
||||
'avatar' => array('title' => 'ACP_AVATAR_SETTINGS', 'auth' => 'acl_a_board', 'cat' => array('ACP_BOARD_CONFIGURATION')),
|
||||
'message' => array('title' => 'ACP_MESSAGE_SETTINGS', 'auth' => 'acl_a_board', 'cat' => array('ACP_BOARD_CONFIGURATION', 'ACP_MESSAGES')),
|
||||
'post' => array('title' => 'ACP_POST_SETTINGS', 'auth' => 'acl_a_board', 'cat' => array('ACP_BOARD_CONFIGURATION')),
|
||||
'post' => array('title' => 'ACP_POST_SETTINGS', 'auth' => 'acl_a_board', 'cat' => array('ACP_BOARD_CONFIGURATION', 'ACP_MESSAGES')),
|
||||
'signature' => array('title' => 'ACP_SIGNATURE_SETTINGS', 'auth' => 'acl_a_board', 'cat' => array('ACP_BOARD_CONFIGURATION')),
|
||||
'feed' => array('title' => 'ACP_FEED_SETTINGS', 'auth' => 'acl_a_board', 'cat' => array('ACP_BOARD_CONFIGURATION')),
|
||||
'registration' => array('title' => 'ACP_REGISTER_SETTINGS', 'auth' => 'acl_a_board', 'cat' => array('ACP_BOARD_CONFIGURATION')),
|
||||
|
|
|
@ -1025,6 +1025,9 @@ function set_user_options()
|
|||
'bbcode' => array('bit' => 8, 'default' => 1),
|
||||
'smilies' => array('bit' => 9, 'default' => 1),
|
||||
'popuppm' => array('bit' => 10, 'default' => 0),
|
||||
'sig_bbcode' => array('bit' => 15, 'default' => 1),
|
||||
'sig_smilies' => array('bit' => 16, 'default' => 1),
|
||||
'sig_links' => array('bit' => 17, 'default' => 1),
|
||||
);
|
||||
|
||||
$option_field = 0;
|
||||
|
|
|
@ -528,7 +528,7 @@ function user_delete($mode, $user_id, $post_username = false)
|
|||
|
||||
$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, SESSIONS_KEYS_TABLE);
|
||||
$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, SESSIONS_KEYS_TABLE, PRIVMSGS_FOLDER_TABLE, PRIVMSGS_RULES_TABLE);
|
||||
|
||||
foreach ($table_ary as $table)
|
||||
{
|
||||
|
|
|
@ -2134,9 +2134,9 @@ class user extends session
|
|||
// Zone offset
|
||||
$zone_offset = $this->timezone + $this->dst;
|
||||
|
||||
// Show date <= 1 hour ago as 'xx min ago'
|
||||
// Show date <= 1 hour ago as 'xx min ago' but not greater than 60 seconds in the future
|
||||
// A small tolerence is given for times in the future but in the same minute are displayed as '< than a minute ago'
|
||||
if ($delta <= 3600 && ($delta >= -5 || (($now / 60) % 60) == (($gmepoch / 60) % 60)) && $date_cache[$format]['is_short'] !== false && !$forcedate && isset($this->lang['datetime']['AGO']))
|
||||
if ($delta <= 3600 && $delta > -60 && ($delta >= -5 || (($now / 60) % 60) == (($gmepoch / 60) % 60)) && $date_cache[$format]['is_short'] !== false && !$forcedate && isset($this->lang['datetime']['AGO']))
|
||||
{
|
||||
return $this->lang(array('datetime', 'AGO'), max(0, (int) floor($delta / 60)));
|
||||
}
|
||||
|
|
|
@ -685,7 +685,6 @@ function _add_modules($modules_to_install)
|
|||
WHERE module_class = '" . $db->sql_escape($module_data['class']) . "'
|
||||
AND parent_id = {$parent_id}
|
||||
AND left_id BETWEEN {$first_left_id} AND {$module_row['left_id']}
|
||||
GROUP BY left_id
|
||||
ORDER BY left_id";
|
||||
$result = $db->sql_query($sql);
|
||||
$steps = (int) $db->sql_fetchfield('num_modules');
|
||||
|
@ -1684,6 +1683,19 @@ function change_database_data(&$no_updates, $version)
|
|||
}
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
// Install modules
|
||||
$modules_to_install = array(
|
||||
'post' => array(
|
||||
'base' => 'board',
|
||||
'class' => 'acp',
|
||||
'title' => 'ACP_POST_SETTINGS',
|
||||
'auth' => 'acl_a_board',
|
||||
'cat' => 'ACP_MESSAGES',
|
||||
'after' => array('message', 'ACP_MESSAGE_SETTINGS')
|
||||
),
|
||||
);
|
||||
|
||||
_add_modules($modules_to_install);
|
||||
|
||||
$no_updates = false;
|
||||
break;
|
||||
|
|
Loading…
Add table
Reference in a new issue