<!-- #include file="conn.asp" -->
<!-- #include file="cls_main.asp" -->
<!-- #include file="cls_ishion_showPage.asp" -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>会员中心</title>
<link href="User_Style.css" rel="stylesheet" type="text/css">
</head>
<body leftmargin="3" topmargin="0">
<table width="800"  border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
  <tr>
    <td colspan="3"><img src="images/user_top.gif" width="800" height="13"></td>
  </tr>
  <tr>
    <td width="10">&nbsp;</td>
    <td width="190"><img src="images/User_Logo.gif" width="150" height="72"></td>
    <td width="600" align="right"><table  border="0" cellpadding="0" cellspacing="1">
        <tr>
          <td>·<a href="default.html">站点首页</a> ·<a href="downnew/0_1.html">最近更新</a> ·<a href="downtop/1_1.html">下载排行</a> </td>
          <td>·<a href="UserLogin.asp?action=logout">退出登录</a></td>
          <td width="10">&nbsp;</td>
        </tr>
      </table>
        <table  border="0" cellpadding="0" cellspacing="0">
          <tr>
            <td height="52" align="center" background="images/user_bg.gif"><img src="images/user_bg1.gif" width="8" height="52" align="absmiddle">&nbsp;<a href="User_Index.asp">会员中心</a> <img src="images/bg_dot1.gif" width="3" height="25" align="absmiddle"> <a href="User_Down_Upload.asp">上传软件</a> <img src="images/bg_dot1.gif" width="3" height="25" align="absmiddle"> <a href="User_Down_Resource.asp">添加软件</a> <img src="images/bg_dot1.gif" width="3" height="25" align="absmiddle"> <a href="User_Down_Reslist.asp">软件管理</a> <img src="images/bg_dot1.gif" width="3" height="25" align="absmiddle"> <a href="User_Cms_Resource.asp">添加文章</a> <img src="images/bg_dot1.gif" width="3" height="25" align="absmiddle"> <a href="User_Cms_Reslist.asp">文章管理</a> <img src="images/bg_dot1.gif" width="3" height="25" align="absmiddle"> <a href="User_Modfiy.asp">资料修改</a> <img src="images/bg_dot1.gif" width="3" height="25" align="absmiddle"> <a href="User_BuyPoints.asp">帐号充值</a> <img src="images/bg_dot1.gif" width="3" height="25" align="absmiddle"> <a href="User_List.asp">会员列表</a>&nbsp;<img src="images/user_bg2.gif" width="10" height="52" align="absmiddle"></td>
          </tr>
      </table></td>
  </tr>
</table>
<table width="800" border="0" align="center" cellpadding="5" cellspacing="0" bgcolor="#FFFFFF">
  <tr>
    <td height="400" valign="top">
<% dim obj
set obj = New User_Down_reslist
	obj.AspInit()
set obj = nothing %>
	</td>
  </tr>
</table>
<table width="800" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td><img src="images/user_ti.gif" width="800"></td>
  </tr>
</table>
</body>
</html>
<% 
Class User_Down_reslist

	Private BatchID, sID, sResName, sToolTip
	Private ishion
	Private Sub Class_Initialize()
		Set ishion = New Cls_Main
		Founderr = False
	End Sub
	Private Sub Class_Terminate()
		Set ishion = Nothing
	End Sub
	Public Sub AspInit()
		Response.Write "<script src=""js/ishion_Tooltip.js""></script>" & vbCrLf
		BatchID = Request.Form("ID")
		If Request.QueryString("ID") <> "" Then
			sID = CLng(Request.QueryString("ID"))
		Else
			sID = ""
		End If
		
			Call ishion.LoadSetting
			If ishion.MemberUserName = "" Then
				ishion.strMsg = "<li>非法操作，您没有登录系统，<a href=""UserLogin.asp"">点击此处进入登录界面</a>。"
				Call ishion.SystemMsg
			Else
				Call Main
			End If
		
	
	End Sub
	Private Sub Main()
		Call sMenu
		Call sForm
		Select Case Trim(Request("action"))
		Case "isBatchDel" '批量删除
			If ishion.checkPermission(ishion.adminName, "12") Then
				Call isBatchDel
			Else
				ishion.strMsg = "<li>非法操作：你没有权限进行此项操作，请联系管理员！"
				Call ishion.SystemMsg
			End If
		Case "isBatchAuditing" '批量审核
			Call isBatchAuditing
		Case "unBatchAuditing" '批量取消审核
			Call unBatchAuditing
		Case "isBatchTop" '批量置顶
			Call isBatchTop
		Case "unBatchTop" '批量取消置顶
			Call unBatchTop
		Case "isBatchHot" '批量推荐
			Call isBatchHot
		Case "unBatchHot" '批量取消推荐
			Call unBatchHot
		Case "isBatchBest" '批量精品
			Call isBatchBest
		Case "unBatchBest" '批量取消精品
			Call unBatchBest
		Case "isBatchMov" '批量移动
			Call isBatchMov
		Case "isDel" '删除
			If ishion.checkPermission(ishion.adminName, "12") Then
				Call isDel
			Else
				ishion.strMsg = "<li>非法操作：你没有权限进行此项操作，请联系管理员！"
				Call ishion.SystemMsg
			End If
		Case "isAuditing" '审核
			Call isAuditing
		Case "unAuditing" '取消审核
			Call unAuditing
		Case "AllAuditing" '全部审核
			Call AllAuditing
		Case "isTop" '置顶
			Call isTop
		Case "unTop" '取消置顶
			Call unTop
		Case "isHot" '批量推荐
			Call isHot
		Case "unHot" '批量取消推荐
			Call unHot
		Case "isBest" '批量精品
			Call isBest
		Case "unBest" '批量取消精品
			Call unBest
		Case Else
			Call Reslist
		End Select
	End Sub
	Private Sub Reslist()
	Dim Rs, showPageRs, sql, Keyword, i, q, sCatalog, sKeyword, sColumn, currentPage
	sColumn = "ID,CatalogID,CatalogName,ResName,ResVer,FontColor,FontType,SmallImg,ResLanguage,ResSize,ResType  ,ResLicence,ResRank,System,DateAndTime,UpdateTime,HitsTotal,HitsMonth,HitsWeek,HitsToday,isHot,isTop,isBest,isError,isAuditing,UserName"
	If Trim(Request.QueryString("Page")) = "" Then
		currentPage = 1
	Else
		currentPage = Trim(Request.QueryString("Page"))
	End If
	Set showPageRs = New cls_ishion_showPage '创建对象
	If IsSqlDataBase = 1 Then
		showPageRs.DbType = "MSSQL"
	Else
		showPageRs.DbType = "AC"
	End If
		'数据库类型,AC为access,MSSQL为sqlserver2000,MSSQL_SP为存储过程版,MYSQL为mysql,PGSQL为PostgreSql
	showPageRs.RecType = 0
		'取记录总数方法(0执行count,1自写sql语句取,2固定值)
	showPageRs.RecSql = 0
		'如果RecType＝1则=取记录sql语句，如果是2=数值，等于0=""
	showPageRs.RecTerm = 1
		'取从记录条件是否有变化(0无变化,1有变化,2不设置cookies也就是及时统计，适用于搜索时候)
	showPageRs.CookieName = "ishion_down_reslist"  '如果RecTerm＝2,cookiesname="",否则写cookiesname
	showPageRs.Order = 1              '排序(0顺序1降序),注意要和下面sql里面主键ID的排序对应
	showPageRs.PageSize = 35          '每页记录条数
	showPageRs.currentPage = currentPage
	
	If Trim(Request("action")) = "s" Then
		Keyword = ishion.checkStr(Request("keyword"))
		Select Case Request("sType")
		Case "ResName"
			sKeyword = " (" & ishion.translate(Keyword, "ResName") & ")"
			q = "&action=s&sType=ResName&catalog=" & Request("catalog") & "&keyword=" & Keyword
		Case "ResVer"
			sKeyword = " (" & ishion.translate(Keyword, "ResVer") & ")"
			q = "&action=s&sType=ResVer&catalog=" & Request("catalog") & "&keyword=" & Keyword
		Case "Excerpt"
			sKeyword = " (" & ishion.translate(Keyword, "Excerpt") & ")"
			q = "&action=s&sType=Excerpt&catalog=" & Request("catalog") & "&keyword=" & Keyword
		Case "Content"
			sKeyword = " (" & ishion.translate(Keyword, "Content") & ")"
			q = "&action=s&sType=Content&catalog=" & Request("catalog") & "&keyword=" & Keyword
		Case "UserName"
			sKeyword = " UserName = '" & Keyword & "'"
			q = "&action=s&sType=UserName&catalog=" & Request("catalog") & "&keyword=" & Keyword
		End Select
		
		If Keyword <> "" Then
			If Request("catalog") <> "" Then
				If Split(Request("catalog"), ",")(2) = 0 Then
					sCatalog = sKeyword & " and RootID = " & Split(Request("catalog"), ",")(0)
				Else
					sCatalog = sKeyword & " and catalogID=" & Split(Request("catalog"), ",")(1) & " and Depth>=" & Split(Request("catalog"), ",")(2) & " and RootID = " & Split(Request("catalog"), ",")(0)
				End If
			Else
				sCatalog = sKeyword & ""
			End If
		Else
			If Request("catalog") <> "" Then
				If Split(Request("catalog"), ",")(2) = 0 Then
					sCatalog = " RootID = " & Split(Request("catalog"), ",")(0)
				Else
					sCatalog = " catalogID=" & Split(Request("catalog"), ",")(1) & " and Depth>=" & Split(Request("catalog"), ",")(2) & " and RootID = " & Split(Request("catalog"), ",")(0)
				End If
			Else
				sCatalog = ""
			End If
			sKeyword = ""
		End If
		'Response.Write(sCatalog)
		showPageRs.sql = sColumn & "$ishion_Down_Resource$" & sCatalog & " and UserName = '" & ishion.MemberUserName & "'$UpdateTime desc$UpdateTime" '字段,表,条件(不需要where),排序(不需要需要ORDER BY),主键ID
	Else
		showPageRs.sql = sColumn & "$ishion_Down_Resource$UserName = '" & ishion.MemberUserName & "'$UpdateTime desc$UpdateTime" '字段,表,条件(不需要where),排序(不需要需要ORDER BY),主键ID
	End If
	Dim iRecCount, sqlRs
	iRecCount = showPageRs.RecCount() '记录总数
	
	Response.Write "<script language=""JavaScript"">" & vbCrLf
	Response.Write "function doSort() {" & vbCrLf
	Response.Write "    var oE = window.event.srcElement;" & vbCrLf
	Response.Write "    for (var i=0;i<oE.rows[oE.headindex].cells.length;i++) {" & vbCrLf
	Response.Write "        oE.rows[oE.headindex].cells[i].children[1].innerText = """";" & vbCrLf
	Response.Write "    }" & vbCrLf
	Response.Write "    oE.rows[oE.headindex].cells[window.event.sortIndex].children[1].innerText = window.event.sortOrder ? ""↑"" : ""↓"";" & vbCrLf
	Response.Write "}" & vbCrLf
	Response.Write "function sort() {" & vbCrLf
	Response.Write "    document.getElementById(""databox"").sort(2,false,""float"");" & vbCrLf
	Response.Write "}" & vbCrLf
	Response.Write "</script>" & vbCrLf
	
	Response.Write (showPageRs.showPage("?Page={$pages}" & q))
	
	Response.Write "<table width=""100%"" border=""0"" cellpadding=""0"" cellspacing=""0"">" & vbCrLf
	Response.Write "<form name=""myform"" method=""post"" action="""">" & vbCrLf
	Response.Write "  <tr>" & vbCrLf
	Response.Write "    <td><table width=""100%"" border=""0"" align=""center"" cellpadding=""3"" cellspacing=""1"" headindex=""0"" begin=""1"" end=""0"" onsort=""doSort()"" id=""databox"" style=""behavior:url(js/sortrow1.11.htc)""> " & vbCrLf
	Response.Write "        <COLGROUP>" & vbCrLf
	Response.Write "              <COL width=26>" & vbCrLf
	Response.Write "              <COL width=*>" & vbCrLf
	Response.Write "              <COL width=65>" & vbCrLf
	Response.Write "              <COL width=40>" & vbCrLf
	Response.Write "              <COL width=85>" & vbCrLf
	Response.Write "              <COL width=40>" & vbCrLf
	Response.Write "              <COL width=120>" & vbCrLf
	Response.Write "        <tr>" & vbCrLf
	Response.Write "          <td align=""center"" data-type=""none"" background=""images/menubg.gif""><span><a href=""javascript:SelectAll()"">选择</a></span><span></span></td>" & vbCrLf
	Response.Write "          <td background=""images/menubg.gif"">　<span>资源分类和资源名称</span><span></span></td>" & vbCrLf
	Response.Write "          <td align=""center"" background=""images/menubg.gif""><span>日期</span><span></span></td>" & vbCrLf
	Response.Write "          <td align=""center"" background=""images/menubg.gif""><span>用户</span><span></span></td>" & vbCrLf
	Response.Write "          <td align=""center"" data-type=""none"" background=""images/menubg.gif""><span>资源属性</span><span></span></td>" & vbCrLf
	Response.Write "          <td align=""center"" background=""images/menubg.gif""><span>审核</span><span></span></td>" & vbCrLf
	Response.Write "          <td align=""center"" data-type=""none"" background=""images/menubg.gif""><span>常规操作</span><span></span></td>          " & vbCrLf
	Response.Write "        </tr>" & vbCrLf
	Response.Write "<SCRIPT language = ""JavaScript"">" & vbCrLf
	Response.Write "//parent.frame.cols=""0,*"";" & vbCrLf
	Response.Write "function SelectAll() {" & vbCrLf
	Response.Write "    for (var i=0;i<document.myform.ID.length;i++) {" & vbCrLf
	Response.Write "        var e=document.myform.ID[i];" & vbCrLf
	Response.Write "        e.checked=!e.checked;" & vbCrLf
	Response.Write "    }" & vbCrLf
	Response.Write "}" & vbCrLf
	Response.Write "<!--" & vbCrLf
	Response.Write "function CheckAll(form)  {" & vbCrLf
	Response.Write "  for (var i=0;i<form.elements.length;i++)    {" & vbCrLf
	Response.Write "    var e = form.elements[i];" & vbCrLf
	Response.Write "    if (e.name != 'chkall')       e.checked = form.chkall.checked; " & vbCrLf
	Response.Write "   }" & vbCrLf
	Response.Write "  }" & vbCrLf
	Response.Write "//-->" & vbCrLf
	Response.Write "</script>" & vbCrLf
	
	If iRecCount < 1 Then
		Response.Write "<tr bgcolor=""#FCFCFC""> <td colspan=""7"">Sorry！没有找到任何记录。</td></tr>"
	Else
		Set sqlRs = showPageRs.ResultSet()  '返回ResultSet
		Rs = sqlRs.GetRows(-1)
		For i = 0 To UBound(Rs, 2)
			'设置文字颜色和字型
			If Rs(5, i) = "" Or IsNull(Rs(5, i)) Then
				sResName = ishion.cutStr(Rs(3, i) & " " & Rs(4, i), 50)
			Else
				sResName = "<font color=""" & Rs(5, i) & """>" & ishion.cutStr(Rs(3, i) & " " & Rs(4, i), 50) & "</font>"
			End If
			If Rs(6, i) = 1 Then
				sResName = "<strong>" & sResName & "</strong>"
			ElseIf Rs(6, i) = 2 Then
				sResName = "<em>" & sResName & "</em>"
			ElseIf Rs(6, i) = 3 Then
				sResName = "<strong><em>" & sResName & "</em></strong>"
			End If
			
			sToolTip = "<table width=330 border=0 cellspacing=1 cellpadding=0>" & _
			"<tr><td>语种：" & Rs(8, i) & "</td><td>大小：" & Rs(9, i) & " KB</td></tr>" & _
			"<tr><td>类型：" & Rs(10, i) & "</td><td>级别：" & Rs(12, i) & "星</td></tr>" & _
			"<tr><td>授权：" & Rs(11, i) & "</td><td>上传：" & Rs(14, i) & "</td></tr>" & _
			"<tr><td colspan=2>系统：" & Rs(13, i) & "</td></tr>" & _
			"<tr><td colspan=2>下载：总" & Rs(16, i) & " 月" & Rs(17, i) & " 周" & Rs(18, i) & " 日" & Rs(19, i) & "</td></tr></table>"
				
				Response.Write " <tr "
				If i Mod 2 Then
					Response.Write (" class=""tdbg2""")
				Else
					Response.Write (" class=""tdbg3""")
				End If
				Response.Write " onmouseover=""this.style.backgroundColor='#CEE7FF';this.style.color='red'"" onmouseout=""this.style.backgroundColor='';this.style.color=''""> "
				Response.Write " <td align=""center"">"
				If checkResAdmin(Rs(25, i)) = True Then
					Response.Write "<input name=""ID"" type=""checkbox"" value=""" & Rs(0, i) & """>"
				 Else
					Response.Write "--"
				End If
				Response.Write "</td>"
				Response.Write " <td>"
				Response.Write "[<a href=""?catalogID=" & Rs(1, i) & """>" & Rs(2, i) & "</a>]"
				Response.Write " <a href=""ViewDownInfo.asp?ID=" & Rs(0, i) & """ target=""_blank"" onmouseover=""showToolTip('" & sToolTip & "',event.srcElement)"" onmouseout=""hiddenToolTip()"">" & sResName & "</a>"
				Response.Write " </td>"
				Response.Write " <td align=""center"">"
				Response.Write ishion.FormatMyDate(Rs(15, i), "{Y}/{m}/{d}")
				Response.Write "</td>"
				Response.Write " <td align=""center"">"
				Response.Write Rs(25, i)
				Response.Write "</td>"
				Response.Write " <td align=""center"">"
				If Rs(21, i) = 1 Then
				Response.Write "<font color=blue>顶 </font>"
				Else
				Response.Write "&nbsp;&nbsp;&nbsp;"
				End If
			   If Rs(20, i) = 1 Then
			   Response.Write "<font color=green>荐 </font>"
			   Else
			   Response.Write "&nbsp;&nbsp;&nbsp;"
			   End If
			   If Rs(22, i) = 1 Then
				Response.Write "<font color=red>热 </font>"
			   Else
			   Response.Write "&nbsp;&nbsp;&nbsp;"
			   End If
			   If Rs(7, i) <> "" Then
			   Response.Write "<font color=blue>图 </font>"
			   Else
			   Response.Write "&nbsp;&nbsp;&nbsp;"
			   End If
			   If Rs(23, i) = 1 Then
			   Response.Write "<font color=red>错</font>"
			   Else
			   Response.Write "&nbsp;&nbsp;"
			   End If
			   Response.Write "</td>"
				Response.Write " <td align=""center"">"
				If Rs(24, i) = 1 Then
					Response.Write ("<a href=""?action=unAuditing&ID=" & Rs(0, i) & """><font color=red>√</font></a>")
				 Else
					Response.Write ("<a href=""?action=isAuditing&ID=" & Rs(0, i) & """>待审</a>")
				End If
				Response.Write "</td>"
				Response.Write " <td align=""center"">"
					Response.Write "<a href=""User_Down_Resource.asp?action=edit&ID=" & Rs(0, i) & """ title=""修改下载资源信息"">修改</a> "
					Response.Write "<a href=""User_Down_Resource.asp?action=isDel&ID=" & Rs(0, i) & """ onclick=""{if(confirm('执行此删除操作后该资源不能恢复，确定删除吗？')){return true;}return false;}"">删除</a> "
				Response.Write "</td>"
				Response.Write " </tr>"
			Next
			Rs = Null
			Set sqlRs = Nothing
		End If
		
		Response.Write "</table>" & vbCrLf
		Response.Write "    <table width=""100%"" border=""0"" align=""center"" cellpadding=""3"" cellspacing=""1"">" & vbCrLf
		Response.Write "        <tr class=""tdbg3""> " & vbCrLf
		Response.Write "            <td><input type=checkbox name=chkall value=on onclick=""CheckAll(this.form)"" id=""chkall""><label for=""chkall"">全选</label><br>管理</td>" & vbCrLf
		Response.Write "            <td colspan=""6""><input type=""radio"" name=""action"" value=""isBatchDel"">批量<font color=red>删除</font>" & vbCrLf
		Response.Write "            <input type=""radio"" name=""action"" value=""isBatchMov"">批量移动:"
		Response.Write "<select name=""catalog"">" & vbCrLf
		
		If Request("catalog") <> "" Then
			Response.Write ishion.GetCatalogSelect(Split(Request("catalog"), ",")(1), "ishion_Down_Catalog")
		Else
			Response.Write ishion.GetCatalogSelect(0, "ishion_Down_Catalog")
		End If
		Response.Write "</select>"
		Response.Write "     <input type=""submit"" name=""Submit3"" value=""执行操作"" onclick=""{if(confirm('您确定执行的操作吗?')){this.document.myform.submit();return true;}return false;}""> </td>" & vbCrLf
		Response.Write "        </tr>" & vbCrLf
		Response.Write "        <tr class=""tdbg2"">" & vbCrLf
		Response.Write "        <td colspan=""7"">资源属性中的各项含义：<font color=blue>顶</font>——固顶下载，<font color=green>荐</font>——推荐下载，<font color=red>热</font>——热门下载，<font color=blue>图</font>——有下载图片，<font color=red>错</font>——下载地址中有错误链接</td>" & vbCrLf
		Response.Write "        </tr>" & vbCrLf
		Response.Write "        " & vbCrLf
		Response.Write "</table></td>" & vbCrLf
		Response.Write "  </tr>" & vbCrLf
		Response.Write "</form>" & vbCrLf
		Response.Write "</table> " & vbCrLf
		
		Response.Write (showPageRs.showPage("?Page={$pages}" & q))
	
		Set showPageRs = Nothing
		
	End Sub
	Private Sub sForm()
		Response.Write "<table width=""100%"" border=""0"" cellpadding=""3"" cellspacing=""0"">"
		Response.Write "<form action=""User_Down_reslist.asp"" method=""post"" name=""sForm""> "
		Response.Write " <tr>"
		Response.Write " <td height=""3""></td>"
		Response.Write " </tr>"
		Response.Write " <tr class=""tdbg2"">"
		Response.Write " <td><input name=""action"" type=""hidden"" id=""action"" value=""s"">"
		Response.Write " 软件搜索："
		Response.Write " <select name=""sType"">"
		Response.Write " <option value=""ResName"" "
		If Request("sType") = "ResName" Then Response.Write ("selected")
		Response.Write ">资源名称</option>"
		Response.Write " <option value=""ResVer"" "
		If Request("sType") = "ResVer" Then Response.Write ("selected")
		Response.Write ">资源版本</option>"
		Response.Write " <option value=""Content"" "
		If Request("sType") = "Content" Then Response.Write ("selected")
		Response.Write ">资源简介</option>"
		Response.Write " <option value=""UserName"" "
		If Request("sType") = "UserName" Then Response.Write ("selected")
		Response.Write ">添加用户</option>"
		Response.Write " </select>:<select name=""catalog"" id=""catalog"">"
		If Request("catalog") <> "" Then
			Response.Write ishion.GetCatalogSelect(CLng(Split(Request("catalog"), ",")(1)), "ishion_Down_Catalog")
		 Else
			Response.Write ishion.GetCatalogSelect(0, "ishion_Down_Catalog")
		End If
		Response.Write " </select>:<input name=""keyword"" type=""text"" value="""
		Response.Write ishion.checkStr(Request("keyword"))
		Response.Write """ size=""25"" maxlength=""100"">"
		Response.Write "<input type=""submit"" name=""Submit"" value=""搜索""></td>"
		Response.Write " </tr></form>"
		Response.Write "</table>"
	End Sub
	Private Sub sMenu()
		Dim tRs
		Response.Write "<table width=""100%"" border=""0"" cellpadding=""3"" cellspacing=""0"" bordercolor=""#FFFFFF"">"
		Response.Write " <tr>"
		Response.Write " <td background=""images/menubg.gif""> 分类： "
		Response.Write " "
		Set tRs = ishion.Execute("select RootID,CatalogID,Depth,CatalogName from ishion_Down_Catalog where depth=0 order by rootid,orders")
		Do While Not tRs.EOF
			Response.Write ("·<a href=""?action=s&sType=ResName&catalog=" & tRs(0) & "," & tRs(1) & "," & tRs(2) & "," & tRs(3) & """>" & tRs(3) & "</a>")
			tRs.MoveNext
		Loop
		Set tRs = Nothing
		Response.Write " </td>"
		Response.Write " </tr>"
		Response.Write "</table>"
	End Sub
	
	Private Sub isBatchDel()
		If BatchID <> "" Then
			ishion.Execute ("delete from ishion_Down_Resource where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.Execute ("delete from ishion_Down_Address where ResourceID in (" & BatchID & ")")
			ishion.Execute ("delete from ishion_Down_Comment where ResourceID in (" & BatchID & ")")
			ishion.strMsg = "<li>“批量删除”操作成功！</li>"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub isBatchTop()
		If BatchID <> "" Then
			ishion.Execute ("update ishion_Down_Resource set isTop=1 where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.strMsg = "<li>“批量固顶”操作成功！"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub unBatchTop()
		If BatchID <> "" Then
			ishion.Execute ("update ishion_Down_Resource set isTop=0 where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.strMsg = "<li>“批量取消固顶”操作成功！"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub isBatchHot()
		If BatchID <> "" Then
			ishion.Execute ("update ishion_Down_Resource set isHot=1 where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.strMsg = "<li>“批量推荐”操作成功！"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub unBatchHot()
		If BatchID <> "" Then
			ishion.Execute ("update ishion_Down_Resource set isHot=0 where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.strMsg = "<li>“批量取消推荐”操作成功！"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub isBatchBest()
		If BatchID <> "" Then
			ishion.Execute ("update ishion_Down_Resource set isBest=1 where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.strMsg = "<li>“批量热门”操作成功！</li>"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub unBatchBest()
		If BatchID <> "" Then
			ishion.Execute ("update ishion_Down_Resource set isBest=0 where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.strMsg = "<li>“批量取消热门”操作成功！</li>"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub isBatchAuditing()
		If BatchID <> "" Then
			ishion.Execute ("update ishion_Down_Resource set isAuditing=1 where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.strMsg = "<li>“批量审核”操作成功！</li>"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub unBatchAuditing()
		If BatchID <> "" Then
			ishion.Execute ("update ishion_Down_Resource set isAuditing=0 where ID in (" & BatchID & ") and UserName='" & ishion.MemberUserName & "'")
			ishion.strMsg = "<li>“批量取消审核”操作成功！</li>"
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub AllAuditing()
		ishion.Execute ("update ishion_Down_Resource set isAuditing=1")
		ishion.strMsg = "<li>“全部审核”操作成功！</li>"
		Call ishion.SystemMsg
	End Sub
	Sub isBatchMov()
		If BatchID <> "" Then
			If Trim(Request.Form("catalog")) <> "" Then
				Dim splCatalog
				splCatalog = Split(Trim(Request.Form("catalog")), ",")
				'0=RootID;1=CatalogID;2=Depth;3=CatalogName
				If splCatalog(2) > 0 Then
					Conn.Execute ("update ishion_Down_Resource set RootID=" & splCatalog(0) & ",CatalogID=" & splCatalog(1) & ",Depth=" & splCatalog(2) & ",CatalogName='" & splCatalog(3) & "' where ID in (" & ID & ") and UserName='" & ishion.MemberUserName & "'")
					ishion.strMsg = "<li>“批量移动”操作成功！</li>"
				Else
					ishion.strMsg = "<li>不能转移到一级分类下，本次操作被取消！</li>"
				End If
			Else
				ishion.strMsg = "<li>没有选择资源分类，本次操作被取消。</li>"
			End If
		Else
			ishion.strMsg = "<li>没有选择任何软件，本次操作被取消！</li>"
		End If
		Call ishion.SystemMsg
	End Sub
	Sub isDel() '单个删除
		If sID <> "" Then
			ishion.Execute ("delete from ishion_Down_Resource where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
			ishion.Execute ("delete from ishion_Down_Address where ResourceID=" & sID & "")
			ishion.Execute ("delete from ishion_Down_Comment where ResourceID=" & sID & "")
			'ishion.strMsg = "<li>“批量删除”操作成功！</li>"
		End If
		Response.Redirect ishion.RefererPage
	End Sub
	Sub isAuditing() '单个审核
		If sID <> "" Then ishion.Execute ("update ishion_Down_Resource set isAuditing=1 where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
		Response.Redirect ishion.RefererPage
	End Sub
	Sub unAuditing() '取消审核
		If sID <> "" Then ishion.Execute ("update ishion_Down_Resource set isAuditing=0 where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
		Response.Redirect ishion.RefererPage
	End Sub
	Sub isTop() '置顶
		If sID <> "" Then ishion.Execute ("update ishion_Down_Resource set isTop=1 where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
		Response.Redirect ishion.RefererPage
	End Sub
	Sub unTop() '取消置顶
		If sID <> "" Then ishion.Execute ("update ishion_Down_Resource set isTop=0 where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
		Response.Redirect ishion.RefererPage
	End Sub
	Sub isHot() '批量推荐
		If sID <> "" Then ishion.Execute ("update ishion_Down_Resource set isHot=1 where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
		Response.Redirect ishion.RefererPage
	End Sub
	Sub unHot() '批量取消推荐
		If sID <> "" Then ishion.Execute ("update ishion_Down_Resource set isHot=0 where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
		Response.Redirect ishion.RefererPage
	End Sub
	Sub isBest() '批量精品
		If sID <> "" Then ishion.Execute ("update ishion_Down_Resource set isBest=1 where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
		Response.Redirect ishion.RefererPage
	End Sub
	Sub unBest() '批量取消精品
		If sID <> "" Then ishion.Execute ("update ishion_Down_Resource set isBest=0 where ID=" & sID & " and UserName='" & ishion.MemberUserName & "'")
		Response.Redirect ishion.RefererPage
	End Sub
	Function checkResAdmin(sName)
		checkResAdmin = True
	End Function
	
	Public Sub OnEndPage()
		'Response.Write ishion.CopyRight
	End Sub ' OnEndPage

End Class %>

