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

<!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="../StyleSheet.css" rel="stylesheet" type="text/css" />
  
</head>
<body>
    <form id="form1" runat="server">
    <div style="margin-top:10px;">
        <div class="listTop">
            <span class="title">考试安排</span>
        </div>
        
        <asp:Repeater ID="Repeater1" runat="server">
            <HeaderTemplate>
             <table width="800px" class="tableList" border="0" cellpadding="0" cellspacing="0">
    <tr class="header"><td style="width:30px;">编号</td><td>考试名称</td><td>组卷方式</td><td>考试时长</td><td>有效起始日期</td><td>有效终止日期</td><td>参加考试</td></tr>
            </HeaderTemplate>
            <ItemTemplate>
                 <tr class="body">
             <td><%#Eval("TestID") %></td>
            <td>
                <%#Eval("TestName") %></td>
            <td>
                <%#Eval("PaperType")%></td>
            <td>
            <%#Eval("NeededMinutes") %>分钟
               </td>
            <td>
                 <%# ((DateTime)Eval("EnableDate")).ToShortDateString()%></td>
            <td>
                <%# ((DateTime)Eval("UnabaleDate")).ToShortDateString()%></td>
            <td>
               <%# ((bool)Eval("HasUnable"))==true ? "日期已过" : "" %>
               <%# ((bool)Eval("BeforeEnable")) == true ? "<span style='color:red'>日期未到</span>" : ""%>
              <%# (((bool)Eval("HasUnable"))==true || ((bool)Eval("BeforeEnable"))==true ) ? "" : string.Format("<a href='ConfirmBeforeTest.aspx?testID={0}&recorderID={1}&paperType={2}&paperID={3}'>参加考试</a>", Eval("TestID"), Eval("RecorderID"),(int)Eval("PaperType"),Eval("Paper.PaperID"))%>
                </td>
           </tr>
            </ItemTemplate>
            <FooterTemplate>
                    </table>
            </FooterTemplate>
        </asp:Repeater>
   
     <div class="listBottom"><span class="content">总共<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>条记录</span></div>
    <div class="tip"><span class="content">有效日期的说明：比如起始日期2009-3-1，终止日期：2009-3-4，则表示1、2、3、4号都可以考试。<br />
    如果出现日期已过，表示你未参加该次考试！</span></div>
    </div>
    </form>
</body>
</html>
