<!--#include file="Config.asp" -->
<div class='menu'>&nbsp;回收站管理</div>
<%
eTable = Prefix&eims
ListUrl = "Recycle.asp?eims="&eims
Mgt("p01") 'Cookies : Permission
'还原数据
If Trim(Request("submit"))="还原" Then
Mgt("admin") 'Cookies : Permission
if Trim(Request("BoxID"))="" then WtMsg("没有选择数据")
Conn.Execute "Update ["&eTable&"] set ItemRec=1 where ItemID in ("&Trim(Request("BoxID"))&")"
Response.Redirect ListUrl
End If
%>
<div class="title">
<form method='post' name='sForm' action="<%=ListUrl%>">
  <table width="100%" border="0" cellspacing="1" cellpAdding="1">
    <tr>
      <td><a href="<%=eims%>List.asp?eims=<%=eims%>">【返回列表】</a></td>
      <td align="right"><!-- Search Begin -->
        <input type='submit' value='还原' name='submit'>
		<input type='submit' value='删除' name='submit' onClick="return confirm('确定要删除吗？')">
		<input type="hidden" name="del" value="yes">
        <!-- Search end -->
      </td>
    </tr>
  </table>
</div>
<div class="content" align="center">
<table width="100%" border="0" cellspacing="1" cellpAdding="1">
<%
Sql="Select * From ["&eTable&"] Where ItemRec=0 Order By ItemID desc"
Set Rs=Server.CreateObject("Adodb.RecordSet")
Rs.Open Sql,Conn,1,1
%>
  <tr bgcolor="#FFFFFF" align="center">    
	<td width='60'><div class='title'><%=Rs(0).name%></div></td>
    <td><div class='title'><%=Rs(1).name%></div></td>
    <td><div class='title'><%=Rs(2).name%></div></td>
	<td><div class='title'><%=Rs(3).name%></div></td>
	<td width='35'><div class='title'><input type='checkbox' name='chkall' onClick='CheckAll(this.form)' value='ON'> </div></td>
  </tr>
<%
totalnumber=rs.recordcount'总记录数
if not (rs.eof and rs.bof) then'有记录
rs.PageSize=pagenum
maxpage=rs.pageCount'总页数
page=cint(request("page"))'接收页面传来的参数
if page<1 then page=1
If page>maxpage then page=maxpage
rs.Absolutepage=Page
for i=1 to rs.PageSize
if rs.eof then exit for
%>
  <tr onMouseOver='trOver(this)' onMouseOut='trOut(this)' align="center">
	<td><%=Int(Rs(0))%></td>
    <td><%=Trim(Rs(1))%></td>
	<td><%=Trim(Rs(2))%></td>
	<td><%=Trim(Rs(3))%></td>
	<td><input name='BoxID' type='checkbox' value='<%=Int(Rs(0))%>'></td>
  </tr>
<% 
Rs.MoveNext
next
end if
Rs.Close
Set Rs=nothing
%>
</table>
</form>
<div class="page"><%showpage Page,totalnumber,pagenum,ReUrl() %></div>
</div>
</body></html>
<%Call CloseConn()%>