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

📄 huanshu1.asp

📁 课设做的图书管理系统,主要功能是管理图书的租借情况.里面有功能说明.
💻 ASP
字号:
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>图书借阅</title>
</head>
<!--#include file="conn.asp"-->
<!--#include file="checkuser.asp" -->
<style>
BODY{
	font-family:verdana,arial,helvetica;
	margin:0;
}
td {
	font-family:Tahoma,Verdana, Arial;
	font-size:11px;
	border: 1px solid #CCCCCC;
}
A:link, A:active,A:visited
{
	color: #CCCCCC;
	text-decoration: none;
	padding-left:6px;
	padding-right:6px;
}
A:hover
{
	color: #FF3300;
	text-decoration: none;
	padding-left:6px;
	padding-right:6px;
}
.STYLE1 {color: #FFFFFF}
</style><title>图书归还</title>
<%
'图书归还处理
if trim(request.querystring("action"))="huanshu" then
logid=request.form("logid")
tiaoxingma=request.form("tiaoxingma")
Set rs=conn.execute("update booklog set leixing=false where id="&logid&" and caozuoren='"&session("username")&"' and leixing=true")
set rs=conn.execute("update ebook set yijie=yijie-1 where tiaoxingma='"&tiaoxingma&"'")
response.Write "<script>"
response.Write "alert('还书成功!');"
response.write "window.location.href='huanshu.asp';"
response.write "</script>"
response.end
end if


tiaoxingma=request.form("tiaoxingma")
set rs=server.CreateObject("adodb.recordset")
sql="select * from [ebook] where tiaoxingma='"&tiaoxingma&"'"
rs.open sql,conn,1,1
if rs.eof then
response.Write "<script>"
response.Write "alert('该书暂未加入系统,操作失败!');"
response.write "window.location.href='huanshu.asp';"
response.write "</script>"
rs.close
set rs=nothing
response.end

else
if rs("yijie")=0 then
response.Write "<script>"
response.Write "alert('该书没有借出!');"
response.write "window.location.href='huanshu.asp';"
response.write "</script>"
rs.close
set rs=nothing
response.end
end if
bookid=rs("id")
logid=rs("logid")
shuming=rs("shuming")
rs.close
set rs=nothing
end if

'获取借阅信息
Set rs=conn.execute("select * from booklog where caozuoren='"&session("username")&"' and leixing=true")
if rs.eof then
response.Write "<script>"
response.Write "alert('没有该书的借出信息!');"
response.write "window.location.href='huanshu.asp';"
response.write "</script>"
response.end
end if
logid=rs("id")
%>
 <form id="form1" name="form1" method="post" action="?action=huanshu">
  <p>&nbsp;</p>
  <p>&nbsp;</p>
  <table width="307" border="0" align="center" cellpadding="0" cellspacing="0">
    <tr>
      <td height="24" colspan="2" align="center" bgcolor="#003366"><span class="STYLE1">借阅信息</span></td>
    </tr>
    <tr>
      <td height="26" align="center">书名:</td>
      <td><a href="bookinfo.asp?bookid=<%=bookid%>" target="_blank"><font color=red><%=shuming%></font></a>
        <input name="logid" type="hidden" id="logid" value="<%=logid%>" />
		<input name="tiaoxingma" type="hidden" id="tiaoxingma" value="<%=tiaoxingma%>" />
      </td>
    </tr>
    <tr>
      <td align="center">姓名:</td>
      <td><input name="xingming" type="text" id="xingming" value="<%=rs("xingming")%>" /></td>
    </tr>
    <tr>
      <td align="center">备注:</td>
      <td><textarea name="beizhu" rows="3" id="beizhu"><%=rs("beizhu")%></textarea> 
        * 班级等信息 </td>
    </tr>
	 <tr>
      <td colspan="2" align="center"><input type="submit" name="Submit" value="确认" />
        <input name="fanhui" type="button" id="fanhui" value="返回" onClick="window.location.href='huanshu.asp';" /></td>
    </tr>
  </table>
  
</form>



⌨️ 快捷键说明

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