<%
    //-----------------------------------------------------------
    // 文件名称: Tool_AdminLog_Manage.aspx
    // 页面名称: 日志管理
    //
    // 描    述:
    //
    // 创建标识: Add By 吴建春 2008-08-13
    //-----------------------------------------------------------
%>

<%@ page language="C#" autoeventwireup="true" inherits="V5Shop.Admin.Tool_AdminLog_Manage, V5Shop.Shop.Tool" enableviewstatemac="false" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Register Src="control/PageBottom.ascx" TagName="PageBottom" TagPrefix="uc2" %>
<%@ Register Src="control/HiddenField.ascx" TagName="HiddenField" TagPrefix="uc1" %>
<%@ Register Src="control/ManageHeader.ascx" TagName="ManageHeader" TagPrefix="uc3" %>
<%@ Register TagPrefix="V5Shop" Namespace="V5Shop.Control" Assembly="V5Shop.Control" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>管理员操作日志</title>
    <link href="css/css.css" rel="stylesheet" type="text/css" />
    <link href="css/css_list.css" rel="stylesheet" type="text/css" />
    <link href="css/control.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" language="javascript" src="js/Control_Calendar.js"></script>
    <script type="text/javascript" language="javascript" src="js/Common.js"></script>
</head>
<body>
    <form id="form1" runat="server">
        <div>
            <uc3:ManageHeader ID="ManageHeader1" runat="server" />
            <div id="search">
                <div style="padding: 10px 20px; border: 1px #eeeeee solid; background: #f7f7f7">
                    <asp:Label ID="lblAdmin" runat="server" Text="操作者：" />
                    <asp:TextBox ID="txtAdminName" Width="100px" runat="server" class="input" />
                    <asp:Label ID="lblIp" runat="server" Text="操作IP：" />
                    <asp:TextBox ID="txtIp" runat="server" />
                    <asp:Label ID="lblType" runat="server" Text="操作日期：" />
                    <asp:TextBox ID="txtStartDate" runat="server" Width="80px" />
                    <img id="sltStart" src="images/calendar1.gif" title="打开日历" alt="打开日历" align="absmiddle" />
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" ControlToValidate="txtStartDate" runat="server" ErrorMessage="日期格式不正确" ValidationExpression="^\d{4}-\d{2}-\d{2}$" Display="Dynamic"></asp:RegularExpressionValidator>
                    －
                    <asp:TextBox ID="txtEndDate" runat="server" Width="80px" />
                    <img id="slEnd" src="images/calendar1.gif" title="打开日历" alt="打开日历" align="absmiddle" />
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator2" ControlToValidate="txtDelEndDate" runat="server" ErrorMessage="日期格式不正确" ValidationExpression="^\d{4}-\d{2}-\d{2}$" Display="Dynamic"></asp:RegularExpressionValidator>
                    <asp:Button ID="btnSearch" runat="server" Text="查询" OnClick="btnSearch_Click" class="button" CausesValidation="false" /></div>
            </div>
            <div id="content">
                <div style="padding: 3px 25px; color: #4B6888; border-bottom: 1px #CCCCCC solid">
                    <div style="float: left">
                        <input id="CheckAllBox" onclick="CheckAll()" type="checkbox" class="checkbox" />&nbsp;全选
                        <asp:CheckBox ID="cbDelByTime_disable" runat="server" Text="按时间清除" AutoPostBack="True" CssClass="checkboxaspx" OnCheckedChanged="cbDelByTime_disable_CheckedChanged" /></div>
                    <div style="float: left">
                        <asp:Panel ID="PanelDate" runat="server" Visible="false">
                            <asp:TextBox ID="txtDelStartDate" runat="server" Width="80px" />
                            <img id="sltDelStart" src="images/calendar1.gif" title="打开日历" alt="打开日历" align="absMiddle" />
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator3" ControlToValidate="txtDelStartDate" runat="server" ErrorMessage="日期格式不正确" ValidationExpression="^\d{4}-\d{2}-\d{2}$" Display="Dynamic" />
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtDelStartDate" Display="Dynamic" ErrorMessage="不能为空"></asp:RequiredFieldValidator>
                            <asp:Label ID="lblLine" runat="server" Text=" -" />
                            <asp:TextBox ID="txtDelEndDate" runat="server" Width="80px" />
                            <img id="sltDelEnd" src="images/calendar1.gif" title="打开日历" alt="打开日历" align="absMiddle" />&nbsp;
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator4" ControlToValidate="txtDelEndDate" runat="server" ErrorMessage="日期格式不正确" ValidationExpression="^\d{4}-\d{2}-\d{2}$" Display="Dynamic"></asp:RegularExpressionValidator>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txtDelEndDate" Display="Dynamic" ErrorMessage="不能为空"></asp:RequiredFieldValidator></asp:Panel>
                    </div>
                    <div style="float: left">
                        &nbsp;&nbsp;
                        <asp:LinkButton ID="btnDel" runat="server" ForeColor="#4B6888" OnClick="btnDel_Click" OnClientClick="return CheckDel()"><img src="images/icon/key_delete.gif" /> 删除</asp:LinkButton>
                    </div>
                    <br clear="all">
                </div>
                <div class="listborder">
                    <V5Shop:V5ShopGridView ID="GridViewShow" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" CssClass="datalist" HeaderStyle-Height="18px" HeaderStyle-ForeColor="#000" EmptyDataText="没有查询到任何记录" TableName="Notice" BorderWidth="0px" CacheName="AdminLog" GridLines="None" PageSize="12">
                        <Columns>
                            <asp:TemplateField meta:resourcekey="DetilData" ItemStyle-Width="5%">
                                <itemtemplate>
                                <input runat="server" value='<%# Eval("ID") %>' id="CheckBoxID" type="checkbox" class="checkbox"
                                    onmouseover="this.mouse='over'" onmouseout="this.mouse='out'" />
                                </itemtemplate>
                                <itemstyle horizontalalign="Center" />
                            </asp:TemplateField>
                            <asp:BoundField DataField="id" SortExpression="ID" HeaderText="ID" ItemStyle-Width="5%" />
                            <asp:BoundField DataField="Name" SortExpression="Name" HeaderText="操作者" ItemStyle-Width="10%" />
                            <asp:BoundField DataField="Type" SortExpression="Type" HeaderText="操作类型" ItemStyle-Width="6%" />
                            <asp:BoundField DataField="Page" SortExpression="Page" HeaderText="操作页面" ItemStyle-Width="25%" />
                            <asp:BoundField DataField="Date" SortExpression="Date" HeaderText="操作日期" ItemStyle-Width="10%" />
                            <asp:BoundField DataField="Record" SortExpression="Record" HeaderText="操作记录" ItemStyle-Width="30%" />
                            <asp:BoundField DataField="Ip" SortExpression="Ip" HeaderText="操作IP" ItemStyle-Width="9%" />
                        </Columns>
                        <PagerSettings Mode="NumericFirstLast" />
                        <HeaderStyle CssClass="category" ForeColor="Black" Height="18px" />
                    </V5Shop:V5ShopGridView>
                </div>
                <div id="hiddenfield">
                    <asp:HiddenField ID="CheckedIDS" runat="server" Value="0" />
                    <asp:HiddenField ID="PageIndex" runat="server" Value="0" />
                    <asp:HiddenField ID="MaxPageIndex" runat="server" Value="0" />
                    <uc1:HiddenField ID="Alert" runat="server" />
                </div>
                <uc2:PageBottom ID="PageBottom1" runat="server" />
                <script type="text/javascript">
        Calendar.setup({
            inputField     :    "txtStartDate",
            ifFormat       :    "%Y-%m-%d", 
            button         :    "sltStart",
            align          :    "Br",
            singleClick    :    true
        });
        Calendar.setup({
            inputField     :    "txtEndDate",
            ifFormat       :    "%Y-%m-%d", 
            button         :    "sltEnd",
            align          :    "Br",
            singleClick    :    true
        });
        if(document.getElementById("txtDelStartDate"))
        {
        Calendar.setup({
            inputField     :    "txtDelStartDate",
            ifFormat       :    "%Y-%m-%d", 
            button         :    "sltDelStart",
            align          :    "Br",
            singleClick    :    true
        });
        Calendar.setup({
            inputField     :    "txtDelEndDate",
            ifFormat       :    "%Y-%m-%d", 
            button         :    "sltDelEnd",
            align          :    "Br",
            singleClick    :    true
        });
        }
                </script>
            </div>
    </form>
</body>
</html>
