</td>
</tr>
</table><br>
<!---------数据输出------------->
<%if(kucun_id!=0&& wp_name!=0){%>
<table border="1" width="100%" cellspacing="0" cellpadding="0" bordercolor="#808080" bordercolorlight="#808080" bordercolordark="#808080">
<jsp:useBean id="wp_select" kucun="wpman.wp_operation" scope="page"/>
<%//-----用JavaBean查询出数据,并得到总记录条数------
kucunlession_operation kucun=new kucun_operation();
if(kucunLession.getKucunCloseStatus(kucun_id, wp_name).equals("已封存")){
%>
<tr>
<td colspan="3" align="center">
此物品信息已被封存!
</td>
</tr>
<% }else{
ResultSet rs=wp_select.wp_select_part(kucun_id,null);
rs.last();
int rowCount=rs.getRow();
rs.beforeFirst();
%>
<form name="wp_core" action="core_save.jsp" method="post" onsubmit="return check_core_data()">
<tr>
<td colspan="3" align="center">物品(共<%=rowCount%>条)
</td>
</tr>
<tr>
<td colspan="3" align="right">
<input type="submit" value="保存">
</td>
</tr>
<tr>
<td width="20%" align="center">物品编号</td>
<td width="40%" align="center">物品名称</td>
<td width="40%" align="center">物品数量</td>
</tr>
<input type="hidden" value="<%= wp_name %>" name=" wp_name ">
<input type="hidden" value="<%=kucun_id%>" name="kucun_id">
<jsp:useBean id="core_operation" kucun="core.core_operation" scope="page"/>
<%
int i=0;
while(rs.next()){%>
<tr>
<td align="center" ><%=rs.getLong("wp_id")%></td>
<td align="center" ><%=rs.getString("wp_name")%></td>
<td align="center" >
<input type="text" maxlength="10" name="<%=rs.getLong("wp_id")%>" value="<%=core_operation.getWp_core(rs.getLong("wp_id"), wp_name)%>">
</td>
</tr>
<%i++;
}%>
<input type="hidden" name="all_Count" value="<%=i%>">
</form>
<%}%>
</table><br>
<%}%>
<!----------操作提示信息--------------->
<table border="1" width="100%" cellspacing="0" cellpadding="0" bordercolor="#808080" bordercolorlight="#808080" bordercolordark="#808080">
<tr>
<td width="100%">
<table border="0" width="100%">
<tr>
<td width="100%">注意:单击保存按钮会保存当前屏幕上的所有物品的基本信息</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>
package org.apache.jsp.wupin;
import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
import java.sql.ResultSet;
public final wupin wupin_jsp extends org.apache.jasper.runtime.HttpJspBase
implements org.apache.jasper.runtime.JspSourceDependent {
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
private static java.util.List _jspx_dependants;
private javax.el.ExpressionFactory _el_expressionfactory;
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
public Object getDependants() {
return _jspx_dependants;}
publicvoid_jspInit()_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();_jsp_annotationprocessor=(org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.wupin.getName());}public void _jspDestroy() {
}public void _jspService(HttpServletRequest request, HttpServletResponse response)throws java.io.IOException, ServletException {
PageContext pageContext = null;
HttpSession session = null;
ServletContext application = null;
ServletConfig config = null;
JspWriter out = null;
Object page = this;
JspWriter _jspx_out = null;
PageContext _jspx_page_context = null;
try {response.setContentType("text/html;charset=GB2312");
pageContext = _jspxFactory.getPageContext(this, request, response,null, true, 8192, true);
_jspx_page_context = pageContext;
application = pageContext.getServletContext();
config = pageContext.getServletConfig();
session = pageContext.getSession();
out = pageContext.getOut();
_jspx_out = out;
out.write("\r\n");out.write("\r\n");
out.write("<html>\r\n");
out.write("<!------系统交互javascript----->\r\n");
out.write("<script language=\"JavaScript\">\r\n");
out.write("<!--\r\n");
out.write("function check_data() {\r\n");
out.write("//按提交按钮时,检查数据是否为空\r\n");
out.write(" if(add_lession_form.lessionname.value.length==0){\r\n");
out.write(" \t\talert(\"输入的物品名为空,请重新输入!\");\r\n");
out.write(" \t\treturn false;\r\n");
out.write("\t}else return true;\t\r\n");
out.write("}\r\n");
out.write("function delete_confirm() {\r\n");
out.write("//按删除链接时,弹出确认对话框\r\n");
out.write(" if(confirm(\"确认要删除吗?\")){\r\n");
out.write(" \t\treturn true;\r\n");
out.write("\t}else return false;\t\r\n");
out.write("}\r\n");out.write("-->\r\n");
out.write("</script>\r\n");
out.write("<body bgcolor=\"#DCDADA\">\r\n");
out.write("<!---------导航菜单------------->\r\n");
org.apache.jasper.runtime.JspRuntimeLibrary.include(request, response, "navigator.txt", out, false);out.write("\r\n");
out.write("<!---------数据输入------------->\r\n");
out.write("<table border=\"1\" width=\"100%\" cellspacing=\"0\" cellpadding=\"0\" bordercolor=\"#808080\" bordercolorlight=\"#808080\" bordercolordark=\"#808080\">\r\n");
out.write(" <tr>\r\n");
out.write(" <td width=\"100%\">\r\n");
out.write(" <table border=\"0\" width=\"100%\">\r\n");
out.write(" <tr>\r\n");
out.write(" <td width=\"100%\" colspan=\"3\">录入物品信息:<br><hr></td>\r\n");
out.write(" </tr>\r\n");
out.write("<form name=\"add_lession_form\" action=\"lession_add.jsp\" method=\"post\" onsubmit=\"return check_data()\">\r\n");
out.write(" <tr>\r\n");
out.write(" <td width=\"25%\" align=\"right\">物品名:</td>\r\n");
out.write(<tdwidth=\"25%\"><inputtype=\"text\"name=\"lessionname\"maxlength=\"20\"></td>\r\n");
out.write(" <td width=\"50%\"><input type=\"submit\" value=\"提交\"></td>\r\n");
out.write(" </tr>\r\n");
out.write(" </form>\r\n");
out.write(" </table>\r\n");
out.write(" </td>\r\n");
out.write(" </tr>\r\n");
out.write("</table><br>\r\n");
out.write("<!---------数据输出------------->\r\n");
out.write("<table border=\"1\" width=\"100%\" cellspacing=\"0\" cellpadding=\"0\" bordercolor=\"#808080\" bordercolorlight=\"#808080\" bordercolordark=\"#808080\">\r\n");
wupin.lession_operation lession_select = null;
synchronized (_jspx_page_context) {lession_select = (wupin.lession_operation) _jspx_page_context.getAttribute("lession_select", PageContext.PAGE_SCOPE);
if (lession_select == null){lession_select = new wupin.lession_operation();
_jspx_page_context.setAttribute("lession_select"lession_select, PageContext.PAGE_SCOPE);}}out.write('\r');out.write('\n');
//-----用JavaBean查询出数据,并得到总记录条数------
ResultSet rs=lession_select.lession_select_all();
rs.last();int rowCount=rs.getRow();rs.beforeFirst();
out.write(' ');out.write('\r');out.write('\n');
util.rsFenYe lession_rsFenYe = null;
synchronized (_jspx_page_context) {
('\r');out.write('\n');
org.apache.jasper.runtime.JspRuntimeLibrary.handleSetProperty(_jspx_page_context.findAttribute("lession_rsFenYe"), "rs",rs);out.write("\r\n");
out.write("<!-------pageSize为每页记录条数--------->\r\n"); org.apache.jasper.runtime.JspRuntimeLibrary.introspecthelper(_jspx_page_context.findAttribute("lession_rsFenYe"), "pageSize", "10", null, null, false);
out.write("\r\n");out.write(" <tr>\r\n");
out.write(" <td colspan=\"4\" align=\"center\">\r\n");
//-----从请求参数中得到当前页码------