bookBorrow.jsp~1~
上传用户:toby828
上传日期:2015-06-26
资源大小:8558k
文件大小:8k
源码类别:

Jsp/Servlet

开发平台:

Java

  1. <%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" errorPage="" %>
  2. <%@ page import="com.dao.BorrowDAO" %>
  3. <%@ page import="com.actionForm.BorrowForm" %>
  4. <%@ page import="com.actionForm.ReaderForm" %>
  5. <%@ page import="java.util.*"%>
  6. <html>
  7. <%
  8. ReaderForm readerForm=(ReaderForm)request.getAttribute("readerinfo");
  9. BorrowForm borrowForm=(BorrowForm)request.getAttribute("borrowinfo");
  10. %>
  11. <head>
  12. <title>图书馆管理系统</title>
  13. <link href="CSS/style.css" rel="stylesheet">
  14. </head>
  15. <body onLoad="clockon(bgclock)">
  16. <table width="778" border="0" align="center" cellpadding="0" cellspacing="0" class="tableBorder">
  17.   <tr>
  18.     <td height="183">
  19. <%@include file="navigation.jsp"%>
  20. </td>
  21. </tr>
  22. <td>
  23. <table width="100%"  border="0" cellspacing="0" cellpadding="0">
  24.   <tr>
  25.     <td valign="top" bgcolor="#FFFFFF"><table width="99%" height="966"  border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" class="tableBorder_gray">
  26.   <tr>
  27.     <td height="966" align="center" valign="top" style="padding:5px;"><table width="98%" height="487"  border="0" cellpadding="0" cellspacing="0">
  28.       <tr>
  29.         <td height="22" valign="top" class="word_orange">当前位置:图书借还 &gt; 图书借阅 &gt;&gt;&gt;</td>
  30.       </tr>
  31.       <tr>
  32.         <td align="center" valign="top">
  33. <script language="javascript">
  34. function checkreader(form){
  35. if(form.barcode.value==""){
  36. alert("请输入读者条形码!");form.barcode.focus();return;
  37. }
  38. form.submit();
  39. }
  40. function checkbook(form){
  41. if(form.inputkey.value==""){
  42. alert("请输入查询关键字!");form.inputkey.focus();return;
  43. }
  44. form.submit();
  45. }
  46. </script>
  47. <form name="form1" method="post" action="borrow.do?action=bookborrow">
  48. <table width="100%" border="0" cellpadding="0" cellspacing="0" class="tableBorder_gray">
  49.    <tr>
  50.      <td valign="top"><table width="100%" border="0" cellpadding="02" cellspacing="2" bordercolor="#E3F4F7">
  51.        <tr>
  52.          <td height="27" bgcolor="#E3F4F7">&nbsp;<img src="Images/bookBorrow.jpg" width="73" height="23"></td>
  53.        </tr>
  54.        <tr>
  55.          <td valign="top" bgcolor="#E3F4F7">
  56. <%
  57. int ID=0;
  58. String name="";
  59. String sex="";  
  60. String barcode="";
  61. String birthday="";
  62. String paperType="";
  63. String paperNO="";
  64. int number=0;
  65. String typename="";
  66. if(readerForm!=null){
  67. ID=readerForm.getId().intValue();
  68. name=chStr.toChinese(readerForm.getName());
  69. sex=chStr.toChinese(readerForm.getSex());  
  70. barcode=readerForm.getBarcode();
  71. birthday=readerForm.getBirthday();
  72. paperType=chStr.toChinese(readerForm.getPaperType());
  73. paperNO=readerForm.getPaperNO();
  74. number=readerForm.getNumber();
  75. typename=chStr.toChinese(readerForm.getTypename());
  76. }
  77. %>
  78.  <table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
  79.            <tr>
  80.              <td width="33%"><table width="100%" height="74" border="0" cellpadding="0" cellspacing="0">
  81.                <tr>
  82.                  <td height="27" colspan="2" align="center"><table width="90%" height="21" border="0" cellpadding="0" cellspacing="0">
  83.                    <tr>
  84.                      <td background="Images/reader_checkbg.jpg">&nbsp;读者验证</td>
  85.                    </tr>
  86.                  </table></td>
  87.                </tr>
  88.                <tr>
  89.                  <td width="8%" height="27">&nbsp;</td>
  90.                  <td width="92%">读者条形码:</td>
  91.                </tr>
  92.                <tr>
  93.                  <td height="27" colspan="2" align="center"><input name="barcode" type="text" id="barcode" value="<%=barcode%>" size="24">
  94.                    &nbsp;
  95.                    <input name="Button" type="button" class="btn_grey" value="确定" onClick="checkreader(form1)"></td>
  96.                </tr>
  97.              </table></td>
  98.              <td width="1%" align="center" valign="bottom"><img src="Images/borrow_fg.gif" width="18" height="111"></td>
  99.              <td width="66%" align="right">
  100.  <table width="96%" border="0" cellpadding="0" cellspacing="0">
  101.                <tr>
  102.                  <td height="27">姓&nbsp;&nbsp;&nbsp;&nbsp;名:
  103.                        <input name="readername" type="text" id="readername" value="<%=name%>"></td>
  104.                  <td>性&nbsp;&nbsp;&nbsp;&nbsp;别:
  105.                    <input name="sex" type="text" id="sex" value="<%=sex%>"></td>
  106.                </tr>
  107.                <tr>
  108.                  <td height="27">证件类型:
  109.                    <input name="paperType" type="text" id="paperType" value="<%=paperType%>"></td>
  110.                  <td>证件号码:
  111.                    <input name="paperNo" type="text" id="paperNo" value="<%=paperNO%>"></td>
  112.                </tr>
  113.                <tr>
  114.                  <td height="27">读者类型:
  115.                    <input name="readerType" type="text" id="readerType" value="<%=typename%>"></td>
  116.                  <td>可借数量:
  117.                    <input name="number" type="text" id="number" value="<%=number%>" size="20">
  118.                    册</td>
  119.                </tr>
  120.              </table>  </td>
  121.            </tr>
  122.          </table>
  123.  </td>
  124.        </tr>
  125.        <tr>
  126.          <td valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
  127.            <tr>
  128.              <td height="55" valign="top" bgcolor="#E3F4F7"><table width="100%" height="88" border="0" cellpadding="0" cellspacing="0">
  129.                <tr>
  130.                  <td height="38">&nbsp;添加的依据:
  131.                    <label>
  132.                    <input name="f" type="radio" class="noborder" value="barcode" checked>
  133.                    图书条形码 &nbsp;&nbsp;
  134.                    <input name="f" type="radio" class="noborder" value="bookname">
  135. 图书名称&nbsp;&nbsp;                   
  136. <input name="inputkey" type="text" id="inputkey" size="50">
  137.                    <input name="Submit2" type="button" class="btn_grey" value="确定" onClick="checkbook(form1)">
  138.                    <input name="operator" type="hidden" id="operator" value="<%=chStr.toChinese(manager)%>">
  139.                    </label></td>
  140.                </tr>
  141.                <tr>
  142.                  <td align="center"><table width="99%" height="50"  border="1" cellpadding="0" cellspacing="0" bordercolor="#FFFFFF" bordercolorlight="#FFFFFF" bordercolordark="#D2E3E6" bgcolor="#FFFFFF">
  143.                    <tr align="center" bgcolor="#e3F4F7">
  144.                      <td width="8%" height="25" bgcolor="#F0FAFB">借阅次数</td>
  145.                      <td width="11%" bgcolor="#F0FAFB">图书条形码</td>
  146.                      <td width="17%" bgcolor="#F0FAFB">图书名称</td>
  147.                      <td width="15%" bgcolor="#F0FAFB">图书类型</td>
  148.                      <td width="16%" bgcolor="#F0FAFB">书架</td>
  149.                      <td width="14%" bgcolor="#F0FAFB">出版社</td>
  150.                      <td width="11%" bgcolor="#F0FAFB">作者</td>
  151.                      <td colspan="2" bgcolor="#F0FAFB">定价(元)</td>
  152.                    </tr>
  153. <%
  154. String bookname="";
  155. String borrowTime="";  
  156. String backTime="";
  157. Float price=new Float(0);
  158. String pubname="";
  159. String bookcase="";
  160. if(borrowForm!=null){
  161. bookname=chStr.toChinese(readerForm.getName());
  162. borrowTime=borrowForm.getBarcode();
  163. backTime=borrowForm.getBirthday();
  164. price=borrowForm.getPaperType();
  165. pubname=chStr.toChinese(borrowForm.getPaperNO());
  166. bookcase=chStr.toChinese(borrowForm.getTypename());
  167. }
  168. %>
  169.                    <tr>
  170.                      <td height="25" align="center">&nbsp;</td>
  171.                      <td style="padding:5px;">&nbsp;</td>
  172.                      <td style="padding:5px;">&nbsp;</td>
  173.                      <td style="padding:5px;">&nbsp;</td>
  174.                      <td align="center">&nbsp;</td>
  175.                      <td align="center">&nbsp;</td>
  176.                      <td width="11%" align="center">&nbsp;</td>
  177.                      <td width="8%" align="center">&nbsp;</td>
  178.                    </tr>
  179.                  </table></td>
  180.                </tr>
  181.              </table></td>
  182.            </tr>
  183.          </table></td>
  184.        </tr>
  185.      </table></td>
  186.    </tr>
  187. </table>
  188.  </form>
  189.  </td>
  190.       </tr>
  191.     </table>
  192. </td>
  193.   </tr>
  194. </table></td>
  195.   </tr>
  196. </table>
  197. </td>
  198.   </tr>
  199. </table>
  200. </body>
  201. </html>