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

📄 cangku_modi.asp

📁 下了就能用 不信你看一下 一定能用的
💻 ASP
字号:
<!--#include file="../conn.asp"-->
<%

'----------------读取原来的数据-------
id=trim(request("id"))
  set rs=server.createobject("adodb.recordset")
  rs.open "select * from ht_Storehouse where number="&id&"",conn,1,1
  if  rs.eof then
     response.write "该记录不存在,可能已经被删除!"
  else
    storehouse_id=trim(rs("storehouse_id"))
	storehouse_name=trim(rs("storehouse_name"))
	storehouse_address=trim(rs("storehouse_address"))
	storehouse_type=trim(rs("storehouse_type"))
	storehouse_capacity=trim(rs("storehouse_capacity"))
	storehouse_manager=trim(rs("storehouse_manager"))
	storehouse_tel=trim(rs("storehouse_tel")) '电话
	storehouse_remark=trim(rs("storehouse_remark"))
  end if
  rs.close
  set rs=nothing
  
'-------------修改数据

if trim(request("ckmodi"))<>"" then
    storehouse_id=trim(request("storehouse_id"))
	storehouse_name=trim(request("storehouse_name"))
	storehouse_address=trim(request("storehouse_address"))
	storehouse_type=trim(request("storehouse_type"))
	storehouse_capacity=trim(request("storehouse_capacity"))
	storehouse_manager=trim(request("storehouse_manager"))
	storehouse_tel=trim(request("storehouse_tel")) '电话
	storehouse_remark=trim(request("storehouse_remark"))
   conn.execute "update ht_Storehouse set storehouse_id='"&storehouse_id&"',storehouse_name='"&storehouse_name&"',storehouse_address='"&storehouse_address&"',storehouse_type='"&storehouse_type&"',storehouse_capacity='"&storehouse_capacity&"',storehouse_manager='"&storehouse_manager&"',storehouse_tel='"&storehouse_tel&"',storehouse_remark='"&storehouse_remark&"' where number="&id&""
   response.write "<script language='javascript'>window.opener.location.href = window.opener.location.href;window.close();</script>"
end if
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>基础资料维护--仓库修改</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="../css/body.css" rel="stylesheet" type="text/css">
 <script language="javascript">
			function check(){
			if (document.ck.storehouse_id.value==''){
			alert('请输入仓库编号!');
			document.ck.storehouse_id.focus();
			return false;
			
			history.back();
			}
			if (document.ck.storehouse_name.value==''){
			alert('请输入仓库名称!');
			document.ck.storehouse_name.focus();
			return false;
			history.back();
			}
			return true;
			}
			</script>
</head>
<body leftmargin="0" topmargin="00" marginwidth="0" marginheight="0">
<table width="100%" height="168" border="0" cellspacing="0">
  <tr> 
    <td height="168" class="borderon"> 
      <form action="cangku_modi.asp" method="post" name="ck" id="ck">
        <table width="377" border="0" align="center" cellpadding="0" cellspacing="0">
          <tr>
            <td width="78"><div align="right">仓库编号:</div></td>
            <td colspan="3"><input name="storehouse_id" type="text" id="storehouse_id" value="<%=storehouse_id%>" size="5"></td>
          </tr>
          <tr>
            <td><div align="right">仓库名称:</div></td>
            <td colspan="3"><input name="storehouse_name" type="text" id="storehouse_name" value="<%=storehouse_name%>" size="25"></td>
          </tr>
          <tr>
            <td><div align="right">仓库地址:</div></td>
            <td colspan="3"><input name="storehouse_address" type="text" id="storehouse_address" value="<%=storehouse_address%>" size="30"></td>
          </tr>
          <tr>
            <td><div align="right">仓库容量:</div></td>
            <td width="125"><input name="storehouse_capacity" type="text" value="<%=storehouse_capacity%>" size="15"></td>
            <td width="70">仓库类型:</td>
            <td width="104"><input name="storehouse_type" type="text" id="storehouse_type" value="<%=storehouse_type%>" size="10"></td>
          </tr>
          <tr>
            <td><div align="right">管 理 员:</div></td>
            <td><input name="storehouse_manager" type="text" id="storehouse_manager" value="<%=storehouse_manager%>" size="15"></td>
            <td>联系电话:</td>
            <td><input name="storehouse_tel" type="text" id="storehouse_tel" value="<%=storehouse_tel%>" size="12"></td>
          </tr>
          <tr>
            <td><div align="right">备  注:</div></td>
            <td colspan="3">&nbsp;</td>
          </tr>
		  <tr>
            <td colspan="4"><div align="center">
    <textarea name="storehouse_remark" cols="40" rows="5" id="storehouse_remark"><%=storehouse_remark%></textarea>
            </div></td>
          </tr>
		  <tr>
            <td colspan="4"><div align="center">
              <input name="ckmodi" type="submit" id="ckmodi3"  value=" 修改 " onClick="javascript:return check();">
              <input type="button" name="Submit2" value=" 取消 " onClick="javascript:window.close();">
              <input name="id" type="hidden" id="id3" value="<%=trim(request("id"))%>">
            </div></td>
          </tr>
        </table>
        </form></td>
  </tr>
</table>
</body>
</html>

⌨️ 快捷键说明

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