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

📄 frm_ydwxfy_modify.asp

📁 一套石油公司内部的运营管理系统
💻 ASP
字号:
<!--#include virtual="/include/DBCon.inc"-->
<html>
<head>
 
<title>油田采油工艺综合管理系统</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="/css/oil.css" type="text/css">
<SCRIPT LANGUAGE="javascript" src="/include/calender.js"></SCRIPT>
<SCRIPT LANGUAGE=javascript>
<!--
function subcheck() {
	form1.submit();
}
-->
</SCRIPT>

</head>

<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0"><br>
	<%
	wellId=request("wellId")
	syear=request("year")
	smonth=request("month")
	ydwxfyId=request.form("chydwxfy")
	if ydwxfyId="" then
		response.redirect "/profile/errorpage.asp?title=修改维修费用结算数据&msg=您没有选择任何数据!" 
	else
		ydwxfyId=split(ydwxfyId,",")(0)
	end if
	isSub=request.form("isSub")
	if isSub="" then
		Set Rs = Server.CreateObject("ADODB.RecordSet")
		SQL="select owc_date,owc_id,well_type,wxzl_value,dict_value,owc_repair_date,owc_repair_reason,owc_fee,owc_memo from oil.oil_owc c,oil.oil_well w,oil.oil_dict d,oil.oil_wxzl z where owc_type=wxzl_code and owc_well_id=well_id and well_area=dict_code and dict_type='area' and owc_id='" &ydwxfyId& "'"
		rs.open SQL,conn,1,1
		dim ydwxfy(8)
		ydwxfy(0)=rs("owc_id") 
		ydwxfy(1)=rs("well_type") 
		ydwxfy(2)=rs("dict_value") 
		ydwxfy(3)=rs("wxzl_value") 
		ydwxfy(4)=rs("owc_repair_date") 
		ydwxfy(5)=rs("owc_repair_reason")
		ydwxfy(6)=rs("owc_fee")
		ydwxfy(7)=rs("owc_memo")
		rs.close
		if ydwxfy(1)=0 then
			SQL="select * from oil.oil_wxzl where wxzl_code like '0%'"
		else
			SQL="select * from oil.oil_wxzl where wxzl_code like '1%'"
		end if
		rs.open SQL,conn
		dim wxzl(),wxzlCount
		wxzlCount=0
		do while not rs.eof 
			wxzlCount=wxzlCount+1
			redim preserve wxzl(wxzlCount)
			wxzl(wxzlCount-1)=rs("wxzl_code") &"@"& rs("wxzl_value")
			rs.movenext
		loop
		rs.close
%>
	<span class="subject">
		修改<%=syear%>年<%=smonth%>月井<%=wellId%>的维修费用结算数据<font color=cc0000><%=ydwxfyId%></font>
	</span> 
	<hr size="1" class=hr width="98%" align="center">
	<br>
	<form action="" method=post name=form1>
	<table border="1" cellpadding="1" cellspacing="0" align="center" class="table2" 
	  bordercolor="#000000" bordercolordark="#F8EDEB" width="90%">
	  <tr height="20">
	   <td class="title" align=center width=30%>&nbsp</td>
	   <td class="title" align=center width=30%>原数据</td>
	   <td class="title" align=center width=40%>修改后(数据不变化则不填写!)</td>	
	  </tr> 
	  <tr height="20">
	   <td class="title" align=center width=30%>维修种类</td>
	   <td align=left width=30%>&nbsp&nbsp<%=ydwxfy(3)%></td>
	   <td align=left width=40%>&nbsp&nbsp		
		   <select name=text1>
				<option value="">请选择...</option>
				<%for i=0 to wxzlCount-1%>
				<option value=<%=wxzl(i)%>><%=split(wxzl(i),"@")(1)%></option>
				<%next%>
			</select>
		</td>
	  </tr> 
	  <tr height="20">
	   <td class="title" align=center width=30%>维修日期</td>
	   <td align=left width=30%>&nbsp&nbsp<%=ydwxfy(4)%></td>
	   <td align=left width=40%>&nbsp&nbsp<input type=text name=text2 size=20 class=text>&nbsp<input type=button value=".." name=datebt class=button onclick="fPopCalendar(text2,text2); return false" alt="按此选时">	   
		</td>	
	  </tr> 
	  <tr height="20">
	   <td class="title" align=center width=30%>维修原因</td>
	   <td align=left width=30%>&nbsp&nbsp<textarea cols=30 rows=3 class=text><%=ydwxfy(5)%></textarea></td>
	   <td align=left width=40%>&nbsp&nbsp<textarea name=text3 cols=30 rows=3 class=text></textarea></td>	
	  </tr> 
	  <tr height="20">
	   <td class="title" align=center width=30%>费用结算</td>
	   <td align=left width=30%>&nbsp&nbsp<%=ydwxfy(6)%></td>
	   <td align=left width=40%>&nbsp&nbsp<input type=text name=text4 size=20 class=text></td>	
	  </tr> 
	  <tr height="20">
	   <td class="title" align=center width=30%>备注</td>
	   <td align=left width=30%>&nbsp&nbsp<textarea cols=30 rows=3 class=text><%=ydwxfy(7)%></textarea></td>
	   <td align=left width=40%>&nbsp&nbsp<textarea name=text5 cols=30 rows=3 class=text></textarea></td>	
	  </tr> 
	</table>
	<br>
	<hr size="1" class=hr width="98%" align="center">
	  <br>
	  <table width="98%" border="0" cellspacing="0" cellpadding="2" align="center">
		<tr align="center"> 
		  <td> 
			<input type=hidden name=chydwxfy value=<%=ydwxfyId%>>
			<input type=hidden name=wellId value=<%=wellId%>>
			<input type=hidden name=year value=<%=syear%>>
			<input type=hidden name=month value=<%=smonth%>>
			<input type=hidden name=isSub value=true>
			<input type="button" name="Submit32" value=" 更新 " class=button onclick=subcheck()>
			<input type="button" name="Submit32" value=" 返回 " class=button LANGUAGE=javascript onclick='javascript:location.replace("frm_ydwxfy.asp?well_id=<%=wellId%>&year=<%=syear%>&month=<%=smonth%>");'>
		  </td>
		</tr>
	  </table>
	</form>
	<%
	else
		text1=request.form("text1")
		text2=request.form("text2")
		text3=request.form("text3")
		text4=request.form("text4")
		text5=request.form("text5")
		Set Rs = Server.CreateObject("ADODB.RecordSet")
		SQL="select * from oil.oil_owc where owc_id='" &ydwxfyId& "'"
		rs.open SQL,conn,1,1
		redim ydwxfy(5)
		ydwxfy(0)=rs("owc_type") 
		ydwxfy(1)=rs("owc_repair_date") 
		ydwxfy(2)=rs("owc_repair_reason")
		ydwxfy(3)=rs("owc_fee")
		ydwxfy(4)=rs("owc_memo")
		rs.close
		if text1="" then
			text1=ydwxfy(0)
		else
			text1=split(text1,"@")(0)
		end if
		if text2="" then
			text2=ydwxfy(1)
		end if
		if text3="" then
			text3=ydwxfy(2)
		end if
		if text4="" then
			text4=ydwxfy(3)
		end if
		if text5="" then
			text5=ydwxfy(4)
		end if
		SQL="select * from oil.oil_owc where owc_id='" &ydwxfyId& "'"
		rs.open SQL,conn,1,3
		rs("owc_type")=text1
		rs("owc_repair_date")=text2
		rs("owc_repair_reason")=text3
		rs("owc_fee")=text4
		rs("owc_memo")=text5
		rs.update
		rs.close
		response.redirect "frm_ydwxfy.asp?year=" &syear& "&month=" &smonth& "&well_id=" &wellId
	end if
	%>
</body>
</html>
<!--#include virtual="/include/DBClose.inc"-->

⌨️ 快捷键说明

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