<%@ Register TagPrefix="uc1" TagName="LanguagesDeal" Src="LanguagesDeal.ascx" %>
<%@ Page language="c#" Codebehind="InternalLetterManage.aspx.cs" AutoEventWireup="True" validateRequest="false" Inherits="DreamerShop.Admin.InternalLetterManage" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
	<HEAD>
		<title>
			<%=myLanguagesDeal.GetMyString("TextVisitLimitManage")%>
		</title>
		<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
		<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR">
		<meta content="C#" name="CODE_LANGUAGE">
		<meta content="JavaScript" name="vs_defaultClientScript">
		<meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema">
		<META content="<%=mConfigInf.strDescription%>" name=description>
		<META content="<%=mConfigInf.strKeywords%>" name=keywords>
		<LINK href="style.css" type="text/css" rel="stylesheet">
		<LINK href="../StyleSheet1.css" rel="stylesheet">
		<SCRIPT language="javascript" id="clientEventHandlersJS">
		<!--

		
		function imgHelp_onclick() {
			popUpWin("DSHelp/SiteCounter.html","Help",100,100,800,600);
			}
			
		
		//-->
		</SCRIPT>
		<link rel="stylesheet" href="../editor/themes/default/default.css" />
	    <link rel="stylesheet" href="../editor/plugins/code/prettify.css" />
	    <script charset="utf-8" src="../editor/kindeditor.js"></script>
	    <script charset="utf-8" src="../editor/lang/zh_CN.js"></script>
	    <script charset="utf-8" src="../editor/plugins/code/prettify.js"></script>
	    <script>
	        KindEditor.ready(function (K) {
	            var editor1 = K.create('#txtContent', {
	                cssPath: '../editor/plugins/code/prettify.css',
	                uploadJson: '../editor/netfile/upload_json.ashx',
	                fileManagerJson: '../editor/netfile/file_manager_json.ashx',
	                allowFileManager: true,
	                afterCreate: function () {
	                    var self = this;
	                    K.ctrl(document, 13, function () {
	                        self.sync();
	                        K('form[name=example]')[0].submit();
	                    });
	                    K.ctrl(self.edit.doc, 13, function () {
	                        self.sync();
	                        K('form[name=example]')[0].submit();
	                    });
	                }
	            });
	            prettyPrint();
	        });
	    </script>
	</HEAD>
	<body MS_POSITIONING="GridLayout">
		<form id="Form1" method="post" runat="server">
			<asp:label id="lbEditID" runat="server" Visible="false"></asp:label><uc1:languagesdeal id="myLanguagesDeal" runat="server" Visible="False"></uc1:languagesdeal>
			<TABLE cellSpacing="0" cellPadding="0" width="97%" align="center" border="0">
				<TR>
					<TD vAlign="top" height="100%">
						<TABLE cellSpacing="0" cellPadding="0" width="100%" border="0">
							<TR>
								<TD vAlign="top" bgColor="#ffffff" height="319"><FONT face="宋体">
										<TABLE class="p9black" cellSpacing="0" cellPadding="0" width="100%" border="0">
											<TR>
												<TD style="WIDTH: 711px">
													<TABLE cellSpacing="0" cellPadding="0" width="100%" border="0">
														<TR>
															<TD class="p12black" align="left"><SPAN class="p9orange"><IMG height="11" src="IMAGES/icon_1.gif" width="12" align="absMiddle">&nbsp;<%=myLanguagesDeal.GetMyString("TextUserManage")%>
																	--&gt;<%=myLanguagesDeal.GetMyString("TextInternalLetterManage")%></SPAN></TD>
															<TD align="right" width="50"></TD>
														</TR>
													</TABLE>
												</TD>
											</TR>
										</TABLE>
										<hr noShade SIZE="1">
										<table width="100%" border="0">
											<tr>
												<td width="25%"><IMG src="../Images/Admin/intromenu-o_03.gif">&nbsp;
													<asp:linkbutton id="lbInbox" runat="server" CausesValidation="false" onclick="lbInbox_Click">收件箱</asp:linkbutton></td>
												<td width="25%"><IMG src="../Images/Admin/intromenu-o_03.gif">&nbsp;
													<asp:linkbutton id="lbWrite" runat="server" CausesValidation="false" onclick="lbWrite_Click">写信件</asp:linkbutton></td>
												<td width="25%"><IMG src="../Images/Admin/intromenu-o_03.gif">&nbsp;
													<asp:linkbutton id="lbOutbox" runat="server" CausesValidation="false" onclick="lbOutbox_Click">发件箱</asp:linkbutton></td>
												<td width="25%"><IMG src="../Images/Admin/intromenu-o_03.gif">&nbsp;<asp:linkbutton id="lbClear" runat="server" CausesValidation="false" onclick="lbClear_Click">信件清理</asp:linkbutton></td>
											</tr>
										</table>
										<br>
										<hr align="center" width="80%" SIZE="1">
										<div align="center"><asp:Label id="lbOperationTitle" runat="server" Font-Bold="True"></asp:Label></div>
										
										<asp:panel id="PanInbox" runat="server">
											<asp:panel id="PanInboxDetail" runat="server" Visible="False">
											<TABLE cellSpacing="1" cellPadding="3" width="100%" align="center" bgColor="#cccccc" border="0">
												<TR bgColor="#ffffff">
													<TD align="right" width="150"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextFormUser")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
													<TD class="pad">
														<asp:Label id="lbInboxUser" runat="server"></asp:Label>&nbsp;&nbsp;
														<asp:button id="btMsgToUser" runat="server" CssClass="go-wenbenkuang" Text="发信给他" onclick="btMsgToUser_Click"></asp:button></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD align="right"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextSendTime")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
													<TD class="pad">
														<asp:Label id="lbInboxTime" runat="server"></asp:Label></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD align="right"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextTitle")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
													<TD class="pad" >
														<asp:Label id="lbInboxTitle" runat="server"></asp:Label></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD align="right"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextContent")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
													<TD class="pad">
														<asp:Label id="lbInboxContent" runat="server"></asp:Label></TD>
												</TR>
											</TABLE>
										</asp:panel>
										<br>
										<asp:datagrid id="dgListInbox" runat="server" CssClass="table-shangxia" Width="100%" PageSize="20"
												AllowPaging="true" AutoGenerateColumns="False" DataKeyField="LetterID">
												<HeaderStyle HorizontalAlign="Center" BackColor="#F1F1F1"></HeaderStyle>
												<Columns>
													<asp:TemplateColumn HeaderText="InternalLetterManageTextTitle">
														<ItemTemplate>
															<%# DataBinder.Eval(Container.DataItem, "Title")%>
															&nbsp;<font color="red"><%# DataBinder.Eval(Container.DataItem, "IsNew")%></font>
														</ItemTemplate>
													</asp:TemplateColumn>
													<asp:BoundColumn DataField="UserName" HeaderText="InternalLetterManageTextFormUser">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
													<asp:BoundColumn DataField="SendTime" HeaderText="InternalLetterManageTextSendTime">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
													<asp:TemplateColumn HeaderText="TextOperation">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
														<ItemTemplate>
															<asp:Button id="btViewInf" Text="查看" CssClass="go-wenbenkuang" CommandName="GetDetails" Runat="server"></asp:Button>
															<asp:Button id="btDelete" Text="删除" CssClass="go-wenbenkuang" CommandName="Delete" Runat="server"></asp:Button>
														</ItemTemplate>
													</asp:TemplateColumn>
												</Columns>
												<PagerStyle Visible="False" NextPageText="下一页" PrevPageText="上一页" HorizontalAlign="Right"></PagerStyle>
											</asp:datagrid>
											<TABLE class="table-notop" width="100%" align="center" border="0">
												<TR align="center" bgColor="#f1f1f1">
													<TD>
														<asp:button id="btInFirst" runat="server" CssClass="go-wenbenkuang" Text=" 首 页" BorderStyle="Groove" onclick="btInFirst_Click"></asp:button>&nbsp;
														<asp:button id="btInPre" runat="server" CssClass="go-wenbenkuang" Text="上一页" BorderStyle="Groove" onclick="btInPre_Click"></asp:button>&nbsp;
														<asp:button id="btInNext" runat="server" CssClass="go-wenbenkuang" Text="下一页" BorderStyle="Groove" onclick="btInNext_Click"></asp:button>&nbsp;
														<asp:button id="btInLast" runat="server" CssClass="go-wenbenkuang" Text=" 尾 页" BorderStyle="Groove" onclick="btInLast_Click"></asp:button>&nbsp;
														<asp:label id="lbInPage" runat="server"></asp:label>&nbsp;
														<%=myLanguagesDeal.GetMyString("TextGotoPage")%>
														<asp:textbox id="txtInPageNum" runat="server" CssClass="wenbenkuang" Width="30px" MaxLength="3"></asp:textbox>
														<asp:CompareValidator id="cpvInPageNum" runat="server" Display="Dynamic" ControlToValidate="txtInPageNum"
															ErrorMessage="输入数字" Operator="DataTypeCheck" Type="Integer" ForeColor="#FF0000"></asp:CompareValidator><%=myLanguagesDeal.GetMyString("TextPages")%>
														<asp:Button id="btInGo" runat="server" CssClass="go-wenbenkuang" Text="Go" onclick="btInGo_Click"></asp:Button></TD>
												</TR>
											</TABLE>
											<BR>
										</asp:panel><asp:panel id="PanWrite" runat="server" Visible="False">
											<TABLE cellSpacing="1" cellPadding="3" width="720" align="center" bgColor="#cccccc" border="0">
												<TR bgColor="#ffffff">
													<TD align="right"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextToUser")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
													<TD class="pad">
														<asp:DropDownList id="drlLetterType" runat="server" AutoPostBack="True" onselectedindexchanged="drlLetterType_SelectedIndexChanged">
															<asp:ListItem Value="0">全部会员</asp:ListItem>
															<asp:ListItem Value="1">等级会员</asp:ListItem>
															<asp:ListItem Value="2">单一会员</asp:ListItem>
														</asp:DropDownList>&nbsp;&nbsp;
													</TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD align="right">
														<asp:Label id="lbToUserMode" runat="server"></asp:Label></TD>
													<TD class="pad" width="70%">
														<asp:DropDownList id="drlToUserGrade" runat="server" AutoPostBack="True">
															<asp:ListItem Value="0">全部会员</asp:ListItem>
														</asp:DropDownList>
														<asp:textbox id="txtToUserName" runat="server" CssClass="wenbenkuang" Width="100px" MaxLength="50"></asp:textbox>
														<asp:requiredfieldvalidator id="rfvToUserName" runat="server" Display="Dynamic" ControlToValidate="txtToUserName"
															ErrorMessage="请输入用户名" ForeColor="#FF0000"></asp:requiredfieldvalidator></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD align="right"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextTitle")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
													<TD class="pad" width="360">
														<asp:textbox id="txtWriteTitle" runat="server" CssClass="wenbenkuang" Width="300px" MaxLength="100"></asp:textbox>
														<asp:requiredfieldvalidator id="rfvWriteTitle" runat="server" Display="Dynamic" ControlToValidate="txtWriteTitle"
															ErrorMessage="请输入标题" ForeColor="#FF0000"></asp:requiredfieldvalidator></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD noWrap align="right" width="20%"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextContent")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--关闭说明：--></TD>
													<TD>
														<textarea id="txtContent" cols="100" rows="8" style="width:500px;height:200px;visibility:hidden;" runat="server" ></textarea></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD align="right" width="20%"></TD>
													<TD class="pad">&nbsp;
														<asp:button id="btWriteSend" runat="server" CssClass="go-wenbenkuang" Text="发送信件" onclick="btWriteSend_Click"></asp:button></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD align="center" colSpan="2">
														<asp:Label id="lbWriteInfo" runat="server" ForeColor="Red"></asp:Label></TD>
												</TR>
											</TABLE>
										</asp:panel><asp:panel id="PanOutbox" runat="server" Visible="False">
										<asp:panel id="PanOutboxDetail" runat="server" Visible="False">
												<TABLE cellSpacing="1" cellPadding="3" width="100%" align="center" bgColor="#cccccc" border="0">
													<TR bgColor="#ffffff">
														<TD align="right" width="150"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextToUser")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
														<TD class="pad">
															<asp:Label id="lbOutboxUser" runat="server"></asp:Label>&nbsp;&nbsp;
														</TD>
													</TR>
													<TR bgColor="#ffffff">
														<TD align="right"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextSendTime")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
														<TD class="pad">
															<asp:Label id="lbOutboxTime" runat="server"></asp:Label></TD>
													</TR>
													<TR bgColor="#ffffff">
														<TD align="right"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextTitle")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
														<TD class="pad">
															<asp:Label id="lbOutboxTitle" runat="server"></asp:Label></TD>
													</TR>
													<TR bgColor="#ffffff">
														<TD align="right"><%=myLanguagesDeal.GetMyString("InternalLetterManageTextContent")%><%=myLanguagesDeal.GetMyString("TextColonCharacter")%><!--名称：--></TD>
														<TD class="pad">
															<asp:Label id="lbOutboxContent" runat="server"></asp:Label></TD>
													</TR>
												</TABLE>
											</asp:panel>
											<br>
											<asp:datagrid id="dgListOutbox" runat="server" CssClass="table-shangxia" Width="100%" PageSize="20"
												AllowPaging="true" AutoGenerateColumns="False" DataKeyField="LetterID">
												<HeaderStyle HorizontalAlign="Center" BackColor="#F1F1F1"></HeaderStyle>
												<Columns>
													<asp:BoundColumn DataField="Title" HeaderText="InternalLetterManageTextTitle">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
													<asp:BoundColumn DataField="UserName" HeaderText="InternalLetterManageTextToUser">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
													<asp:BoundColumn DataField="SendTime" HeaderText="InternalLetterManageTextSendTime">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
													</asp:BoundColumn>
													<asp:TemplateColumn HeaderText="TextOperation">
														<ItemStyle HorizontalAlign="Center"></ItemStyle>
														<ItemTemplate>
															<asp:Button id="btOutViewInf" Text="查看" CssClass="go-wenbenkuang" CommandName="GetDetails" Runat="server"></asp:Button>
															<asp:Button id="btOutDelete" Text="删除" CssClass="go-wenbenkuang" CommandName="Delete" Runat="server"></asp:Button>
														</ItemTemplate>
													</asp:TemplateColumn>
												</Columns>
												<PagerStyle Visible="False" NextPageText="下一页" PrevPageText="上一页" HorizontalAlign="Right"></PagerStyle>
											</asp:datagrid>
											<TABLE class="table-notop" width="100%" align="center" border="0">
												<TR align="center" bgColor="#f1f1f1">
													<TD>
														<asp:button id="btOutFirst" runat="server" CssClass="go-wenbenkuang" Text=" 首 页" BorderStyle="Groove" onclick="btOutFirst_Click"></asp:button>&nbsp;
														<asp:button id="btOutPre" runat="server" CssClass="go-wenbenkuang" Text="上一页" BorderStyle="Groove" onclick="btOutPre_Click"></asp:button>&nbsp;
														<asp:button id="btOutNext" runat="server" CssClass="go-wenbenkuang" Text="下一页" BorderStyle="Groove" onclick="btOutNext_Click"></asp:button>&nbsp;
														<asp:button id="btOutLast" runat="server" CssClass="go-wenbenkuang" Text=" 尾 页" BorderStyle="Groove" onclick="btOutLast_Click"></asp:button>&nbsp;
														<asp:label id="lbOutPage" runat="server"></asp:label>&nbsp;
														<%=myLanguagesDeal.GetMyString("TextGotoPage")%>
														<asp:textbox id="txtOutPageNum" runat="server" CssClass="wenbenkuang" Width="30px" MaxLength="3"></asp:textbox>
														<asp:CompareValidator id="cpvOutPageNum" runat="server" Display="Dynamic" ControlToValidate="txtOutPageNum"
															ErrorMessage="输入数字" Operator="DataTypeCheck" Type="Integer" ForeColor="#FF0000"></asp:CompareValidator><%=myLanguagesDeal.GetMyString("TextPages")%>
														<asp:Button id="btOutGo" runat="server" CssClass="go-wenbenkuang" Text="Go" onclick="btOutGo_Click"></asp:Button></TD>
												</TR>
											</TABLE>
											<BR>
											
										</asp:panel>
										<asp:panel id="PanClear" runat="server" Visible="False">
											<TABLE cellSpacing="1" cellPadding="3" width="550" align="center" bgColor="#cccccc" border="0">
												<TR bgColor="#ffffff">
													<TD class="pad">
														<asp:Label id="lbInboxTotal" runat="server"></asp:Label></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD class="pad">
														<asp:DropDownList id="drlDelInbox" runat="server" AutoPostBack="True">
															<asp:ListItem Value="0">全部</asp:ListItem>
															<asp:ListItem Value="7">一周</asp:ListItem>
															<asp:ListItem Value="30">一个月</asp:ListItem>
															<asp:ListItem Value="180" Selected="True">半年</asp:ListItem>
														</asp:DropDownList>&nbsp;&nbsp;
														<asp:Button id="btDelInbox" runat="server" CssClass="go-wenbenkuang" Text=" 删 除 " onclick="btDelInbox_Click"></asp:Button></TD>
												</TR>
											</TABLE>
											<BR>
											<TABLE cellSpacing="1" cellPadding="3" width="550" align="center" bgColor="#cccccc" border="0">
												<TR bgColor="#ffffff">
													<TD class="pad">
														<asp:Label id="lbOutboxTotal" runat="server"></asp:Label></TD>
												</TR>
												<TR bgColor="#ffffff">
													<TD class="pad">
														<asp:DropDownList id="drlDelOutbox" runat="server" AutoPostBack="True">
															<asp:ListItem Value="0">全部</asp:ListItem>
															<asp:ListItem Value="7">一周</asp:ListItem>
															<asp:ListItem Value="30">一个月</asp:ListItem>
															<asp:ListItem Value="180" Selected="True">半年</asp:ListItem>
														</asp:DropDownList>&nbsp;&nbsp;
														<asp:Button id="btDelOutbox" runat="server" CssClass="go-wenbenkuang" Text=" 删 除 " onclick="btDelOutbox_Click"></asp:Button></TD>
												</TR>
											</TABLE>
										</asp:panel>
									</FONT>
								</TD>
							</TR>
						</TABLE>
					</TD>
				</TR>
			</TABLE>
		</form>
	</body>
</HTML>
