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

📄 projectxiangxi.jsp

📁 一个毕业设计网络招标系统实现了招标的业务逻辑内含了数据库sql server备份文件
💻 JSP
字号:
<%@ page language="java"
	import="java.util.*,C03.BO.*,C03.VO.*"
	pageEncoding="GB2312"%>

<%
String username = (String) session.getAttribute("username");
			if (username == null)
				response.sendRedirect("error.jsp?error=usernull");
	int i = 1;
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
	String tb = null;

	String id = request.getParameter("ID");

	String action = request.getParameter("action");
	

	if (action == null)
		action = "";

	String action1 = request.getParameter("action1");
	if (action1 == null)
		action1 = "";
	String addproduct = request.getParameter("addproduct");
	if (addproduct == null)
		addproduct = "";
	String stri = request.getParameter("i");
	if (stri == null)
		stri = "";
		else i = Integer.parseInt(stri);
	if (action.equals(""))
		tb = "";
	if (action.equals("tb"))
		tb = "tb";
	Vector vc = new Vector();
	projectBO bo = new projectBO();
	vc = bo.returnProject(id);
	projectBean pb = (projectBean) vc.get(0);

	Vector vc1 = new Vector();
	productBO pdb = new productBO();
	vc1 = pdb.returnzbproduct(id);
%>


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<base href="<%=basePath%>">

		<title>My JSP 'Projectxiangxi.jsp' starting page</title>

		<meta http-equiv="pragma" content="no-cache">
		<meta http-equiv="cache-control" content="no-cache">
		<meta http-equiv="expires" content="0">
		<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
		<meta http-equiv="description" content="This is my page">
		<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
		<script language="javaScript">
	function check3(){

	if(document.myform.tb_cost.value==""){
	alert("投标资金不能为空");
	return false;
	}
	if(document.myform.tb_content.value==""){
	alert("投标说明不能为空");
	return false;
	}

	
	}
		function check(){
		
		window.navigate("Projectxiangxi.jsp?action1=1&ID=<%=id%>&action=tb");
		}
		function check1(){
		
		window.navigate("Projectxiangxi.jsp?action1=2&ID=<%=id%>&action=tb");
		}
		function addproduct(){
		
	
		
		
		window.navigate("Projectxiangxi.jsp?action1=1&addproduct=yes&i=<%=i+1%>&ID=<%=id%>&action=tb");
		
	}	
	</script>

	</head>

	<body><iframe  height=0></iframe>
		<form action="servlet/toubiaoCheck?xmID=<%=id%>&productsum=<%=i%>" method="POST"
			name="myform">
			<table align="center" bgcolor="#33ccff" border="1">
				<tr>
					<td>
						项目编号:
					</td>
					<td colspan="2">
						<%=pb.getProject_id()%>
					</td>
				</tr>
				<tr>
					<td>
						项目名称:
					</td>
					<td colspan="2">
						<%=pb.getProject_name()%>
					</td>
				</tr>
				<tr>
					<td>
						项目发布时间:
					</td>
					<td colspan="2">
						<%=pb.getProject_time()%>
					</td>
				</tr>
				<tr>
					<td>
						项目所属公司:
					</td>
					<td colspan="2">
						<%=pb.getProject_company()%>
					</td>
				</tr>
				<tr>
					<td>
						项目资金:
					</td>
					<td colspan="2">
						<%=pb.getProject_cost()%>
					</td>

				</tr>
				<tr>
					<td>
						项目参与产品:
					</td>
					<td colspan="2">
						<%
								for (int n = 0; n < vc1.size(); n++) {
								productBean bean = (productBean) vc1.get(n);
						%>
						<a href="productxiangxi.jsp?product_id=<%=bean.getProduct_id()%>"
							target="_blank"><%=bean.getProduct_name()%> </a>&nbsp;
						<%
						}
						%>
					</td>

				</tr>
				<tr>
					<td>
						项目说明:
					</td>
					<td colspan="2">
						<%=pb.getProject_content()%>
					</td>
				</tr>
				<%
				if (action.equals("")) {
				%>
				<tr>
					<td>
						<a href="Projectxiangxi.jsp?ID=<%=id%>&action=tb">我要投标</a>
					</td>
					<td colspan="2">
						<a href="information.jsp">返回</a>
					</td>

				</tr>
				<%
				} else {
				%>


				<%
				if (action.equals("tb")) {
				%>


				<tr>
					<td>
						请填写您投标的资金
					</td>
					<td colspan="2">
						<input type="text" size="8" name="tb_cost">
					</td>
				</tr>
				<tr>
					<td>
						是否有产品参与
					</td>
					<td colspan="2">

						<input type="radio" name="rodio" onclick="check1()" value="1"
							checked="checked">

						<input type="radio" name="rodio" onclick="check()" value="2"
							<%if(action1.equals("1")){%> checked="checked" <%} %>>

					</td>
				</tr>

				<%
				if (action1.equals("1")) {
				%>


				<%
							if (addproduct.equals("yes")) {

							for (int n = 1; n < i; n++) {
								
				%>
				
				<tr>
					<td>
						产品名称:
					</td>
					<td>
						<input type="text" size="10" name="productname<%=n%>">
						
						
						产品价格:
						<input type="text" size="5" name="productprice<%=n%>">
						产品说明:
					</td>	
					<td>
						
						<textarea wrap="soft" name="project_content<%=n%>" rows="5" cols="10"></textarea>
					</td>
				</tr>
				<%
						}
						}
				%>
				<tr>
					<td>
						<input type="button" value="添加产品" name="button1"
							onclick="addproduct()">
					</td>
				</tr>
				<%
				}
				%>
				<tr>
					<td>
						请填写投标说明
					</td>
					<td colspan="2">
						<textarea wrap="soft" name="tb_content" rows="5" cols="20"></textarea>
					</td>
				</tr>
				<tr>
					<td align="right">
						<input type="Submit" value="提交" onclick="return check3()">
					</td>
					<td colspan="2" align="center">
						<input type="Reset" value="重设">
					</td>
				</tr>

				<%
					}
					}
				%>

			</table>
		</form>

	</body>
</html>

⌨️ 快捷键说明

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