⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wzgl_01.asp

📁 机票预定系统 各个模块的设计-ticket reservation systems detailed design system modules of the design
💻 ASP
字号:
<!--#include file="function/m_conn.asp"-->
<!--#include file="function.asp"-->
<!--#include file="power.asp"-->

<%login_grade=session("login_grade")
admin_Remark_bak=session("Adm_Remark")
if len(session("login_name"))=0 then
%>
<script language="javascript">
    alert("您没有权限访问,请登陆!")
    top.location="../../System_manage/memlogin.asp"
</script>
<%response.end 
elseif instr(login_grade,"1")=0 and admin_Remark_bak<>"super" then
%>
<script language="javascript">
    alert("您的权限不够,不能访问该页面,请登陆!")
window.history.back(-1);
</script>
<%response.end 
end if


if trim(request("action"))="delete" then
k=request("deleteid")
deleteid=split(request("deleteid"))
for i=0 to ubound(deleteid)
deleteid(i)=replace(deleteid(i),",","")
set rrs=server.CreateObject("adodb.recordset")
rsql="select * from tadmin where adm_id = "&deleteid(i)
rrs.open rsql,conn,3,1
if trim(rrs("adm_remark"))="super" then
'超级管理员不能被删除
else
'删除记录!
sql="delete from tadmin where adm_id ="&deleteid(i)
conn.execute(sql)
end if
next
action=""
msg_ok="群组删除成功!id共"&i&"个,分别是"&k
end if
%>
<!--#include file="../../config.asp"-->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title><%=ZXLCompanyStr%>后台管理会员管理——VIP会员</title>
<link href="RLimages/user.css" rel="stylesheet" type="text/css">
<script language="javascript">

function dele(){
if(!confirm('确实要进行删除操作\n注意:删除以后将不能恢复!\n建议将该帐号设置为“没有激活”,暂停该帐号的使用权!')) 
return false;
myform.submit();
}
function modify(aa){
modify_mem.adm_id.value=aa;
modify_mem.submit();
}
function sltall(){
var nn=self.document.all.item("deleteid");
for(j=0;j<nn.length;j++){
document.all.item("deleteid",j).checked=true;
  }
}
function escall(){
var nn=document.all.item("deleteid");
for(j=0;j<nn.length;j++){
document.all.item("deleteid",j).checked=false;
  }
}
</script>
<style type="text/css">
<!--
.STYLE1 {font-weight: bold}
-->
</style>
</head>
<body>

  <%
  search_word=trim(request("search_word"))
  set rs=server.CreateObject("adodb.recordset")
  if search_word="" then
  sql="select * from tadmin order by adm_id desc"
   else
  sql="select * from tadmin where adm_loginname like '%"&search_word&"%' order by adm_id desc"
  end if
  rs.open sql,conn,3,1
  page_flag="false"
  if rs.recordcount>0 then
  page_flag="true"
  rs.pagesize=20
  ipage=trim(request("page"))
  if not isnumeric(ipage) then ipage=1
  if ipage<1 then ipage=1
  if cint(ipage)>rs.pagecount then ipage=rs.pagecount
  rs.movefirst
  for i=1  to rs.pagesize*(ipage-1)
  rs.movenext
  next
  end if
  %> 
     <table cellpadding="5" cellspacing="0">
	 <form action="wzgl_01.asp" method="post" name="frmsearch" id="frmsearch">
          <tr> 
            <td height="25" bgcolor="#99CCFF"> &nbsp;按用户名查:
                  <input name="search_word" type="text" class="bok" id="search_word" size="15" maxlength="15" >
              <input type="submit" name="Submit" value=" 查 找 ">            </td>
            <td width="27%" align="right" bgcolor="#99CCFF"><a class="b-12" style="cursor:hand" HREF onClick="modify('')">添加管理员</a></td>
          </tr></form>
</table>

        <table cellpadding="3" cellspacing="1">
          <form action="wzgl_01.asp" method="post" name="myform" id="myform">
          <tr align="center"> 
            <td width="6%" height="25" bgcolor="#518BCB" class="white"><strong>操作</strong></td>
            <td width="8%" bgcolor="#518BCB" class="white"><strong>序号</strong></td>
            <td width="18%" bgcolor="#518BCB" class="white"><strong>管理员名称</strong></td>
            <td width="11%" bgcolor="#518BCB" class="white"><strong>进入次数</strong></td>
            <td width="16%" bgcolor="#518BCB" class="white"><strong>上次登陆的IP</strong></td>
            <td width="8%" bgcolor="#518BCB" class="white"><strong>状态</strong></td>
            <td width="14%" bgcolor="#518BCB" class="white"><strong>身份</strong></td>
            <td width="19%" bgcolor="#518BCB" class="white"><strong>查看/授权/操作</strong></td>
          </tr>
          <% 
   if page_flag="false" then
 %>
          <tr align="center"> 
            <td height="25" colspan="8" bgcolor="#FFFFFF"><font color="#FF0000">没有数据</font></td>
          </tr>
          <%else
          for i=1 to rs.pagesize
           if rs.eof then exit for
		   adm_id=rs("adm_id")
		   adm_status=rs("adm_status")
		   if trim(adm_status)="Active" then
		   adm_status="已激活"
		    else
		   adm_status="没激活"
		   end if
		   if trim(rs("Adm_Remark"))="super" then adm_level="超级管理员"
		   if trim(rs("Adm_Remark"))="normal" then adm_level="高级管理员"
		   if trim(rs("Adm_Remark"))="low" then adm_level="普通管理员"
		    %>
          <tr align="center"> 
            <td width="6%" height="25" bgcolor="#FFFFFF"><input type="checkbox" value="<%=adm_id%>" name="deleteid">            </td>
            <td width="8%" bgcolor="#FFFFFF"><%=(ipage-1)*rs.pagesize+i%></td>
            <td width="18%" bgcolor="#FFFFFF"><%=rs("adm_loginname")%></td>
            <td width="11%" bgcolor="#FFFFFF"><%=rs("adm_times")%></td>
            <td width="16%" bgcolor="#FFFFFF"><%=rs("adm_ip")%></td>
            <td width="8%" bgcolor="#FFFFFF"><%=adm_status%></td>
            <td width="14%" bgcolor="#FFFFFF"><%=adm_level%></td>
            <td width="19%" bgcolor="#FFFFFF"><a class="b-12" style="cursor:hand" HREF onClick="modify(<%=adm_id%>)">查看/授权/修改</a></td>
          </tr>
          <%
		  rs.movenext
		  next
  		end if %>
		<%if trim(admin_Remark_bak)="super" then%>
		<tr> 
            <td height="32" colspan="8" bgcolor="#99CCFF">
			<input type="button" onClick="sltall()" value="全选">&nbsp;
			<input type="button" onClick="escall()" value="全不选">&nbsp;
        <input type="button" onClick="return dele()" value=" 删 除 "></td>
          </tr>
		  <%end if%>
        <input type="hidden" name="page" value="<%=ipage%>">
		<input type="hidden" name="search_word" value="<%=search_word%>">
		<input type="hidden" name="action" value="delete">
	</form>
</table>
<table cellpadding="0" cellspacing="0">
  <tr>
     <td ><%=pages()%></td>
  </tr>
</table>
</body>
</html>
<form method="post" name="productsearch" action="wzgl_01.asp">
<input type="hidden" name="page" value="<%=ipage%>">
<input type="hidden" name="search_word" value="<%=search_word%>">
</form>
<form method="post" name="modify_mem" action="modify_adm.asp">
<input type="hidden" name="adm_id" value="">
<input type="hidden" name="page" value="<%=ipage%>">
<input type="hidden" name="search_word" value="<%=search_word%>">
</form>
<%
'rrs.close
set rrs=nothing
rs.close
set rs=nothing
call conn_close()
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -