<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="login_semester.aspx.cs" Inherits="Web.sy.admin.login_semester" %>

<!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 id="Head1" runat="server">
    <title>OA标题页</title>
<link href="../../css/admincss/skin.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../../css/popcalendar.js"></script>
    </head>
<body>
    <form id="form1" runat="server" >
<div>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr>
        <td   class ="top_bg_left "></td>
    <td  class ="top_bg_center " >
    <table style ="width :100%; height :31px"  border="0" cellpadding="0" cellspacing="0" class="left_topbg" id="table2">
      <tr>
      
<!--这里写页标题 -->
        <td style ="height :31px"><div class="titlebt">系统设置</div></td>
      </tr>
    </table>
    </td> 
    <td class ="top_bg_right "></td>
  </tr>
  <tr>
    <td style ="background :url(../../css/admincss/images/mail_leftbg.gif); vertical-align :middle " >&nbsp;</td>
    <td style ="background-color :#F7F8F9; vertical-align :top " >

   <!--  一组内容模块开始   --> 
    <table class ="tablezong"   border="0"  cellpadding="0" cellspacing="0">
      <tr>
        <td style ="height :40px" >
        <table class="tablebiaoti"  border="0" cellpadding="0" cellspacing="0" >
          <tr>
            <td><div class ="biaotileft ">  
             学期设置</div> </td>
          </tr>
        </table>
        </td>
      </tr>
      <tr>
        <td>
        <div>
                   学期：<asp:TextBox ID="tbsemester" runat="server"     Width ="250px"></asp:TextBox> 
                  &nbsp;每天最大课时数：<asp:TextBox ID="tbClassnum" runat="server"     Width ="40px"></asp:TextBox> 
                  &nbsp;<asp:CheckBox ID="CheckBox1" runat="server" Text="当前学期" />
                  &nbsp;<asp:Button ID="btAddsemester" runat="server" Text="添加" 
                        onclick="btAddsemester_Click" ValidationGroup="add" />  
          
              <asp:RequiredFieldValidator ID="RequiredFieldValidator1" 
                  runat="server" ControlToValidate="tbsemester" Display="Dynamic" 
                  ErrorMessage="请填写学期名称。" ValidationGroup="add" ForeColor="Red"></asp:RequiredFieldValidator>
          
              <asp:RequiredFieldValidator ID="RequiredFieldValidator2" 
                  runat="server" ControlToValidate="tbClassnum" Display="Dynamic" 
                  ErrorMessage="请填写每天最大课时数。" ValidationGroup="add" ForeColor="Red"></asp:RequiredFieldValidator>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" 
                   ControlToValidate="tbClassnum" Display="Dynamic" ErrorMessage="请在每天最大课时数中输入大于0的整数。" 
                   ForeColor="Red" ValidationExpression="^\+?[1-9][0-9]*$" ValidationGroup="add"></asp:RegularExpressionValidator>
                                           
                    </div>
<div>
<asp:GridView ID="GridView1" runat="server" Width="100%" CssClass="gv" 
            cellspacing="1" BorderWidth="1px" 
                AutoGenerateColumns="False" 
        onrowdatabound="gv_RowDataBound" onrowcreated="GridView1_RowCreated" 
        onselectedindexchanging="GridView1_SelectedIndexChanging" 
        onrowdeleting="GridView1_RowDeleting" >
            <RowStyle  CssClass="gvrow" BorderWidth="1px" />
                <Columns>
                    <asp:BoundField DataField="id" HeaderText="id" ReadOnly="True" />
                    <asp:BoundField DataField="semestername" HeaderText="学期" ReadOnly="True" />
                    <asp:BoundField DataField="classnum" HeaderText="每天最大课时数" ReadOnly="True" />
                    <asp:BoundField DataField="state" HeaderText="是否为当前学期" ReadOnly="True" />
                    <asp:CommandField HeaderText="切换" SelectText="切换为当前学期" 
                        ShowSelectButton="True" />
                           <asp:CommandField HeaderText="删除" ShowDeleteButton="True" />
                </Columns>
            <HeaderStyle  CssClass="gvhead"  />
        </asp:GridView>
                    </div>
        </td>
      </tr>
    </table>
<!-- 一组内容模块结束 -->
    </td>
    <td  style =" background-image:url(../../css/admincss/images/mail_rightbg.gif )" >
    </td>
  </tr>
  <tr>
<td  class ="buttom_bg_left "></td>
  <td   class ="buttom_bg_center " ></td>
    <td  class ="buttom_bg_right " ></td>
  </tr>
</table>
    </div>
    </form>
</body>
</html>