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

📄 approve.asp

📁 1 除掉了 时间 限制 2 除掉了 人数 限制 改为 500人 原为5人 3 发现一点小缺陷 增加人员的时候没有判断 登陆名是否重复! 自己写吧~~~:) 4 又 是一点缺陷
💻 ASP
字号:
<!--#include file="../config.ini" -->
<!--#include file="../commfunction.inc" -->
<%
if request("poid")<>"" then
dim conn
dim rs 
set conn=server.CreateObject("adodb.connection")
conn.Open connstring
sql="select owner from po where poid="&Request("poid")
set rs=conn.Execute(sql)
if not rs.eof then
	strowner=rs("owner")
else
	Response.Write "找不到记录"
	Response.End
end if
sql="select * from poapprove where userid='"&strowner&"' and approver='"&session("loginid")&"'"
set rs=conn.Execute(sql)
if rs.eof then 
	sql="update po set status='已审核',approvedate='"&date()&"',approver='"&session("loginid")&"' where poid="&Request("poid")
	conn.Execute(sql)
else
	if rs("approver")=session("loginid") then
		sql="update po set status='已审核',approvedate='"&date()&"',approver='"&session("loginid")&"' where poid="&Request("poid")
		conn.Execute(sql)
	else
	%>
	<script language=javascript>
		alert("无权限");
		//window.close();
	</script>
	<%	
	end if
end if
%>
<script language=javascript>
	window.opener.location.reload();
	window.close();
</script>
<%
end if
%>

⌨️ 快捷键说明

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