<%@ Page Language="C#" AutoEventWireup="true" CodeFile="UserInfo.aspx.cs" Inherits="_UserInfo" %>

<%@ Register Src="../../../Control/PageNo.ascx" TagName="PageNo" TagPrefix="uc1" %>
<!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">
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
    <title>会员管理</title>
    <link rel="stylesheet" href="../../skin/style.css" type="text/css" />
</head>

<script type="text/javascript" src="../../../js/jquery.js"></script>

<body>
    <form id="form1" runat="server">
        <div class="itemtitle">
            <h3>
                操作提示</h3>
        </div>
        <div class="itemtitle_tect">
            <p>
                会员名：<asp:TextBox ID="txtLoginName" runat="server"></asp:TextBox>
                &nbsp;公司名：
                <asp:TextBox ID="txtCompanyName" runat="server"></asp:TextBox>
                <asp:Button ID="btnSearch" runat="server" OnClick="btnSearch_Click" Text="立即查询" CssClass="i_button" />
            </p>
        </div>
        <div class="clr">
        </div>
        <div class="talbe_border">
            <asp:GridView ID="grdUser" runat="server" AutoGenerateColumns="False" CellPadding="0"
                BorderStyle="None" DataKeyNames="UserID" OnRowDataBound="grdUser_RowDataBound"
                GridLines="None" AllowPaging="False" CssClass="talbe_list">
                <Columns>
                    <asp:TemplateField>
                        <ItemTemplate>
                            <asp:CheckBox ID="CheckBox1" runat="server" />
                            <asp:Label ID="lblUserID" runat="server" Text='<%# Eval("UserID") %>' Visible="false"></asp:Label>
                        </ItemTemplate>
                        <HeaderStyle CssClass="th20 tou" />
                        <ItemStyle CssClass="nolet" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="会员名">
                        <ItemStyle CssClass="left2" />
                        <ItemTemplate>
                            <a href="LoginInfoEdit.aspx?UserID=<%# Eval("UserID") %>">
                                <%# Eval("LoginName")%>
                            </a>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:BoundField DataField="CompanyName" HeaderText="公司名称">
                        <HeaderStyle CssClass="th75" />
                    </asp:BoundField>
                    <asp:TemplateField HeaderText="服务开始时间">
                        <ItemTemplate>
                            <%# GetShortDate(DataBinder.Eval(Container.DataItem, "StartDate").ToString())%>
                        </ItemTemplate>
                        <HeaderStyle CssClass="th80" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="服务截至时间">
                        <ItemTemplate>
                            <%# GetShortDate(DataBinder.Eval(Container.DataItem, "EndDate").ToString())%>
                        </ItemTemplate>
                        <HeaderStyle CssClass="th80" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="锁定">
                        <ItemTemplate>
                            <asp:LinkButton ID="lbtnUpdateLockedup" Font-Underline="false" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "Lockedup").ToString()== "True" ? "已锁定" : "未锁定"%>'
                                CommandArgument='<%# DataBinder.Eval(Container.DataItem, "UserID")+"|"+DataBinder.Eval(Container.DataItem, "Lockedup")%>'
                                OnCommand="lbtnUpdateLockedup_Command"></asp:LinkButton>
                        </ItemTemplate>
                        <HeaderStyle CssClass="th25" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="审核">
                        <ItemTemplate>
                            <asp:LinkButton ID="lbtnUpdate" Font-Underline="false" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "Verify").ToString()== "True" ? "已审" : "未审"%>'
                                CommandArgument='<%# DataBinder.Eval(Container.DataItem, "UserID")+"|"+DataBinder.Eval(Container.DataItem, "Verify")%>'
                                OnCommand="lbtnUpdate_Command"></asp:LinkButton>
                        </ItemTemplate>
                        <HeaderStyle CssClass="th25" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="编辑">
                        <ItemTemplate>
                            <a href='UserEdit.aspx?UserID=<%# DataBinder.Eval(Container.DataItem, "UserID")%>'>编辑
                            </a>|
                            <asp:LinkButton CommandName="delete" ID="lnkdelete" CommandArgument='<%# DataBinder.Eval(Container.DataItem, "UserID") %>'
                                OnCommand="lnkdelete_Command" runat="server" Text="删除" OnClientClick="return confirm('你确定要删除吗?')"></asp:LinkButton>
                        </ItemTemplate>
                        <HeaderStyle CssClass="th80" />
                    </asp:TemplateField>
                </Columns>
                <HeaderStyle CssClass="header" />
            </asp:GridView>
            <asp:Label ID="lblMessage" runat="server" Text=""></asp:Label>
            <div class="Paging">
                <input id="CheckBox2" name="CheckBox2" type="checkbox" onclick="SelectAll();" />全选
                <asp:Button ID="btnDelete" runat="server" Font-Size="9pt" Text="批量删除" OnClick="btnDelete_Click"
                    CssClass="i_button" />
                <uc1:PageNo ID="PageNo1" runat="server" />
            </div>
        </div>
    </form>
</body>
</html>
