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

📄 materialchangetable_update.jsp

📁 JSP移动商品管理平台源代码.........
💻 JSP
字号:
<%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" import="common.*,java.util.*,imis_mate.bean.MaterialChangeBean,imis_mate.DAO.*" errorPage="error.jsp" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">


<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>物品变更信息</title>
</head>

<body background="/Imis/imis_mate/images/bg_main.png">

	 <script language="JavaScript" src="/Imis/imis_mate/js/checkdata.js"></script>
	 <script language="JavaScript" src="/Imis/imis_mate/js/MaterialChangeTable.js"></script>
	 <link rel="stylesheet" type="text/css" href="/Imis/imis_mate/css/style.css">
	 	<script type="text/javascript" > 
		function NewPageSubmit() {
				form1.action = "../servlet/MaterialChangeServlet?pattern=newPage";
				form1.onsubmit = "";	
		}
		function UpdateSubmit(){ 
<%--			r = CheckSubmit();--%>
			
				ask = confirm("你确定修改该记录吗?");
			
			if(ask){
				if(checkValue()){
					form1.action = "../servlet/MaterialChangeServlet?pattern=update";
		  			return true;
		  			}
		  		else{
		  			return false;
		  			}
				}
			} 
		function DeleteSubmit(){ 
			ask = confirm("你确定删除该记录吗?");
			if(ask){
				form1.action = "../servlet/MaterialChangeServlet?pattern=delete";
				parent.iframe_elec_tree.location.reload();  //刷新左半边的树 框架名称在menu页面内
				form1.onsubmit = "";
			}	
		} 
		function getvalue() {
		    document.form1.action = "/Imis/servlet/MaterialChangeServlet?pattern=getValue&&pag=update";
		    document.form1.target = "_self";
		    document.form1.submit();
		}
		function windowClose() {
		//采购入库
			form1.onsubmit = "";
			form1.action = "/Imis/servlet/MaterialChangeServlet?pattern=windowClose"
			
		}
	</script > 

	<table width="100%"  border="0" background="/Imis/imis_mate/images/bg_main2.png">
	  <tr>
	    <td><span class="tubiao">物品变更信息</span></td>
	  </tr>
	</table>
	<c:if test="${requestScope.mate!=null}">
<form method="post" action=""  name="form1" onSubmit="return checkValue()">
  <table align="center" width="538" border="0" class="ziti">
    <tr class="ziti">
     <td align="right" width="18%">变更编号</td>
      <td width="35%"><input name="changeID" type="text"  class="text1" id="changeID" value="${requestScope.mate.changeID}" size="10" maxlength="9" readonly="readonly"/>
      <font color="#ff0000">*</font></td>
      <td width="14%"><div align="right">更变类型</div></td>
      <td width="33%"><select name="changeType" id="changeType" class="text1" value="${requestScope.mate.changeType}">
				<c:if test="${requestScope.mate.changeType==1}">
					<option value="1" selected>入库</option>
				</c:if>
				<c:if test="${requestScope.mate.changeType==2}">
					<option value="2" selected>转部门</option>
				</c:if>
				<c:if test="${requestScope.mate.changeType==3}">
					<option value="3" selected>报废</option>
				</c:if>
				<c:if test="${requestScope.mate.changeType==4}">
					<option value="4" selected>其他</option>
				</c:if>
            </select><font color="#ff0000">*</font></td>
    </tr>
    <tr>
      <td align="right" width="18%">原出库ID</td>
      <td width="35%"><input name="outNoId" type="text"  class="text1" id="outNoId" value="${requestScope.mate.outNoId}" size="10" maxlength="9" readonly="readonly"/>
      <font color="#ff0000">*</font></td>
      <td width="14%"><div align="right"></div></td>
      <td width="33%">&nbsp;      </td>
    </tr>
    <tr>
      <td align="right" width="18%">更变数量</td>
      <td width="35%"><input name="outCount" type="text"  class="text1" id="outCount" value="${requestScope.mate.outCount}" size="10" maxlength="9" readonly="readonly"/>
      <font color="#ff0000">*</font></td>
      <td width="14%"><div align="right">更变日期</div></td>
      <td width="33%">
      <input name="outDate" id="outDate" size="10" maxlength="10"
							type="text" class="text1"
						 readonly="readonly" 	 value="${requestScope.mate.outDate}"/><font color="#ff0000">*</font>
     
<%--	  <Script>DateBox("outDate")</Script><font color="#ff0000">*</font></td>--%>
    </tr>
    <tr>
      <td align="right" width="18%"> 更变人</td>
      <td width="35%"><input name="userCode" type="text"  class="text1" id="userCode" value="${requestScope.mate.userCode}" size="20" maxlength="30" readonly="readonly"/></td>
      <td width="14%"><div align="right"></div></td>
      <td width="33%">&nbsp;      </td>
    </tr>
	<tr>
      <td align="right" width="18%"> 原部门 </td>
      <td width="35%">

        <select name="oraDep" id="oraDep"  class="text1" >
       <% 

		MaterialChangeBean mate = (MaterialChangeBean)request.getAttribute("mate");
		if(mate!=null)
	 {   int  deptId = 0;
		String deptName = null;
		DepartmentsBean describe1 = new DepartmentsBean();
		ArrayList list1 = describe1.getDepts();
		Iterator itr1 = list1.iterator();
        while (itr1.hasNext()) {
     	Hashtable ht = (Hashtable) itr1.next();  
		deptId      =  Integer.parseInt(ht.get("deptId").toString());
       	deptName   =  ht.get("deptName").toString(); 
       
		if(mate.getOraDep()==deptId){%>

		<option value=<%=deptId%> selected><%=deptName%></option>
		
		<%}
		else
		{%>
<%--		<option value=<%=deptId%>><%=deptName%></option>--%>
		<%		
		}
		}}
		
		%>
        </select>
        
        </td>
         <td align="right" width="18%">责任人</td>
      <td width="35%"><input name="managerBy" type="text"  class="text1" id="managerBy" value="${requestScope.mate.managerBy}" size="20" maxlength="30"/></td>
      
     
    </tr>
       <tr>
        <td width="14%"><div align="right">转入部门</div></td>
      <td width="33%">
    
    	 <select name="useDep" id="useDep"  class="text1" >
    	 <option value="">无</option>
       <% 

		MaterialChangeBean mate1 = (MaterialChangeBean)request.getAttribute("mate");
		if(mate1!=null)
	 {   int  deptId = 0;
		String deptName = null;
		DepartmentsBean describe1 = new DepartmentsBean();
		ArrayList list1 = describe1.getDepts();
		Iterator itr1 = list1.iterator();
        while (itr1.hasNext()) {
     	Hashtable ht = (Hashtable) itr1.next();  
		deptId      =  Integer.parseInt(ht.get("deptId").toString());
       	deptName   =  ht.get("deptName").toString(); 
       
		if(mate.getUseDep()==deptId){%>

		<option value=<%=deptId%> selected><%=deptName%></option>
		
		<%}
		else
		{%>
<%--		<option value=<%=deptId%>><%=deptName%></option>--%>
		<%		
		}
		}
		}
		
		%>
        </select>
      </td>
     <td width="14%"><div align="right">使用人</div></td>
      <td width="33%"><input name="useBy" type="text"  class="text1" id="useBy" value="${requestScope.mate.useBy}" size="20" maxlength="30" readonly="readonly"/>
      </td>
    </tr>
    <tr>
      <td align="right" width="18%">建筑物代号</td>
      <td>
<%--      <input name="buildingNu" type="text"  class="text1" id="buildingNu2" value="${requestScope.mate.buildingNu}" size="20" maxlength="30"/>--%>
              			<select name="buildingNu" id="buildingNu" class="text1" onchange="getvalue()">
              				<option value="">无</option>
							 <% 
							   MaterialChangeBean mbb = new MaterialChangeBean();
  								mbb = (MaterialChangeBean)request.getAttribute("mate");
								String buildingNu = null;
								String buildingName = null;
								HousBuildingAndRoom mate3 = new HousBuildingAndRoom();
								ArrayList buildList = mate3.getBuildingList();
								Iterator buildItr = buildList.iterator();
								 while (buildItr.hasNext()) {
									Hashtable ht = (Hashtable) buildItr.next();  
									buildingNu = ht.get("BuildingNu").toString();
									buildingName = ht.get("BuildingName").toString();
									if(mbb!=null && mbb.getBuildingNu()!=null && mbb.getBuildingNu().equals(buildingNu)){%>
										<option value=<%=buildingNu%> selected><%=buildingName%></option>
										<%}
									else
										{%>
<%--										<option value=<%=buildingNu%>><%=buildingName%></option>--%>
										<%		
										}
										}
										%>
					  </select>
      </td>
      <td align="right" width="14%">放置位置房间</td>
      <td>          
<%--      <input name="roomNu" type="text"  class="text1" id="roomNu" value="${requestScope.mate.roomNu}" size="20" maxlength="30"/>          --%>
		<select name="roomNu" id="roomNu" class="text1">
			<option value="">无</option>
			<% 
  			ArrayList roomList = (ArrayList)request.getAttribute("roomList");
			String RoomNu = null;
			if(roomList!=null && roomList.size() != 0) {
				Iterator itr2 = roomList.iterator();
			while (itr2.hasNext()) {
				Hashtable ht = (Hashtable) itr2.next();  
				RoomNu = ht.get("RoomNu").toString();
				if(mbb!=null && mbb.getRoomNu()!=null && mbb.getRoomNu().equals(RoomNu)){%>
			<option value=<%=RoomNu%> selected><%=RoomNu%></option>
			<%}
			else
			{%>
<%--			<option value=<%=RoomNu%>><%=RoomNu%></option>--%>
			<%		
			}
			}}
			%>
		</select>
        </td></tr>
    <tr>
      <td width="18%"><div align="right">更变原因</div></td>
      <td align="left"><textarea name="changeCause" cols="20" rows="4" id="changeCause"  class="textarea1" readonly="readonly"> ${requestScope.mate.changeCause}</textarea>
      </td>
      <td width="14%"><div align="right">摘要</div></td>
      <td align="left"><textarea name="remark" cols="20" rows="4" id="remark"  class="textarea1" readonly="readonly">${requestScope.mate.reMark}</textarea>
      </td>
    </tr><tr>
						<td>&nbsp;</td>
						</tr>
	<c:if test="${requestScope.notSubmit==null}">
	    <tr>
	      <td colspan="4" align="left"><div align="center">
	<%--					<input type="submit" name="Submit" value="添  加" onclick="NewPageSubmit()" class="anniu"/>--%>
	<%--					<input type="submit" name="Submit" value="修  改" onclick="return UpdateSubmit()" class="anniu"/>--%>
						<input type="submit" name="Submit" value="删  除" onclick="DeleteSubmit()" class="anniu"/>
	      </div></td>
	    </tr>
    </c:if>
    <c:if test="${requestScope.notSubmit!=null}">
	    <tr>
	      <td colspan="4" align="left"><div align="center">
				<input type="submit" name="Submit" value="关 闭" onclick="windowClose()" class="anniu"/>
	      </div></td>
	    </tr>
    </c:if>
  </table>
</form>
</c:if>
</body>
</html>

⌨️ 快捷键说明

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