mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-22 06:13:58 -07:00
r178
git-svn-id: https://torrentpier2.googlecode.com/svn/trunk@178 a8ac35ab-4ca4-ca47-4c2d-a49a94f06293
This commit is contained in:
parent
da975018df
commit
2f7f5a5b65
7 changed files with 14 additions and 12 deletions
|
@ -10,7 +10,7 @@ if (!isset($this->request['attach_id']))
|
|||
}
|
||||
if (!isset($this->request['status']))
|
||||
{
|
||||
$this->ajax_die('empty tor_status');
|
||||
$this->ajax_die('не выбран статус');
|
||||
}
|
||||
$attach_id = (int) $this->request['attach_id'];
|
||||
$new_status = (int) $this->request['status'];
|
||||
|
@ -72,4 +72,4 @@ if ($tor['tor_status'] != TOR_NOT_APPROVED && $tor['checked_user_id'] != $userda
|
|||
change_tor_status($attach_id, $new_status);
|
||||
|
||||
$this->response['attach_id'] = $attach_id;
|
||||
$this->response['status'] = $bb_cfg['tor_icons'][$new_status] .' '. $lang['TOR_STATUS_NAME'][$new_status];
|
||||
$this->response['status'] = $bb_cfg['tor_icons'][$new_status] .' <b> '. $lang['TOR_STATUS_NAME'][$new_status]. '</b> · <a class="med" href='. PROFILE_URL . $tor['checked_user_id'] . '>' . get_username($tor['checked_user_id']) . '</a> · <i>'. delta_time(time()) . $lang['BACK']. '</i>';
|
|
@ -159,7 +159,7 @@ switch($this->request['type'])
|
|||
$days_after_last_edit = $bb_cfg['dis_edit_tor_after_days'];
|
||||
$last_edit_time = max($post['post_time'], $post['post_edit_time']) + 86400*$days_after_last_edit;
|
||||
$disallowed_by_forum_perm = in_array($post['forum_id'], $bb_cfg['dis_edit_tor_forums']);
|
||||
$disallowed_by_user_opt = bf($user->opt, 'user_opt', 'dis_edit_release');
|
||||
$disallowed_by_user_opt = bf($user->opt, 'user_opt', 'allow_post_edit');
|
||||
|
||||
if ($last_edit_time < TIMENOW && ($disallowed_by_forum_perm || $disallowed_by_user_opt))
|
||||
{
|
||||
|
@ -169,14 +169,14 @@ switch($this->request['type'])
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$hidden_form = '<input type="hidden" name="mode" value="editpost" />';
|
||||
$hidden_form .= '<input type="hidden" name="'. POST_POST_URL .'" value="'. $post_id .'" />';
|
||||
$hidden_form .= '<input type="hidden" name="subject" value="'. $post['topic_title'] .'" />';
|
||||
|
||||
$this->response['text'] = '
|
||||
<form action="posting.php" method="post" name="post">
|
||||
'. $hidden_form .'
|
||||
'. $hidden_form .'
|
||||
<div class="buttons mrg_4">
|
||||
<input type="button" value=" B " name="codeB" title="Bold (Ctrl+B)" style="font-weight: bold; width: 30px;" />
|
||||
<input type="button" value=" i " name="codeI" title="Italic (Ctrl+I)" style="width: 30px; font-style: italic;" />
|
||||
|
|
|
@ -219,7 +219,7 @@ if ($tor_reged && $tor_info)
|
|||
// torrent status mod
|
||||
'TOR_STATUS_TEXT' => $lang['TOR_STATUS_NAME'][$tor_info['tor_status']],
|
||||
'TOR_STATUS_ICON' => $bb_cfg['tor_icons'][$tor_info['tor_status']],
|
||||
'TOR_STATUS_BY' => ($cuid && $is_auth['auth_mod']) ? (' · <a href='. PROFILE_URL . $cuid . '>' . get_username($cuid) . '</a> · <i>'. delta_time($tor_info['checked_time']) .' назад</i>') : '',
|
||||
'TOR_STATUS_BY' => ($cuid && $is_auth['auth_mod']) ? ('<span title="'.bb_date($tor_info['checked_time'], 'd-M-Y H:i').'"> · <a class="med" href='. PROFILE_URL . $cuid . '>' . get_username($cuid) . '</a> · <i>'. delta_time($tor_info['checked_time']) . $lang['BACK'] . '</i></span>') : '',
|
||||
'TOR_STATUS_SELECT' => build_select('', array_flip($lang['TOR_STATUS_NAME']), TOR_APPROVED),
|
||||
//end torrent status mod
|
||||
|
||||
|
|
|
@ -57,8 +57,8 @@ $bb_cfg['css_ver'] = 1;
|
|||
|
||||
// Increase number of revision after update
|
||||
$bb_cfg['tp_version'] = '2.0.2';
|
||||
$bb_cfg['tp_release_state'] = 'TP II r177';
|
||||
$bb_cfg['tp_release_date'] = '29-07-2011';
|
||||
$bb_cfg['tp_release_state'] = 'TP II r178';
|
||||
$bb_cfg['tp_release_date'] = '30-07-2011';
|
||||
|
||||
$bb_cfg['board_disabled_msg'] = 'форум временно отключен'; // 'forums temporarily disabled'; // show this msg if board has been disabled via ON/OFF trigger
|
||||
$bb_cfg['srv_overloaded_msg'] = "Извините, в данный момент сервер перегружен\nПопробуйте повторить запрос через несколько минут";
|
||||
|
|
|
@ -280,6 +280,7 @@ $bf['user_opt'] = array(
|
|||
'allow_topic' => 11, // Запрет на создание новых тем
|
||||
'allow_post' => 12, // Запрет на отправку сообщений
|
||||
'allow_post_edit' => 13, // Запрет на редактирование сообщений
|
||||
'view_profile' => 14, // Запрет на просмотр профиля гостям
|
||||
);
|
||||
|
||||
function bit2dec ($bit_num)
|
||||
|
|
|
@ -392,6 +392,7 @@ foreach ($profile_fields as $field => $can_edit)
|
|||
'notify' => true,
|
||||
'notify_pm' => true,
|
||||
'hide_porn_forums' => true,
|
||||
'allow_post_edit' => true,
|
||||
);
|
||||
foreach ($update_user_opt as $opt => $can_change_opt)
|
||||
{
|
||||
|
|
|
@ -8,10 +8,6 @@ $datastore->enqueue(array(
|
|||
'ranks',
|
||||
));
|
||||
|
||||
if (!$userdata['session_logged_in'])
|
||||
{
|
||||
redirect(append_sid("login.php?redirect={$_SERVER['REQUEST_URI']}", TRUE));
|
||||
}
|
||||
if (empty($_GET[POST_USERS_URL]) || $_GET[POST_USERS_URL] == ANONYMOUS)
|
||||
{
|
||||
bb_die($lang['NO_USER_ID_SPECIFIED']);
|
||||
|
@ -21,6 +17,10 @@ if (!$profiledata = get_userdata($_GET[POST_USERS_URL]))
|
|||
bb_die($lang['NO_USER_ID_SPECIFIED']);
|
||||
}
|
||||
|
||||
if(bf($profiledata['user_opt'], 'user_opt', 'view_profile'))
|
||||
{
meta_refresh(append_sid("login.php?redirect={$_SERVER['REQUEST_URI']}", true));
|
||||
bb_die("Пользователь {$profiledata['username']} запретил гостям просмотр своего профиля");
}
|
||||
|
||||
//
|
||||
// Calculate the number of days this user has been a member ($memberdays)
|
||||
// Then calculate their posts per day
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue