Version 2.3.6
This commit is contained in:
1 parent
a3bb603c96
commit
19b38c7c74
764 files changed
+143731
-118164
No files matched your search
@@ -2,26 +2,18 @@
|
||||
|
||||
/*
|
||||
+--------------------------------------------------------------------------
|
||||
| Invision Power Board 2.2.2
|
||||
| Invision Power Board
|
||||
| =============================================
|
||||
| by Matthew Mecham
|
||||
| (c) 2001 - 2006 Invision Power Services, Inc.
|
||||
| http://www.invisionpower.com
|
||||
| =============================================
|
||||
| Web: http://www.invisionboard.com
|
||||
| http://www.ibresource.ru/products/invisionpowerboard/
|
||||
| Time: Monday 05th of March 2007 10:10:54 PM
|
||||
| Release: e3790216629e5a2aaf37070b32237f06
|
||||
| Licence Info: http://www.invisionboard.com/?license
|
||||
| http://www.ibresource.ru/license
|
||||
+---------------------------------------------------------------------------
|
||||
| INVISION POWER BOARD ÍÅ ßÂËßÅÒÑß ÁÅÑÏËÀÒÍÛÌ ÏÐÎÃÐÀÌÌÍÛÌ ÎÁÅÑÏÅ×ÅÍÈÅÌ!
|
||||
| Ïðàâà íà ÏÎ ïðèíàäëåæàò Invision Power Services
|
||||
| Ïðàâà íà ïåðåâîä IBResource (http://www.ibresource.ru)
|
||||
+---------------------------------------------------------------------------
|
||||
| > $Date: 2006-09-22 05:28:54 -0500 (Fri, 22 Sep 2006) $
|
||||
| > $Revision: 567 $
|
||||
| > $Author: matt $
|
||||
| > $Date: 2007-05-08 16:35:01 -0400 (Tue, 08 May 2007) $
|
||||
| > $Revision: 981 $
|
||||
| > $Author: bfarber $
|
||||
+---------------------------------------------------------------------------
|
||||
|
|
||||
| > Warn Log functions
|
||||
@@ -36,216 +28,220 @@
|
||||
|
||||
if ( ! defined( 'IN_ACP' ) )
|
||||
{
|
||||
print "<h1>Íåêîððåêòíûé àäðåñ</h1>Âû íå èìååòå äîñòóïà ê ýòîìó ôàéëó íàïðÿìóþ. Åñëè âû íåäàâíî îáíîâëÿëè ôîðóì, âû äîëæíû îáíîâèòü âñå ñîîòâåòñòâóþùèå ôàéëû.";
|
||||
print "<h1>Incorrect access</h1>You cannot access this file directly. If you have recently upgraded, make sure you upgraded 'admin.php'.";
|
||||
exit();
|
||||
}
|
||||
|
||||
class ad_warnlogs {
|
||||
|
||||
var $base_url;
|
||||
|
||||
|
||||
/**
|
||||
* Section title name
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
var $perm_main = "admin";
|
||||
|
||||
|
||||
/**
|
||||
* Section title name
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
var $perm_child = "warnlog";
|
||||
|
||||
|
||||
function auto_run()
|
||||
{
|
||||
$this->ipsclass->admin->nav[] = array( $this->ipsclass->form_code, 'Æóðíàë ïðåäóïðåæäåíèé' );
|
||||
|
||||
$this->ipsclass->admin->nav[] = array( $this->ipsclass->form_code, 'Warn Logs' );
|
||||
|
||||
//-----------------------------------------
|
||||
|
||||
switch($this->ipsclass->input['code'])
|
||||
{
|
||||
|
||||
|
||||
case 'view':
|
||||
$this->ipsclass->admin->cp_permission_check( $this->perm_main.'|'.$this->perm_child.':' );
|
||||
$this->view();
|
||||
break;
|
||||
|
||||
|
||||
case 'viewcontact':
|
||||
$this->ipsclass->admin->cp_permission_check( $this->perm_main.'|'.$this->perm_child.':' );
|
||||
$this->view_contact();
|
||||
break;
|
||||
|
||||
|
||||
case 'viewnote':
|
||||
$this->ipsclass->admin->cp_permission_check( $this->perm_main.'|'.$this->perm_child.':view' );
|
||||
$this->view_note();
|
||||
break;
|
||||
|
||||
|
||||
case 'remove':
|
||||
$this->ipsclass->admin->cp_permission_check( $this->perm_main.'|'.$this->perm_child.':remove' );
|
||||
$this->remove();
|
||||
break;
|
||||
|
||||
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
default:
|
||||
$this->ipsclass->admin->cp_permission_check( $this->perm_main.'|'.$this->perm_child.':' );
|
||||
$this->list_current();
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
// View NOTE in da pop up innit
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
function view_note()
|
||||
{
|
||||
if ($this->ipsclass->input['id'] == "")
|
||||
{
|
||||
$this->ipsclass->admin->error("Íåâîçìîæíî ïîëó÷èòü ID email, ïîïðîáóéòå ñíîâà");
|
||||
$this->ipsclass->admin->error("Could not resolve the email ID, please try again");
|
||||
}
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
// Load and config the post parser
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
require_once( ROOT_PATH."sources/handlers/han_parse_bbcode.php" );
|
||||
$this->parser = new parse_bbcode();
|
||||
$this->parser->ipsclass = $this->ipsclass;
|
||||
$this->parser->allow_update_caches = 1;
|
||||
|
||||
|
||||
$this->parser->bypass_badwords = intval($this->ipsclass->member['g_bypass_badwords']);
|
||||
|
||||
|
||||
$id = intval($this->ipsclass->input['id']);
|
||||
|
||||
|
||||
$this->ipsclass->DB->cache_add_query( 'warnlogs_view_note', array( 'id' => $id ) );
|
||||
$this->ipsclass->DB->cache_exec_query();
|
||||
|
||||
|
||||
if ( ! $row = $this->ipsclass->DB->fetch_row() )
|
||||
{
|
||||
$this->ipsclass->admin->error("Íåâîçìîæíî ïîëó÷èòü ID email, ïîïðîáóéòå ñíîâà ($id)");
|
||||
$this->ipsclass->admin->error("Could not resolve the email ID, please try again ($id)");
|
||||
}
|
||||
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( " " , "100%" );
|
||||
|
||||
|
||||
$content = preg_match( "#<content>(.+?)</content>#is", $row['wlog_notes'], $cont );
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Warn Notes" );
|
||||
|
||||
|
||||
$row['date'] = $this->ipsclass->admin->get_date( $row['wlog_date'], 'LONG' );
|
||||
|
||||
|
||||
$row['a_name'] = $row['a_name'] ? $row['a_name'] : 'Deleted Member (ID:' . $row['wlog_mid'] . ')';
|
||||
|
||||
$this->parser->parse_html = 0;
|
||||
$this->parser->parse_nl2br = 1;
|
||||
$this->parser->parse_smilies = 1;
|
||||
$this->parser->parse_bbcode = 1;
|
||||
|
||||
|
||||
$text = $this->parser->pre_display_parse( $this->parser->pre_db_parse($cont[1]) );
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array(
|
||||
"<strong>Îò:</strong> {$row['p_name']}
|
||||
<br /><strong>Êîìó:</strong> {$row['a_name']}
|
||||
<br /><strong>Îòïðàâëåíî:</strong> {$row['date']}
|
||||
"<strong>From:</strong> {$row['p_name']}
|
||||
<br /><strong>To:</strong> {$row['a_name']}
|
||||
<br /><strong>Sent:</strong> {$row['date']}
|
||||
<hr>
|
||||
<br />$text
|
||||
"
|
||||
) );
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->end_table();
|
||||
|
||||
|
||||
$this->ipsclass->admin->print_popup();
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
// View contact in da pop up innit
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
function view_contact()
|
||||
{
|
||||
if ($this->ipsclass->input['id'] == "")
|
||||
{
|
||||
$this->ipsclass->admin->error("Íåâîçìîæíî ïîëó÷èòü ID email, ïîïðîáóéòå ñíîâà");
|
||||
$this->ipsclass->admin->error("Could not resolve the email ID, please try again");
|
||||
}
|
||||
|
||||
|
||||
$id = intval($this->ipsclass->input['id']);
|
||||
|
||||
|
||||
$this->ipsclass->DB->cache_add_query( 'warnlogs_view_note', array( 'id' => $id ) );
|
||||
$this->ipsclass->DB->cache_exec_query();
|
||||
|
||||
|
||||
if ( ! $row = $this->ipsclass->DB->fetch_row() )
|
||||
{
|
||||
$this->ipsclass->admin->error("Íåâîçìîæíî ïîëó÷èòü ID email, ïîïðîáóéòå ñíîâà ($id)");
|
||||
$this->ipsclass->admin->error("Could not resolve the email ID, please try again ($id)");
|
||||
}
|
||||
|
||||
$type = $row['wlog_contact'] == 'pm' ? "Ëè÷íîå ñîîáùåíèå" : "EMAIL";
|
||||
|
||||
|
||||
$type = $row['wlog_contact'] == 'pm' ? "PM" : "EMAIL";
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( " " , "100%" );
|
||||
|
||||
|
||||
$subject = preg_match( "#<subject>(.+?)</subject>#is", $row['wlog_contact_content'], $subj );
|
||||
$content = preg_match( "#<content>(.+?)</content>#is", $row['wlog_contact_content'], $cont );
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( $type.": ".$subj[1] );
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$row['date'] = $this->ipsclass->admin->get_date( $row['wlog_date'], 'LONG' );
|
||||
|
||||
|
||||
$row['a_name'] = $row['a_name'] ? $row['a_name'] : 'Deleted Member (ID:' . $row['wlog_mid'] . ')';
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array(
|
||||
"<strong>Îò:</strong> {$row['p_name']}
|
||||
<br /><strong>Êîìó:</strong> {$row['a_name']}
|
||||
<br /><strong>Îòïðàâëåíî:</strong> {$row['date']}
|
||||
<br /><strong>Òåìà:</strong> $subj[1]
|
||||
"<strong>From:</strong> {$row['p_name']}
|
||||
<br /><strong>To:</strong> {$row['a_name']}
|
||||
<br /><strong>Sent:</strong> {$row['date']}
|
||||
<br /><strong>Subject:</strong> $subj[1]
|
||||
<hr>
|
||||
<br />$cont[1]
|
||||
"
|
||||
) );
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->end_table();
|
||||
|
||||
|
||||
$this->ipsclass->admin->print_popup();
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
// Remove archived files
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
function view()
|
||||
{
|
||||
$start = intval($this->ipsclass->input['st']) >=0 ? intval($this->ipsclass->input['st']) : 0;
|
||||
|
||||
|
||||
$this->ipsclass->html .= ""; // removed js popwin
|
||||
|
||||
$this->ipsclass->admin->page_detail = "Ïðîñìîòð âñåõ çàïèñåé î ïðåäóïðåæäåíèé ïîëüçîâàòåëÿ";
|
||||
$this->ipsclass->admin->page_title = "Æóðíàë ïðåäóïðåæäåíèé";
|
||||
|
||||
|
||||
$this->ipsclass->admin->page_detail = "Viewing all warn entries on a member";
|
||||
$this->ipsclass->admin->page_title = "Warn Logs Manager";
|
||||
|
||||
if ($this->ipsclass->input['search_string'] == "" and $this->ipsclass->input['mid'])
|
||||
{
|
||||
$this->ipsclass->DB->simple_construct( array( 'select' => 'COUNT(wlog_id) as count', 'from' => 'warn_logs', 'where' => "wlog_mid=".intval($this->ipsclass->input['mid']) ) );
|
||||
$this->ipsclass->DB->simple_exec();
|
||||
|
||||
|
||||
$row = $this->ipsclass->DB->fetch_row();
|
||||
|
||||
|
||||
$row_count = $row['count'];
|
||||
|
||||
|
||||
$query = "&{$this->ipsclass->form_code}&mid={$this->ipsclass->input['mid']}&code=view";
|
||||
|
||||
|
||||
$this->ipsclass->DB->cache_add_query( 'warnlogs_view', array( 'mid' => intval($this->ipsclass->input['mid']), 'start' => $start ) );
|
||||
$this->ipsclass->DB->cache_exec_query();
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->ipsclass->input['search_string'] = urldecode($this->ipsclass->input['search_string']);
|
||||
|
||||
|
||||
if ( ($this->ipsclass->input['search_type'] == 'notes') )
|
||||
{
|
||||
$dbq = "l.wlog_notes LIKE '%".$this->ipsclass->input['search_string']."%'";
|
||||
@@ -254,115 +250,116 @@ class ad_warnlogs {
|
||||
{
|
||||
$dbq = "l.wlog_contact_content LIKE '%".$this->ipsclass->input['search_string']."%'";
|
||||
}
|
||||
|
||||
|
||||
$this->ipsclass->DB->simple_construct( array( 'select' => 'COUNT(l.wlog_id) as count', 'from' => 'warn_logs l', 'where' => $dbq ) );
|
||||
$this->ipsclass->DB->simple_exec();
|
||||
|
||||
|
||||
$row = $this->ipsclass->DB->fetch_row();
|
||||
|
||||
|
||||
$row_count = $row['count'];
|
||||
|
||||
|
||||
$query = "&{$this->ipsclass->form_code}&code=view&search_type={$this->ipsclass->input['search_type']}&search_string=".urlencode($this->ipsclass->input['search_string']);
|
||||
|
||||
|
||||
$this->ipsclass->DB->cache_add_query( 'warnlogs_view_two', array( 'dbq' => $dbq, 'start' => $start ) );
|
||||
$this->ipsclass->DB->cache_exec_query();
|
||||
}
|
||||
|
||||
|
||||
$links = $this->ipsclass->adskin->build_pagelinks( array( 'TOTAL_POSS' => $row_count,
|
||||
'PER_PAGE' => 30,
|
||||
'CUR_ST_VAL' => $start,
|
||||
'L_SINGLE' => "Ñòðàíèöà",
|
||||
'L_MULTI' => "Ñòðàíèöû: ",
|
||||
'L_SINGLE' => "Single Page",
|
||||
'L_MULTI' => "Pages: ",
|
||||
'BASE_URL' => $this->ipsclass->base_url.$query,
|
||||
)
|
||||
);
|
||||
|
||||
$this->ipsclass->admin->page_detail = "Â ýòîé ñåêöèè âû ìîæåòå ïðîñìàòðèâàòü è óïðàâëÿòü æóðíàëîì ïðåäóïðåæäåíèé";
|
||||
$this->ipsclass->admin->page_title = "Æóðíàë ïðåäóïðåæäåíèé";
|
||||
|
||||
|
||||
$this->ipsclass->admin->page_detail = "You may view warn entries added by your moderators";
|
||||
$this->ipsclass->admin->page_title = "Warn Logs Manager";
|
||||
|
||||
//-----------------------------------------
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( "Òèï" , "5%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Ïîëüçîâàòåëü" , "15%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Óâåäîìëåí?" , "5%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Ïðîâåðêà ñîîáùåíèé" , "10%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Áàí" , "10%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Çàïðåò ñîîáùåíèé" , "10%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Âðåìÿ" , "15%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Ìîäåðàòîð" , "15%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Ïîñìîòðåòü çàìåòêè" , "10%" );
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Æóðíàë ïðåäóïðåæäåíèé" );
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( "Type" , "5%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Member Name" , "15%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Contacted" , "5%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "MOD Q" , "10%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "SUSP" , "10%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "NO POST" , "10%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Date" , "15%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Warned By" , "15%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "View Note" , "10%" );
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Saved Warn Logs" );
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_basic($links, 'right', 'tablesubheader');
|
||||
|
||||
$days = array( 'd' => "Äíåé", 'h' => "÷àñîâ" );
|
||||
|
||||
|
||||
$days = array( 'd' => "Days", 'h' => "Hours" );
|
||||
|
||||
if ( $this->ipsclass->DB->get_num_rows() )
|
||||
{
|
||||
while ( $row = $this->ipsclass->DB->fetch_row() )
|
||||
{
|
||||
|
||||
$row['a_name'] = $row['a_name'] ? $row['a_name'] : 'Deleted Member (ID:' . $row['wlog_mid'] . ')';
|
||||
|
||||
$row['wlog_date'] = $this->ipsclass->admin->get_date( $row['wlog_date'], 'LONG' );
|
||||
|
||||
|
||||
$type = ( $row['wlog_type'] == 'pos' ) ? '<span style="color:green;font-weight:bold">-</span>' : '<span style="color:red;font-weight:bold">+</span>';
|
||||
$cont = ( $row['wlog_contact'] != 'none' ) ? "<center><a href='javascript:pop_win(\"&{$this->ipsclass->form_code}&code=viewcontact&id={$row['wlog_id']}\",\"Log\", 400,400)'>Ïðîñìîòð</a></center>" : ' ';
|
||||
|
||||
$cont = ( $row['wlog_contact'] != 'none' ) ? "<center><a href='javascript:pop_win(\"&{$this->ipsclass->form_code}&code=viewcontact&id={$row['wlog_id']}\",\"Log\", 400,400)'>View</a></center>" : ' ';
|
||||
|
||||
$mod = preg_match( "#<mod>(.+?)</mod>#is" , $row['wlog_notes'], $mm );
|
||||
$post = preg_match( "#<post>(.+?)</post>#is" , $row['wlog_notes'], $pm );
|
||||
$susp = preg_match( "#<susp>(.+?)</susp>#is" , $row['wlog_notes'], $sm );
|
||||
$content = preg_match( "#<content>(.+?)</content>#is", $row['wlog_notes'], $cm );
|
||||
|
||||
|
||||
$content = $cm[1];
|
||||
|
||||
|
||||
$mod = trim($mm[1]);
|
||||
$post = trim($pm[1]);
|
||||
$susp = trim($sm[1]);
|
||||
|
||||
|
||||
list($v, $u, $i) = explode(',', $mod);
|
||||
|
||||
|
||||
if ( $i == 1 )
|
||||
{
|
||||
$mod = 'Íå îïðåäåëåíî';
|
||||
$mod = 'INDEF';
|
||||
}
|
||||
else if ( $v == "" )
|
||||
{
|
||||
$mod = 'Íåò';
|
||||
$mod = 'None';
|
||||
}
|
||||
else
|
||||
{
|
||||
$mod = $v.' '.$days[$u];
|
||||
}
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
list($v, $u, $i) = explode(',', $post);
|
||||
|
||||
|
||||
if ( $i == 1 )
|
||||
{
|
||||
$post = 'Íå îïðåäåëåíî';
|
||||
$post = 'INDEF';
|
||||
}
|
||||
else if ( $v == "" )
|
||||
{
|
||||
$post = 'Íåò';
|
||||
$post = 'None';
|
||||
}
|
||||
else
|
||||
{
|
||||
$post = $v.' '.$days[$u];
|
||||
}
|
||||
|
||||
|
||||
list($v, $u) = explode(',', $susp);
|
||||
|
||||
|
||||
if ( $v == "" )
|
||||
{
|
||||
$susp = 'íåò';
|
||||
$susp = 'None';
|
||||
}
|
||||
else
|
||||
{
|
||||
$susp = $v.' '.$days[$u];
|
||||
}
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array(
|
||||
"<center>$type</center>",
|
||||
"<b>{$row['a_name']}</b>",
|
||||
@@ -372,83 +369,85 @@ class ad_warnlogs {
|
||||
$post,
|
||||
"{$row['wlog_date']}",
|
||||
"<b>{$row['p_name']}</b>",
|
||||
"<center><a href='javascript:pop_win(\"&{$this->ipsclass->form_code}&code=viewnote&id={$row['wlog_id']}\",\"Log\",400,400)'>Ïðîñìîòð</a></center>"
|
||||
"<center><a href='javascript:pop_win(\"&{$this->ipsclass->form_code}&code=viewnote&id={$row['wlog_id']}\",\"Log\",400,400)'>View</a></center>"
|
||||
) );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_basic("<center>Íåò çàïèñåé</center>");
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_basic("<center>No results</center>");
|
||||
}
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_basic($links, 'right', 'tablesubheader');
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->end_table();
|
||||
|
||||
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
//-------------------------------
|
||||
|
||||
|
||||
$this->ipsclass->admin->output();
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
// Remove archived files
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
function remove()
|
||||
{
|
||||
if ($this->ipsclass->input['mid'] == "")
|
||||
{
|
||||
$this->ipsclass->admin->error("Âû íå âûáðàëè ïîëüçîâàòåëÿ, êîòîðîìó íåîáõîäèìî óäàëèòü ïðåäóïðåæäåíèå.");
|
||||
$this->ipsclass->admin->error("You did not select a member ID to remove by!");
|
||||
}
|
||||
|
||||
|
||||
$this->ipsclass->DB->simple_exec_query( array( 'delete' => 'warn_logs', 'where' => "wlog_mid=".intval($this->ipsclass->input['mid']) ) );
|
||||
|
||||
$this->ipsclass->admin->save_log("Ïðåäóïðåæäåíèå óäàëåíî");
|
||||
|
||||
$this->ipsclass->boink_it($this->ipsclass->base_url."&{$this->ipsclass->form_code}");
|
||||
|
||||
$this->ipsclass->admin->save_log("Removed Warn Logs");
|
||||
|
||||
$this->ipsclass->boink_it($this->ipsclass->base_url."&{$this->ipsclass->form_code}");
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
// SHOW LOGS
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
function list_current()
|
||||
{
|
||||
$form_array = array();
|
||||
|
||||
$this->ipsclass->admin->page_detail = " ýòîé ñåêöèè âû ìîæåòå ïðîñìàòðèâàòü è óïðàâëÿòü æóðíàëîì ïðåäóïðåæäåíèé.<br />Ïðèìå÷àíèå: óäàëåíèå çàïèñåé èç æóðíàëà íå ïîíèæàåò óðîâåíü ïðåäóïðåæäåíèé ïîëüçîâàòåëÿ.";
|
||||
$this->ipsclass->admin->page_title = "Æóðíàë ïðåäóïðåæäåíèé";
|
||||
|
||||
|
||||
$this->ipsclass->admin->page_detail = "You may view and remove warn actions performed by your staff.<br />Note: Removing the logs does not decrease the member's warn level";
|
||||
$this->ipsclass->admin->page_title = "Warn Logs Manager";
|
||||
|
||||
$this->ipsclass->html .= ""; // removed js popwin
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
// VIEW LAST 5
|
||||
//-----------------------------------------
|
||||
|
||||
|
||||
$this->ipsclass->DB->cache_add_query( 'warnlogs_list_current', array() );
|
||||
$this->ipsclass->DB->cache_exec_query();
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( "Type" , "5%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Warned Member" , "25%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Contacted?" , "5%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Date" , "25%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Warned By" , "25%" );
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( "Òèï" , "5%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Ïîëüçîâàòåëü" , "25%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Óâåäîìëåí?" , "5%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Âðåìÿ" , "25%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Ìîäåðàòîð" , "25%" );
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Ïîñëåäíèå 10 çàïèñåé" );
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Last 10 Warn Entries" );
|
||||
|
||||
if ( $this->ipsclass->DB->get_num_rows() )
|
||||
{
|
||||
while ( $row = $this->ipsclass->DB->fetch_row() )
|
||||
{
|
||||
$row['a_name'] = $row['a_name'] ? $row['a_name'] : 'Deleted Member (ID:' . $row['wlog_mid'] . ')';
|
||||
|
||||
$row['wlog_date'] = $this->ipsclass->admin->get_date( $row['wlog_date'], 'LONG' );
|
||||
|
||||
|
||||
$type = ( $row['wlog_type'] == 'pos' ) ? '<span style="color:green;font-weight:bold">-</span>' : '<span style="color:red;font-weight:bold">+</span>';
|
||||
$cont = ( $row['wlog_contact'] != 'none' ) ? "<center><a title='Ïîêàçàòü ñîîáùåíèå' href='javascript:pop_win(\"&{$this->ipsclass->form_code}&code=viewcontact&id={$row['wlog_id']}\",\"Log\",400,400)'><img src='{$this->ipsclass->skin_acp_url}/images/acp_check.gif' border='0' alt='X'></a></center>" : ' ';
|
||||
|
||||
$cont = ( $row['wlog_contact'] != 'none' ) ? "<center><a title='Show message' href='javascript:pop_win(\"&{$this->ipsclass->form_code}&code=viewcontact&id={$row['wlog_id']}\",\"Log\",400,400)'><img src='{$this->ipsclass->skin_acp_url}/images/acp_check.gif' border='0' alt='X'></a></center>" : ' ';
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array(
|
||||
"<center>$type</center>",
|
||||
"<b>{$row['a_name']}</b>",
|
||||
@@ -460,79 +459,80 @@ class ad_warnlogs {
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_basic("<center>Íåò çàïèñåé</center>");
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_basic("<center>No results</center>");
|
||||
}
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->end_table();
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( "Ïîëüçîâàòåëü" , "30%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Âðåìÿ ïðåäóïðåæäåíèÿ" , "20%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Ïðîñìîòð âñåõ ïðåäóïðåæäåíèé" , "20%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Óäàëåíèå âñåõ ïðåäóïðåæäåíèé" , "30%" );
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Æóðíàë ïðåäóïðåæäåíèé" );
|
||||
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( "Member Name" , "30%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Times Warned" , "20%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "View all by member" , "20%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( "Remove all by member" , "30%" );
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Saved Warn Logs" );
|
||||
|
||||
$this->ipsclass->DB->cache_add_query( 'warnlogs_list_current_two', array() );
|
||||
$this->ipsclass->DB->cache_exec_query();
|
||||
|
||||
|
||||
while ( $r = $this->ipsclass->DB->fetch_row() )
|
||||
{
|
||||
|
||||
$r['members_display_name'] = $r['members_display_name'] ? $r['members_display_name'] : 'Deleted Member (ID:' . $r['wlog_mid'] . ')';
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array( "<b>{$r['members_display_name']}</b>",
|
||||
"<center>{$r['act_count']}</center>",
|
||||
"<center><a href='".$this->ipsclass->base_url."&{$this->ipsclass->form_code}&code=view&mid={$r['wlog_mid']}'>Ïðîñìîòð</a></center>",
|
||||
"<center><a href='".$this->ipsclass->base_url."&{$this->ipsclass->form_code}&code=remove&mid={$r['wlog_mid']}'>Óäàëèòü</a></center>",
|
||||
"<center><a href='".$this->ipsclass->base_url."&{$this->ipsclass->form_code}&code=view&mid={$r['wlog_mid']}'>View</a></center>",
|
||||
"<center><a href='".$this->ipsclass->base_url."&{$this->ipsclass->form_code}&code=remove&mid={$r['wlog_mid']}'>Remove</a></center>",
|
||||
) );
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->end_table();
|
||||
|
||||
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
//-------------------------------
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_form( array( 1 => array( 'code' , 'view' ),
|
||||
2 => array( 'act' , 'warnlog' ),
|
||||
4 => array( 'section', $this->ipsclass->section_code ),
|
||||
) );
|
||||
|
||||
|
||||
$this->ipsclass->adskin->td_header[] = array( " " , "40%" );
|
||||
$this->ipsclass->adskin->td_header[] = array( " " , "60%" );
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Ïîèñê äåéñòâèé â æóðíàëå" );
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->start_table( "Search Warn Logs" );
|
||||
|
||||
$form_array = array(
|
||||
0 => array( 'notes' , 'Çàìåòêè' ),
|
||||
1 => array( 'contact', 'Îòïðàâêà Email/PM' ),
|
||||
0 => array( 'notes' , 'Entry Notes' ),
|
||||
1 => array( 'contact', 'Email/PM Sent' ),
|
||||
);
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array( "<b>Èñêàòü </b>" ,
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array( "<b>Search for...</b>" ,
|
||||
$this->ipsclass->adskin->form_input( "search_string")
|
||||
) );
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array( "<b>Èñêàòü â </b>" ,
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array( "<b>Search in...</b>" ,
|
||||
$this->ipsclass->adskin->form_dropdown( "search_type", $form_array)
|
||||
) );
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->end_form("Èñêàòü");
|
||||
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->end_form("Search");
|
||||
|
||||
$this->ipsclass->html .= $this->ipsclass->adskin->end_table();
|
||||
|
||||
|
||||
//-----------------------------------------
|
||||
//-------------------------------
|
||||
|
||||
|
||||
$this->ipsclass->admin->output();
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user