mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-09 10:16:36 +02:00
Fix bug #47815 - View end of ban in MCP and ACP when user is banned by duration - Patch by Pyramide
Authorised by: AcydBurn git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9727 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -181,7 +181,22 @@ class acp_ban
|
||||
$banned_options .= '<option' . (($row['ban_exclude']) ? ' class="sep"' : '') . ' value="' . $row['ban_id'] . '">' . $row[$field] . '</option>';
|
||||
|
||||
$time_length = ($row['ban_end']) ? ($row['ban_end'] - $row['ban_start']) / 60 : 0;
|
||||
$ban_length[$row['ban_id']] = (isset($ban_end_text[$time_length])) ? $ban_end_text[$time_length] : $user->lang['UNTIL'] . ' -> ' . $user->format_date($row['ban_end']);
|
||||
|
||||
if ($time_length == 0)
|
||||
{
|
||||
// Banned permanently
|
||||
$ban_length[$row['ban_id']] = $user->lang['PERMANENT'];
|
||||
}
|
||||
else if (isset($ban_end_text[$time_length]))
|
||||
{
|
||||
// Banned for a given duration
|
||||
$ban_length[$row['ban_id']] = sprintf($user->lang['BANNED_UNTIL_DURATION'], $ban_end_text[$time_length], $user->format_date($row['ban_end'], false, true));
|
||||
}
|
||||
else
|
||||
{
|
||||
// Banned until given date
|
||||
$ban_length[$row['ban_id']] = sprintf($user->lang['BANNED_UNTIL_DATE'], $user->format_date($row['ban_end'], false, true));
|
||||
}
|
||||
|
||||
$ban_reasons[$row['ban_id']] = $row['ban_reason'];
|
||||
$ban_give_reasons[$row['ban_id']] = $row['ban_give_reason'];
|
||||
|
Reference in New Issue
Block a user