<%@ Page language="c#" Inherits="Discuz.ForumPage.Admin.attachtypesgrid" Codebehind="forum_attachtypesgrid.aspx.cs" %>
<%@ Register TagPrefix="cc1" Namespace="Discuz.Control" Assembly="Discuz.Control" %>
<%@ Register TagPrefix="cc2" Namespace="Discuz.Control" Assembly="Discuz.Control" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
	<HEAD>
		<title>上传附件类型列表</title>
		<LINK href="../styles/datagrid.css" type="text/css" rel="stylesheet">
		<script language="javascript" src="../js/common.js"></script>
		<link href="../styles/dntmanager.css" type="text/css" rel="stylesheet">   
	</HEAD>
	<body>
		<form id="Form1" method="post" runat="server">
			<script language="javascript">
showhint(0, ' 本功能可限定某特定类型附件的最大尺寸, 当这里设定的尺寸小于用户组允许的最大尺寸时, 指定类型的附件尺寸限制将按本设定为准');
showhint(1, ' 附件是否有效可在版块及用户组中设置, 且具体版块设置优先于用户组设置');
			</script>
			<table cellspacing="1" cellpadding="4" width="100%" align="center" class="table1" style="MARGIN: 10px">
				<TBODY>
					<tr>
						<td class="category"><input title="选中/取消选中 本页所有Case" onclick="CheckAll(this.form)" type="checkbox" name="chkall" id="chkall">全选/取消全选 
							&nbsp;
							<cc1:Button id="DelRec" runat="server" Text=" 删 除 "  ButtonImgUrl="../images/del.gif"></cc1:Button>
						</td>
					</tr>
				</TBODY>
			</table>
			<cc1:datagrid id="DataGrid1" runat="server" OnCancelCommand="DataGrid_Cancel" OnEditCommand="DataGrid_Edit"
				OnPageIndexChanged="DataGrid_PageIndexChanged" OnSortCommand="Sort_Grid" OnUpdateCommand="DataGrid_Update"
				OnDeleteCommand="DataGrid_Delete">
				<Columns>
				    <asp:TemplateColumn HeaderText="选择">
						<ItemTemplate>
							<INPUT id="id" onclick="javascript:SH_SelectOne(this)" type="checkbox" value="<%# DataBinder.Eval(Container, "DataItem.id").ToString() %>"	name="id"></asp:Label>
						</ItemTemplate>
					</asp:TemplateColumn>
					<asp:BoundColumn DataField="id" SortExpression="id" HeaderText="id [递增]" Visible="false"></asp:BoundColumn>
					<asp:BoundColumn DataField="extension" SortExpression="extension" HeaderText="扩展名"></asp:BoundColumn>
					<asp:BoundColumn DataField="maxsize" SortExpression="maxsize" HeaderText="最大尺寸(单位:字节)"></asp:BoundColumn>
				</Columns>
			</cc1:datagrid>
		<div class="ManagerForm">
        <fieldset>
		<legend style="background:url(../images/icons/icon50.jpg) no-repeat 6px 50%;">添加附件类型</legend>
			<table cellspacing="0" cellPadding="4" class="table1" align="center" width="100%">
				<tr>
					<td class="td1" width="10%">扩展名:</td>
					<td class="td1" width="40%">
						<cc2:TextBox id="extension" runat="server" RequiredFieldType="暂无校验" IsReplaceInvertedComma="true" MaxLength="15" Size="15"></cc2:TextBox></td>
					<td class="td2" width="10%">最大尺寸:</td>
					<td class="td2" width="40%">
						<cc2:TextBox id="maxsize" runat="server" RequiredFieldType="数据校验"  size="9" MaxLength="8"></cc2:TextBox>(单位:字节)
						<select onchange="document.getElementById('maxsize').value=this.value">
									<option value="">请选择</option>
									<option value="51200">50K</option>
									<option value="102400">100K</option>
									<option value="153600">150K</option>
									<option value="204800">200K</option>
									<option value="256000">250K</option>
									<option value="307200">300K</option>
									<option value="358400">350K</option>
									<option value="409600">400K</option>
									<option value="512000">500K</option>
									<option value="614400">600K</option>
									<option value="716800">700K</option>
									<option value="819200">800K</option>
									<option value="921600">900K</option>
									<option value="1024000">1M</option>
									<option value="2048000">2M</option>
									<option value="4096000">4M</option>
									
							</select>
						</td>
				</tr>
				<tr><td colspan="4" align="center"><cc1:Button id="AddNewRec" runat="server" Text=" 提 交 "></cc1:Button></td></tr>
			</table>
			</fieldset>
			</div>
		</form>
		<%=footer%>
	</body>
</HTML>
