<!--<?php
include_once PrintEot('left');
if ($admintype == 'reportcontent') {
if (empty($action)) {print <<<EOT
-->
<div class="nav3 mb10 ta">
    <ul class="cc">
      <li class="current"><a href="$basename">未處理會員舉報</a></li>
      <li><a href="$basename&action=deal">已處理會員舉報</a></li>
    </ul>
</div>
<div class="admin_info mb10">
	<h2 class="h1">功能說明</h2>
	<div class="legend">
    	<ol>
        	<li>標記已處理:標記後系統會發送短消息提醒舉報的用戶</li>
            <li>刪除:沒有理由或者理由無效或者鏈接頁面不存在，建議用刪除</li>
        </ol>
    </div>
</div>
<form action="$basename" method="post" name="FORM">
  <input type="hidden" name="action" value="del">
  <h2 class="h1">未處理會員舉報列表<span class="linka">類型&nbsp;<select name="type" onchange="report_jump(this.value,'');">
    <option value="">全部</option>
    <option value="topic" $select_topic>帖子</option>
    <option value="diary" $select_dirary>日志</option>
    <option value="photo" $select_photo>照片</option>
    <option value="group" $select_group>群組</option>
    <option value="grouptopic" $select_grouptopic>群組帖子</option>
    <option value="groupphoto" $select_groupphoto>群組照片</option>
    <option value="user" $select_user>用戶</option></select></span></h2>
  <div class="admin_table mb10">
  <table width="100%" cellspacing="0" cellpadding="0">
    <tr class="tr2">
	  <td width="30"><span onclick="CheckAll(document.FORM)" class="cp">全選</span></td>
      <td width="60">類型</td>
      <td width="110">反映用戶</td>
      <td>原因</td>
      <td width="50">鏈接來源</td>
    </tr>
<!--
EOT;
if (empty($reportdb)) {print <<<EOT
-->
<tr><td class="p10" colspan="5"><div class="admin_tips">啊哦，沒有你要的信息！</div></td></tr>
<!--
EOT;
}else{
foreach($reportdb as $report){print <<<EOT
-->
    <tr class="tr1 vt">
      <td class="td2"><input type="checkbox" name="selid[]" value="$report[id]"></td>
      <td class="td2">{$report[type]}</td>
      <td class="td2"><a href="{$db_userurl}$report[uid]" target="_blank">$report[username]</a></td>
      <td class="td2">$report[reason]</td>
      <td class="td2"><a href="{$report[url]}" target="_blank">進入</a></td>
    </tr>
<!--
EOT;
}}print <<<EOT
-->
  </table>
  </div>
  <div class="cc mb10">$pages</div>
  <div class="tac mb10"><p>
  <input type="radio" name="action" value="done" checked>&nbsp;標記已處理 &nbsp;
  <input type="radio" name="action" value="del">&nbsp;刪除　　　</p>
    </div>
    <div class="tac mb10">
	<span class="bt"><span><button type="button" onclick="CheckAll(document.FORM)">全 選</button></span></span>
    <span class="btn"><span><button type="submit" name="hello">提 交</button></span></span>
    </div>
</form>

<!--
EOT;
} elseif ($action == 'deal') {print <<<EOT
-->
<div class="nav3 mb10 ta">
    <ul class="cc">
      <li><a href="$basename">未處理會員舉報</a></li>
      <li class="current"><a href="$basename&action=deal">已處理會員舉報</a></li>
    </ul>
 </div>
<form action="$basename&" method="post" name="FORM">
<h2 class="h1"><span class="mr20">已處理會員舉報列表</span><span class="linka">類型&nbsp;<select name="type" onchange="report_jump(this.value,'{$action}');">
    <option value="">全部</option>
    <option value="topic" $select_topic>帖子</option>
    <option value="diary" $select_dirary>日志</option>
    <option value="photo" $select_photo>照片</option>
    <option value="group" $select_group>群組</option>
    <option value="grouptopic" $select_grouptopic>群組帖子</option>
    <option value="groupphoto" $select_groupphoto>群組照片</option>
    <option value="user" $select_user>用戶</option></select></span></h2>
    <div class="admin_table mb10">
  <table width="100%" cellspacing="0" cellpadding="0">
    <tr class="tr2">
		<td width="30"><span onclick="CheckAll(document.FORM)" class="cp">全選</span></td>
        <td> 類型</td>
        <td>反映用戶</td>
        <td>原因</td>
        <td> 鏈接來源</td>
    </tr>
<!--
EOT;
if (empty($reportdb)) {print <<<EOT
-->
<tr><td class="p10" colspan="5"><div class="admin_tips">啊哦，沒有你要的信息！</div></td></tr>
<!--
EOT;
}else{
foreach($reportdb as $report){print <<<EOT
-->
    <tr class="tr1 t">
        <td class="td2"><input type="checkbox" name="selid[]" value="$report[id]"></td>
        <td class="td2">{$report[type]}</td>
        <td class="td2"><a href="{$db_userurl}$report[uid]" target="_blank">$report[username]</a></td>
        <td class="td2">$report[reason]</td>
        <td class="td2"><a href="{$report[url]}" target="_blank">進入</a></td>
    </tr>
<!--
EOT;
}}print <<<EOT
-->
  </table>
</div>
  <div class="cc">$pages</div>
    <input type="hidden" name="action" value="del">
    <div class="tac mb10">
	<span class="bt"><span><button type="button" onclick="CheckAll(document.FORM)">全 選</button></span></span>
    <span class="btn"><span><button type="submit" name="hello">刪除</button></span></span>
    </div>
</form>
<!--
EOT;
}print <<<EOT
-->
<script type="text/javascript">
var basename = '$basename';
function report_jump(type,action){
	if (!action) {
		location.href = basename+"&type="+type;
		return false;	
	}
	location.href = basename+"&action="+action+"&type="+type;
	return true;
}
</script>
<!--
EOT;
}elseif ($admintype == 'reportremind') {
print <<<EOT
-->
<div class="admin_info mb10">
	<h2 class="h1">功能說明</h2>
	<div class="legend">
    	<ol>
        	<li>在下方列表中的用戶會接收到舉報提醒信息，但處理舉報的權限要到相應的"用戶->用戶組權限"中設置。</li>
            <li>除此列表中的用戶外，各版塊版主會收到各自負責版塊內的帖子舉報信息。</li>
        </ol>
    </div>
</div>
<form name="FORM" id="remindmemberform" action="$basename&" method="post">
<input type="hidden" name="action" value="del" />
<h2 class="h1"><span class="fl mr10">接收提醒用戶列表</span>
<span id="addusername" style="display:none;">
	<input type="text" class="input" name="username" id="username" /><span class="btn2 f12"><span><button type="button" onclick="ajaxAdd();">提 交</button></span></span><span class="bt2 f12"><span><button type="button" onclick="showInput();">取 消</button></span></span>
</span>
<span class="btn_add fl" id="add">
	<i onclick="showInput();">添加</i>
</span>
<span id="addtip"></span>
</h2>
<div class="admin_table mb10" id="tablelist">
  <table width="100%" cellspacing="0" cellpadding="0">
  <tbody>
    <tr class="tr2">
	  	<td width="35"><span onclick="CheckAll(document.FORM)" class="cp">全選</span></td>
      <td width="150">用戶名</td>
      <td>用戶組</td>
    </tr>
<!--
EOT;
if (empty($remindMember)) {
$isEmpty = true;
print <<<EOT
-->
	<tr id="emptymember"><td class="p10" colspan="5"><div class="admin_tips">啊哦，沒有你要的信息！</div></td></tr>
<!--
EOT;
}else{
foreach($members as $member){
if (empty($member)) continue;
print <<<EOT
-->
	<tr class="tr1 t">
	  <td class="td2"><input type="checkbox" name="selid[]" value="$member[uid]"></td>
      <td class="td2"><a href="{$db_userurl}$member[uid]" target="_blank">$member[username]</a></td>
      <td class="td2">$member[groupname]</td>
    </tr>
<!--
EOT;
}}
print <<<EOT
-->
	</tbody>
   </table>
</div>
<div class="cc">$pages</div>
<div class="tac mb10">
	<span class="bt"><span><button type="button" onclick="CheckAll(document.FORM)">全 選</button></span></span>
	<span class="btn"><span><button type="submit" name="hello">刪除</button></span></span>
</div>
<input type="hidden" name="isempty" id="isempty" value="$isEmpty" />
</form>
<script type="text/javascript">
var basename = '$basename';
var db_userurl = '$db_userurl';
function showInput() {
	var addusername = getObj('addusername').style.display;
	var add = getObj('add').style.display;
	getObj('addusername').style.display = addusername == 'none' ? '' : 'none';
	getObj('add').style.display = add == 'none' ? '' : 'none';
	getObj('addtip').innerHTML = getObj('username').value = '';
}

function ajaxAdd() {
	var username = getObj('username').value;
	ajax.send(basename + '&ajax=1&action=add&username=' + username,'',function(){
		var rText = ajax.request.responseText;
		if (rText == 'empty') {
			getObj('addtip').innerHTML = '<span class="f12 s1 fn" style="margin-left:10px;">添加失敗，沒有找到指定用戶，請重新輸入</span>';
		} else if (rText == 'exists') {
			getObj('addtip').innerHTML = '<span class="f12 s1 fn" style="margin-left:10px;">該用戶已在接收舉報提醒用戶列表中，無需重復添加</span>';
		} else {
			var isempty = getObj('isempty').value;
			if (isempty == true) getObj('emptymember').style.display='none';
			var tableListInner = getObj('tablelist').innerHTML;
			showInput();
			getObj('addtip').innerHTML = '<span class="f12 fn s3" style="margin-left:10px;">添加成功</span>';
			rsText = rText.split('\t');
			addHtml = '<tr class="tr1 t"><td class="td2"><input type="checkbox" name="selid[]" value="' + rsText[0] + '"></td>';
			addHtml += '<td class="td2"><a href="' + db_userurl + rsText[0] + '" target="_blank">' + rsText[1] + '</a></td>';
			addHtml += '<td class="td2">' + rsText[2] + '</td></tr>';
			tableListInner = tableListInner.replace(/<\/tbody>\s*<\/table>/ig, '');
			getObj('tablelist').innerHTML = tableListInner + addHtml + '</tbody></table>';
			getObj('isempty').value = false;
		}
	});
}
</script>
<!--
EOT;
}
print <<<EOT
-->

<!--
EOT;
include_once PrintEot('adminbottom');
?>
-->
