<%@ Page language="c#" Inherits="Discuz.ForumPage.Admin.audittopicgrid" Codebehind="forum_audittopicgrid.aspx.cs" %>
<%@ Register TagPrefix="cc1" Namespace="Discuz.Control" Assembly="Discuz.Control" %>
<%@ Register TagPrefix="uc1" TagName="AjaxPostInfo" Src="../UserControls/AjaxPostInfo.ascx" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
	<HEAD>
		<title>主题列表</title>
		<LINK href="../styles/dntmanager.css" type=text/css rel=stylesheet >
		<script language="javascript" src="../js/common.js"></script>
		<LINK href="../styles/calendarstyle.css" type="text/css" rel="stylesheet">
		<LINK href="../styles/datagrid.css" type="text/css" rel="stylesheet">		
		<script type="text/javascript">
            function check(browser)
            { 
               document.forms[0].operation.value=browser;
            }
		</script>
		<script language="javascript" src="../js/AjaxHelper.js" type="text/javascript"></script>
		<script language="javascript1.2" type="text/javascript">	
          function  LoadInfo(istopic,pid,tid)
            {            	 
                 AjaxHelper.Updater('../UserControls/AjaxPostInfo','AjaxPostInfo','istopic='+istopic+'&pid='+pid+'&tid='+tid);
                 alert("OK");
                 if(navigator.appName.indexOf("Explorer") > -1)
                 {
                     document.getElementById('PostInfo').style.display = "block";
                 }
                 else
                 {
                     document.getElementById('PostInfo').style.display = "block";
                 }
            }   
        </script>	
	    <script language="javascript" src="../js/common.js"></script>
</head>

	<body>
		<form id="Form1" method="post" runat="server">
		<br />
				
			<div class="DemoArea">
				<table>
					<tr>
						<td>
							<cc1:Button id="AudioSelectTopic" runat="server" Text="恢复选中的帖子"></cc1:Button>
							<cc1:Button id="AllAudioPass" runat="server" Text="全部恢复"></cc1:Button>&nbsp;
							<cc1:Button id="DeleteSelectTopic" runat="server" Text="删除选中的主题" ButtonImgUrl="../images/del.gif"></cc1:Button>&nbsp;
							<cc1:Button id="AllDelete" runat="server" Text="全部删除" ButtonImgUrl="../images/del.gif"></cc1:Button>&nbsp;</td>
					</tr>
				</table>
				<br />
				<input title="选中/取消选中 本页所有Case" onclick="CheckAll(this.form)" type="checkbox" name="chkall" id="chkall">全选/取消全选
			<cc1:datagrid id="DataGrid1" runat="server" OnPageIndexChanged="DataGrid_PageIndexChanged" OnSortCommand="Sort_Grid">
				<Columns>
				   <asp:TemplateColumn HeaderText="选择">
						<ItemTemplate>
							<INPUT id="tid" onclick="javascript:SH_SelectOne(this)" type="checkbox" value="<%# DataBinder.Eval(Container, "DataItem.tid").ToString() %>"	name="tid"></asp:Label>
						</ItemTemplate>
					</asp:TemplateColumn>
					<asp:BoundColumn DataField="tid" SortExpression="tid"  HeaderText="帖子ID" Visible="false"></asp:BoundColumn>
					<asp:TemplateColumn HeaderText="标题">
						<ItemTemplate>
							 <a href="javascript:void(0);" onclick="javascript:LoadInfo('true','0','<%# DataBinder.Eval(Container, "DataItem.tid").ToString() %>');"><%# DataBinder.Eval(Container, "DataItem.title").ToString() %></a>
						</ItemTemplate>
					</asp:TemplateColumn>
					<asp:BoundColumn DataField="poster" SortExpression="poster" HeaderText="发帖人"></asp:BoundColumn>
		         	<asp:BoundColumn DataField="postdatetime" SortExpression="postdatetime" HeaderText="发布日期"></asp:BoundColumn>
					<asp:BoundColumn DataField="lastposter" SortExpression="lastposter" HeaderText="最后回复人"></asp:BoundColumn>
						
					<asp:TemplateColumn HeaderText="回帖数">
						<ItemTemplate>
							<%# GetPostLink(DataBinder.Eval(Container, "DataItem.tid").ToString(),DataBinder.Eval(Container, "DataItem.replies").ToString()) %>
						</ItemTemplate>
					</asp:TemplateColumn>
					<asp:BoundColumn DataField="views" SortExpression="views" HeaderText="查看数"></asp:BoundColumn>
		         	<asp:BoundColumn DataField="digest" SortExpression="digest" HeaderText="精华帖"></asp:BoundColumn>
					<asp:BoundColumn DataField="displayorder" SortExpression="displayorder" HeaderText="显示顺序"></asp:BoundColumn>
					<asp:BoundColumn DataField="price" SortExpression="price" HeaderText="价格"></asp:BoundColumn>					
					<asp:TemplateColumn HeaderText="关闭">
						<ItemTemplate>
							<%# BoolStr(DataBinder.Eval(Container, "DataItem.closed").ToString()) %>
						</ItemTemplate>
					</asp:TemplateColumn>
								
			   	</Columns>
			</cc1:datagrid>
			<br />
			</div>			
			<div id="AjaxPostInfo" style="OVERFLOW-Y: auto;" valign="top">
				<uc1:AjaxPostInfo id="AjaxPostInfo1" runat="server"></uc1:AjaxPostInfo>
			</div>	
		</form>
		<%=footer%>
	</body>
</HTML>
