<%@ Page Language="C#" AutoEventWireup="true" Inherits="System_Info_LinkList, QianboCMS" EnableEventValidation="false" %>
<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<%@ Import Namespace="Qianbo.Common" %>
<!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>
<script type="text/javascript" src="../../Js/Common.js"></script>
<link type="text/css" href="../Css/layout.css" rel="Stylesheet" />
</head>

<body>
<form id="form1" runat="server">
  <table width="99%" cellspacing="1" cellpadding="0" class="wzdh" align="center">
    <tr>
      <td style="padding-left: 10px;"><img src="../Images/Skin/Default/you.gif" align="absmiddle" /> 您现在的位置：<a href="../SystemInfo.aspx">后台管理</a> &gt;&gt; <a href="LinkList.aspx">友情链接管理</a> &gt;&gt; 友情链接列表</td>
    </tr>
  </table>
  <table width="99%" cellspacing="1" cellpadding="0" class="border" align="center">
    <tr class="wzlist">
      <td><span style="float: left;"><asp:LinkButton ID="lnkbtnAll" runat="server" OnClick="lnkbtnAll_Click">所有友情链接</asp:LinkButton> | <a href="Link.aspx?action=add">添加友情链接</a></span>
        <span style="float: right;">按类型查看：
        <asp:DropDownList ID="ddlHeaderLinkType" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddlHeaderLinkType_SelectedIndexChanged"></asp:DropDownList>
        按分类查看：
        <asp:DropDownList ID="ddlHeaderCategory" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddlHeaderCategory_SelectedIndexChanged"></asp:DropDownList></span></td>
    </tr>
  </table>
  <table id="rptTable" class="border" align="center" width="99%" cellpadding="0" cellspacing="1">
    <asp:Repeater ID="rptLink" runat="server" OnItemCommand="rptLinkItemCommand" OnItemDataBound="rptItemDataBound">
      <HeaderTemplate>
        <tr class="title">
          <td width="30px">选择</td>
          <td width="30px">编号</td>
          <td>站点名称</td>
          <td width="60px">链接类型</td>
          <td width="60px">所属分类</td>
          <td width="120px">站长名称</td>
          <td width="180px">联系邮箱</td>
          <td width="90px">申请时间</td>
          <td width="90px">状态</td>
          <td width="150px">常规操作</td>
        </tr>
      </HeaderTemplate>
      <ItemTemplate>
        <tr class="tdbg" onmouseover="this.className='tdbgmouseover'" onmouseout="this.className='tdbg'">
          <td><asp:CheckBox ID="chkBox" runat="server" /></td>
          <td><asp:Literal ID="LitId" runat="server" Text='<%#Eval("LinkId") %>'></asp:Literal></td>
          <td><a href="Link.aspx?LinkId=<%#Eval("LinkId") %>" title="修改"><%#Function.HtmlEncode(Eval("SiteName").ToString()) %></a></td>
          <td><%#Eval("LinkType").ToString()=="1"?"文字链接":"图片链接" %></td>
          <td><%#Eval("LinkCategory") %></td>
          <td><%#Function.HtmlEncode(Eval("OwnerName").ToString()) %></td>
          <td><a href="mailto:<%#Eval("Email") %>" title="发送邮件"><%#Eval("Email") %></a></td>
          <td><%#Eval("AddTime","{0:d}") %></td>
          <td><asp:Label ID="lbStatus" runat="server" Text='<%#Eval("Status")%>'></asp:Label>
            <asp:Label ID="lbIsDisable" runat="server" Text='<%#Eval("IsDisable") %>'></asp:Label></td>
          <td><a href="Link.aspx?LinkId=<%#Eval("LinkId") %>">修改</a>
            <asp:LinkButton ID="lnkbtnDelete" runat="server" OnClientClick="return confirm('是否确定删除此友情链接？')" CommandArgument='<%#Eval("LinkId") %>' CommandName="Delete">删除</asp:LinkButton>
            <asp:LinkButton ID="lnkbtnPass" runat="server" CommandArgument='<%#Eval("LinkId") %>' CommandName="Pass">通过</asp:LinkButton>
            <asp:LinkButton ID="lnkbtnDisable" runat="server" CommandArgument='<%#Eval("LinkId") +"|"+Eval("IsDisable")%>' CommandName="Disable">停用</asp:LinkButton></td>
        </tr>
      </ItemTemplate>
    </asp:Repeater>
  </table>
  <table class="border" cellpadding="0" cellspacing="1" align="center">
    <tr class="wzlist">
      <td><webdiyer:AspNetPager ID="Pager" runat="server" AlwaysShow="True" FirstPageText="首页" HorizontalAlign="Right" LastPageText="尾页" NextPageText="下一页" OnPageChanging="Pager_PageChanging" PageSize="20" PrevPageText="上一页" ShowCustomInfoSection="Left" ShowInputBox="Never" ShowNavigationToolTip="True" Width="99%" LayoutType="Table" CustomInfoSectionWidth="10%"></webdiyer:AspNetPager></td>
    </tr>
  </table>
  <table class="border" cellpadding="0" cellspacing="1" align="center">
    <tr class="wzlist">
      <td><input type="checkbox" id="chk" onclick="SelectAll('chk','rptTable');" />
        全选
        <asp:Button ID="btnDelAll" runat="server" CssClass="btn" Text="删除所选项" OnClientClick="return confirm('是否确定删除所选项？')" OnClick="btnDelAll_Click" /></td>
    </tr>
  </table>
</form>
</body>
</html>