📄 deptopen.asp
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file=DataBase/conn.asp-->
<!--#include file=yan.asp-->
<!--#include file=purview.asp-->
<%
call bumenshezhi
if request("id")<>"" then
'部门名称
set rs=server.CreateObject("adodb.recordset")
sql="select * from tb_Dept where id="&request("id")
rs.open sql,conn,1,1
'上级部门
if rs("shangji")<>"" then
set rss=server.CreateObject("adodb.recordset")
sqls="select * from tb_Dept where id="&rs("shangji")
rss.open sqls,conn,1,1
end if
'下级部门
set rsd=server.CreateObject("adodb.recordset")
sqld="select * from tb_Dept where shangji="&request("id")
rsd.open sqld,conn,1,1
'职位名称
set rsz=server.CreateObject("adodb.recordset")
sqlz="select * from tb_ZhiWei where suoshu="&rs("id")
rsz.open sqlz,conn,1,1
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
<style type="text/css">
<!--
body,td,th {
font-size: 12px;
}
a:link {
color: #0000FF;
}
a:visited {
color: #0000FF;
}
a:hover {
color: #0000FF;
}
.style1 {color: #FF0000}
-->
</style></head>
<body>
<table width="100%" border="0" cellspacing="1">
<tr>
<td><div align="center"><a href="deptadd.asp">添加部门</a> <a href="javascript:" onClick="window.open('deptedit.asp?id=<%=request("id")%>','','width=450,height=220')">修改部门</a><%if request("id")<>1 then%> <a href="deptdel.asp?del=<%=request("id")%>" onClick="return confirm('你真的要删除吗?')">删除部门</a><%else%> 删除部门<%end if%></div></td>
</tr>
</table>
<table width="243" border="0" align="center" cellspacing="1">
<tr>
<td width="323" valign="top"><table width="238" border="0" cellspacing="1" bgcolor="#CCCCCC" >
<tr>
<td width="29%" height="27" bgcolor="#FFFFFF"><div align="center">部门名称:</div></td>
<td width="71%" bgcolor="#FFFFFF">
<%=rs("title")%></td>
</tr>
<tr>
<td height="27" bgcolor="#FFFFFF"><div align="center">上级部门:</div></td>
<td bgcolor="#FFFFFF">
<% if rs("shangji")<>"" then %><a href=deptopen.asp?id=<%=rss("id")%>><%=rss("title")%></a><% End If %></td>
</tr>
<tr>
<td bgcolor="#FFFFFF" height="24"><div align="center">下级部门:</div></td>
<td bgcolor="#FFFFFF">
<%
do while not rsd.EOF
%>
<a href=deptopen.asp?id=<%=rsd("id")%>><%=rsd("title")%></a>
<%
rsd.movenext
loop
%>
</td>
</tr>
<tr>
<td bgcolor="#FFFFFF" height="24"><div align="center">部门描述:</div></td>
<td bgcolor="#FFFFFF" >
<%=rs("content")%></td>
</tr>
<tr>
<td bgcolor="#FFFFFF" height="24"><div align="center">职位:</div></td>
<td bgcolor="#FFFFFF">
<%
do while not rsz.eof
%>
<a href="javascript:" onClick="window.open('zhiweiopen.asp?id=<%=rsz("id")%>','','width=350,height=150')"><%=rsz("zhiwei")%></a>
<%
rsz.movenext
loop
%></td>
</tr>
</table></td>
</tr>
</table>
<p align="center" class="style1">注意:删除一个部门,其下面的所有部门都将被删除,请慎重操作!</p>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -