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

📄 car_edit.asp

📁 *** ***** 系统进入 *** ***** 系统主文件为index.htm 系统超级用户 用户名:lhh 密码:lhh *** ***** 系统功能说明 *** ****
💻 ASP
字号:
<!--#include file="data.asp"-->
<%
if Session("Rname")=request("car_user2") or Session("Urule")="a" then

%><!--#INCLUDE FILE="check.asp" -->
<%
Set myrs= Server.CreateObject("ADODB.Recordset") 
strSql="select * from bumen"
myrs.open strSql,Conn,1,1 
Set yours= Server.CreateObject("ADODB.Recordset") 
strSql="select * from user where shenhe="&true&""
yours.open strSql,Conn,1,1 
%>

<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="oa.css">
<title>修改车辆资料</title>
</head>

<body>
<script Language="javaScript">
    function  validate()
    {
        if  (document.myform.car_code.value=="")
        {
            alert("车辆号码不能为空");
            document.myform.car_code.focus();
            return false ;
        }
        if  (document.myform.car_type.value=="")
        {
            alert("车辆类型不能为空");
            document.myform.car_type.focus();
            return false ;
        }
		if  (document.myform.car_buytime.value=="")
        {
            alert("购买日期不能为空");
            document.myform.car_buytime.focus();
            return false ;
        }
		if  (document.myform.car_buyprice.value=="")
        {
            alert("购买价格不能为空");
            document.myform.car_buyprice.focus();
            return false ;
        }
		if  (document.myform.car_money.value=="")
        {
            alert("运营费用不能为空");
            document.myform.car_money.focus();
            return false ;
        }
               return  true;
    }
</script><link rel="stylesheet" href="eintrdemo.css"> </head> <%
dim sql
dim rs
 sql="select * from car where id="&request("id")
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
                %> <body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0"> 
<form method="post" action="car_saveedit.asp?id=<%=request("id")%>" name="myform" onsubmit="return  validate()"> 
<table width="100%" border="0" cellspacing="1" cellpadding="2"> <tr > <td class="heading"> 
<div align="center"> <center> <table width="81%" border="0" cellspacing="0" cellpadding="0" bgcolor="#000000" bordercolorlight="#000000" style="font-size:9pt"> 
<tr> <td width="2%" align="right"></td><td align="left" height="25"> <p align="center"><font color="#FFFFFF"><b>修 
改 资 料</b></font></p></td><td width="3%"></td></tr> </table></center></div></td></tr> 
</table>
  <div align="center"> 
    <table width="80%" border="1" cellspacing="0" cellpadding="0" bordercolordark="#FFFFFF" bordercolor="#FFFFFF" bordercolorlight="#000000">
      <tr> 
        <td width="17%" valign="top"> <p align="right">车辆号码:</p></td>
        <td width="83%"> <input name="car_code" type="text" class="form" id="car_code" value="<%=rs("car_code")%>" size="24"> 
        </td>
      </tr>
      <tr> 
        <td width="17%" valign="top" height="6"> <p align="right"><font size="2">车辆类型:</font></p></td>
        <td width="83%" height="6"> <input name="car_type" type="text"  class="form" id="car_type" value="<%=rs("car_type")%>" size="24"> 
        </td>
      </tr>
      <tr> 
        <td width="17%"  valign="top" height="16"> <p align="right"><font size="2">购买日期:</font></p></td>
        <td width="83%" height="16"> <input name="car_buytime" type="text" class="form" id="car_buytime" value="<%=rs("car_buytime")%>" size="24"> 
        </td>
      </tr>
      <tr> 
        <td width="17%"  valign="top" height="16"> <p align="right"><font size="2">购买价格:</font></p></td>
        <td width="83%" height="16"> <input name="car_buyprice" type="text" class="form" id="car_buyprice" value="<%=rs("car_buyprice")%>" size="24"> 
        </td>
      </tr>
      <tr> 
        <td width="17%"  valign="top" height="16"> <p align="right"><font size="2">简单说明:</font></p></td>
        <td width="83%" height="16"> <input name="car_detail" type="text" class="form" id="car_detail" value="<%=rs("car_detail")%>" size="24"> 
        </td>
      </tr>
      <tr> 
        <td width="17%"  valign="top"> <p align="right"><font size="2">所属部门:</font> 
        </td>
        <td width="83%"> <select NAME="car_company" id="car_company">
            <option value="<%=rs("car_company")%>" selected><%=rs("car_company")%></option>
            <option value="公用车" > 公用车</option>
            <%if myrs.eof and myrs.bof then
response.write "<font color='red'>还没有任何部门</font>"
else
do while not (myrs.eof or myrs.bof)
%>
            <option VALUE="<%=myrs("type")%>"><%=myrs("type")%></option>
            <%myrs.movenext 
  loop 
  end if%>
          </select> </td>
      </tr>
      <tr> 
        <td width="17%"  valign="top"> <p align="right"><font size="2">所属司机:</font> 
        </td>
        <td width="83%"> <select NAME="car_user">
            <option value="<%=rs("car_user")%>" selected><%=rs("car_user")%></option>
            <option value="任意人" >任意人</option>
            <%if yours.eof and yours.bof then
             response.write "<font color='red'>还没有任何人员</font>"
             else
             do while not (yours.eof or yours.bof)
             %>
            <option value="<%=yours("name")%>"><%=yours("name")%></option>
            <%yours.movenext 
              loop 
             end if%>
          </select> </td>
      </tr>
      <tr> 
        <td width="17%"  valign="top"> <p align="right"><font size="2">司机手机:</font></p></td>
        <td width="83%"> <input name="car_usermobile" type="text" class="form" id="car_usermobile" value="<%=rs("car_usermobile")%>" size="24"> 
        </td>
      </tr>
      <tr> 
        <td width="17%"  valign="top"> <p align="right"><font size="2">司机电话:</font></p></td>
        <td width="83%"> <input name="car_usertel" type="text" class="form" id="car_usertel" value="<%=rs("car_usertel")%>" size="24"> 
        </td>
      </tr>
      <%if session("id")<>"" then %>
      <tr> 
        <td WIDTH="17%"  VALIGN="top"> <p ALIGN="right">运营费用:</p></td>
        <td WIDTH="83%"> <p>
            <textarea name="car_money" cols="43" rows="5" class="smallarea" id="car_money"><%=rs("car_money")%></textarea>
          </p></td>
      </tr>
      <tr> 
        <td width="17%"  valign="top"> <p align="right">维修记录:</p></td>
        <td width="83%"><textarea name="car_fixlog" cols="43" rows="7" class="smallarea" id="car_fixlog"><%=rs("car_fixlog")%></textarea> 
        </td>
      </tr>
      <%end if%>
    </table>
  </div><div align="center"><input type=image  src="images/modify_off.gif">&nbsp;&nbsp; 
<a  href="javaScript:window.close()"><img   border="0" src="images/close_1.gif"></a> 
</div></form>     
<%else
response.redirect "error.asp?id=admin"
end if%>

</body>
</html>

⌨️ 快捷键说明

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