<!--#include file="../checkLogin.asp"-->
<!--#include file="../SQLconn.asp"-->
<!doctype html>
<html>
<head><title></title><meta http-equiv="Content-Type" content="text/html; charset=gb2312">

<link rel="stylesheet" type="text/css" href="../images/<%=request.cookies("imgdir")%>/css/style.css" media="all"/>

<body>
<%
'检查权限
 set RsPowder=Conn.Execute("select p.powderdetail  from teachers t,teacherpowder p  where t.powdergroup=p.powdergroup and tname='"&request.cookies("tname")&"' and powderdetail='员工档案'")
	 if  RsPowder.eof and  RsPowder.bof then
		quanxian="no"
	 end if 
sPowder.close
'检查权限结束
%>

<%		
		xingming=request("xingming")
		 
	%>
<table width="100%" height="495" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="27">
	<div class="header">
	<div class="nav">
        <ul>
            
            <li><a href="ZhengShuAdd.asp?xingming=<%=xingming%>">新增证书</a></li>
			<li class="on">证书列表</li>
            <li><a href="ZhengShuFind.asp?xingming=<%=xingming%>">证书查询</a></li>
			<li><a href="ZhengShuTotal.asp?xingming=<%=xingming%>">证书汇总</a></li>
        </ul>
    </div>	
	</td>
  </tr>
  <tr>
   <td height="400" valign="top"   class="NemuMainBox">
   
    <br>
			  <table width="95%" border="1" align="center" cellspacing="0"  class="mtable">
<tr>          <td align="center" valign="middle" class="STYLE1" >序号</td> 
		      <td align="center" valign="middle" class="STYLE1" >发证日期</td>
			  <td align="center" valign="middle" class="STYLE1" >教师姓名</td> 				  
		      <td height="30" align="center" valign="middle" class="STYLE1" >证书类别</td>
			  <td align="center" valign="middle" class="STYLE1" >证书级别</td>			 
			  <td align="center" valign="middle" class="STYLE1" >发证机关</td>
			  <td align="center" valign="middle" class="STYLE1" >内容说明</td>
		      <td align="center" valign="middle" class="STYLE1" >图片文件</td>
		      <td align="center" valign="middle" class="STYLE1" >登记日期</td> 
				  <td align="center" valign="middle" class="STYLE1" >操作</td>
				</tr>
				<% 
			 	if quanxian="no" then
				   sql="SELECT  *  FROM EmployeeZhengshu where   tname ='"&request.cookies("tname")&"'  order by id desc "
			    else
				   sql="SELECT  *  FROM EmployeeZhengshu  order by id desc "
				end if
			    Set rs=Server.CreateObject("Adodb.Recordset")
			    rs.open sql,conn,1,1
			    j=0
				rs.pagesize=13 '每页记录条数
				curpage=Request.QueryString("curpage") '将URL参数curpage传给curpage变量
				rs.absolutepage=curpage '将本页设为curpage设置的页数
				if curpage=0 then
				   curpage=1
				end if 
				 
				   for i= 1 to rs.pagesize
					  if rs.eof then
						 exit for
					  end if
				 							
				    j=j+1
				 %>
				
				<tr>  
				  <td width="5%" align="center" valign="middle" class="STYLE1" ><%=(curpage-1)*13+j%></td>
				   <td width="10%" align="center" valign="middle" class="STYLE1" ><%=rs("datetime")%></td>
				  <td width="8%" height="30" align="center" valign="middle" class="STYLE1" ><%=rs("tname")%> </td>  				
		
                  <td width="8%" align="center" valign="middle" class="STYLE1" ><%=rs("leibie")%></td>
			      <td width="8%" align="center" valign="middle" class="STYLE1" ><%=rs("jibie")%></td>
			     
				  <td width="15%" align="center" valign="middle" class="STYLE1" ><%=rs("发证机关")%></td>
				  <td width="15%" align="center" valign="middle" class="STYLE1" ><%=rs("shuoming")%></td>
				  <td width="8%" align="center" valign="middle" class="STYLE1" ><a href="showBigimg.asp?id=<%=rs("id")%>" target="_blank">
				图片</a></td>
				  <td width="10%" align="center" valign="middle" class="STYLE1" ><%=rs("登记日期")%></td>
				  
			     
				  <td width="8%" align="center" valign="middle" class="STYLE1" >
				  
				  <%if  request.cookies("tname")=rs("登记人")   then%>
				      <a href="delzhengshu.asp?id=<%=rs("id")%>&xingming=<%=xingming%>"  target="main" class="STYLE1"> 删除</a>
				   <%end if%>
				  </td>
				</tr>
				
				<%  rs.movenext
               next%>
  </table>
	 
	 
	 
	
	
             </td>
  </tr>
</table>
<br>
<div align="center" class="STYLE1">
<%if curpage=1 then%>
首页
<%else%>
<a href="?&curpage=1&id=<%=id%>>">首页</a>
<%end if%>

<%if curpage=1 then%>
上一页
<%else%>
<a href="?curpage=<%=curpage-1%>&id=<%=id%>">上一页</a>
<%end if%>

<%if rs.pagecount<curpage+1 then%>
下一页
<%else%>
<a href="?curpage=<%=curpage+1%>&id=<%=id%>">下一页</a>
<%end if%>

<%if rs.pagecount<curpage+1 then%>
尾页
<%else%>
<a href="?curpage=<%=rs.pagecount%>&id=<%=id%>">尾页</a>
<%end if%>
<span class="STYLE2">(当前第<%=curpage%>页，共有<%=rs.pagecount%>页，共有：<%=rs.recordcount%>条记录)</span></div>
</body>
</html>
