
<!--#include file="./Conn_Mail.asp"-->
<!--#include file="inc/Check.asp"-->
<!--#include file="inc/public.asp"-->
<%
dim makking,del,GroupID
			makking=request.QueryString("makking")
			GroupID   = TRIM(Request.Form("GroupID")) 
			del       = int(Request.Form("del")) 
	if makking="Make" then
	if GroupID<>"" and del<>0 then
    select case del
	case "" 
		call no()
	case "0" 
		call no()
	case "1"
		conn_m.execute("update Mail set Ending=0,MailPicture='' where GroupID in ("&GroupID&")")
	case "2"
		conn_m.execute("update Mail set Ending=2,MailPicture='' where GroupID in ("&GroupID&")")
	case "3"
		conn_m.execute("update Mail set Ending=1,MailPicture='' where GroupID in ("&GroupID&")")
	case "4"
		conn_m.execute("delete from Mail where Ending=0 and GroupID in ("&GroupID&")")
	case "5"
		conn_m.execute("delete from Mail where Ending=1 and GroupID in ("&GroupID&")")
	case "6"
		conn_m.execute("delete from Mail where Ending=2 and GroupID in ("&GroupID&")")
	case "7"
		conn_m.execute("delete from Mail where GroupID in ("&GroupID&")")
		conn_m.execute("delete from Mail_Group where GroupID in ("&GroupID&")")
    end select
	Save_Title = "·删除成功"
	Call Save_ok
	else
	Save_Title = "·删除失败"
	Call Save_err
	end if
	end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>ELIGHT.CC</title>
</head>
<link href="Images/Admin.css" rel="stylesheet" type="text/css">
<body>
<table width="98%" height="40"  border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td><table width="100%"  border="0" align="center" cellpadding="2" cellspacing="1" bgcolor="#D8D8D8">
        <tr>
          <td height="30" align="left" bgcolor="ffffff"><table width="100%" height="100%"  border="0" cellpadding="3" cellspacing="0">
              <tr bgcolor="eeeeee">
                <td width="5%" align="center"><img src="Images/1.gif" width="13" height="12"></td>
                <td width="78%"><span City="style2">管理中心 &gt;&gt;&gt; 管理邮件列表</span></td>
                <td width="17%" align="right">&nbsp; </td>
              </tr>
          </table></td>
        </tr>
    </table></td>
  </tr>
</table>
<table width="98%" height="90%"  border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#D8D8D8">
  <tr>
    <td valign="top" bgcolor="ffffff"><table width="100%"  border="0" align="center" cellpadding="0" cellspacing="0">
        <tr> 
          <td align="center" bgcolor="ffffff"> <table width=100% border=0 align='center' cellpadding=3 cellspacing=1 bordercolordark=#ffffff bgcolor="eaeaea"><form name="form1" method="post" action="Mail_Manage.asp?Makking=Make">
              <tr align="left" bgcolor="ffffff" background="Images/box_bg.gif"> 
                <td width="4%" height="20" background="Images/box_bg.gif" bgcolor="ffffff">&nbsp;</td>
                <td width="5%" height="20" background="Images/box_bg.gif" bgcolor="ffffff">ID</td>
                <td width="31%" height="20" background="Images/box_bg.gif">组名称</td>
                <td width="21%" height="20" background="Images/box_bg.gif">未发/成功/失败</td>
                <td width="24%" height="20" background="Images/box_bg.gif">创建时间</td>
                <td width="15%" height="20" background="Images/box_bg.gif">操作</td>
              </tr>
              <%
	sql="select * from Mail_Group order by datetime desc" 
	set rs=server.createobject("adodb.recordset") 
	rs.open sql,conn_m,1,1
	if not(rs.bof and rs.eof) then
	'==============================page
	rs.PageSize =10
	%>
              <!--#include file="page.asp"-->
              <tr align="left" bgcolor="ffffff" onmouseout="this.style.backgroundColor=''" onmouseover="this.style.backgroundColor='#F5F5F5'"> 
                <td height="24" bgcolor="ffffff"> <input type="checkbox" name="GroupID" value="<%=rs("GroupID")%>"> 
                </td>
                <td bgcolor="ffffff"><%=rs("GroupID")%></td>
                <td> <A href="SendMail_Lest.asp?ID=<%=Rs("GroupID")%>"><%=left(trim(rs("Groupname")),30)%></a></td>
                <td height="24"> 
                  <%
		'未发送
		Set Rsm = Conn_m.Execute("Select Count(Mail) As MailCount From Mail Where GroupID="& Rs("GroupID") &" and Ending=0")
		Response.Write Rsm("MailCount") & "/"
		Rsm.Close
		Set Rsm = Nothing
		'成功
		Set Rsm = Conn_m.Execute("Select Count(Mail) As MailCount From Mail Where GroupID="& Rs("GroupID") &" and Ending=1")
		Response.Write Rsm("MailCount") & "/"
		Rsm.Close
		Set Rsm = Nothing
		'失败
		Set Rsm = Conn_m.Execute("Select Count(Mail) As MailCount From Mail Where GroupID="& Rs("GroupID") &" and Ending=2")
		Response.Write Rsm("MailCount")
		Rsm.Close
		Set Rsm = Nothing
		%>
                </td>
                <td height="24"><%=rs("Datetime")%></td>
                <td>
				<%if Rs("TaskID") <> 0 Then%>
				<a href="XMLHTTPURL.asp?Makking=MakeTask&ID=<%=Rs("TaskID")%>">续抓</a>|<a href="XMLHTTPURL.asp?Makking=MakeTask&ID=<%=Rs("TaskID")%>&URL_A_A=0">重抓</a>
				<%End IF%>
				</td>
              </tr>
              <%   
			rs.movenext
			next
			end if
           %>
            </table></td>
        </tr>
      </table>
      <table width="100%"  border="0" cellspacing="0" cellpadding="0">
        <tr> 
          <td width="4%" height="24" align="center" valign="middle" background="Images/box_bg_1.gif"> 
            <input type="checkbox" name="checkbox2" value="Check All" onClick="mm()"> 
          </td>
          <td width="12%" height="24" align="left" valign="middle" background="Images/box_bg_1.gif"> 
            <select name="del" class="all_box1">
              <option value="0">选择操作……</option>
              <option value="1">改为未发</option>
              <option value="2">改为失败</option>
              <option value="3">改为成功</option>
              <option value="4">删除未发</option>
              <option value="5">删除失败</option>
              <option value="6">删除成功</option>
              <option value="7">删除全部</option>
            </select> </td>
          <td align="left" valign="middle" background="Images/box_bg_1.gif"> <input name="imageField2" type="image" src="Images/refer.gif" width="36" height="21" border="0"> 
          </td>
		   </form>
          <td width="51%" height="24" align="right" valign="top" background="Images/box_bg_1.gif"> 
            <%Page_links=""
			call PageControl(iCount,maxpage,page)
			rs.close
			set rs=nothing
Conn_m.Close
Set Conn_m = Nothing
			%>
          </td>
        </tr>
      </table>
      <table width="100%"  border="0" cellspacing="0" cellpadding="0">
        <tr> 
          <td height="1" bgcolor="#E2E1E1"></td>
        </tr>
      </table>
      
    </td>
  </tr>
</table>
<table width="98%"  border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="6"></td>
  </tr>
</table>
</body>
</html>