<%if request.cookies("bjx")("shjianame")="" then
response.Redirect "admin_login.asp"
response.End
end if
%>
<!--#include file="conn.asp"-->
<html>
<head>
<title>263商城电话定购第一步</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="../../images/css.css" rel="stylesheet" type="text/css">
</head>
<body bgcolor="#FFFFFF" text="#000000">

<table width="98%" height="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr> 
    <td valign="top" align="center"> 
      <% Select case Request("add")
   case "t"%>
  <form method="POST" action="?add=a">
        第一步：录入客户信息 <br>
        <br>
        <table bgcolor=#CCCCCC border=0 cellpadding=3 cellspacing=1 
        width="600" align="center" class="9bang">
          <tbody>
            <tr> 
              <td bgcolor=#f1f1f1 width=100 class="008c5e" height="25" align="center"><font size="2">客户名称</font></td>
              <td bgcolor=#ffffff width=200 class="008c5e" height="25"> <font size="2"> 
                <input name=t_name type="text" class="wenbenkuang" value="" size="20">
                </font></td>
              <td width=100 height="25" align="center" bgcolor=#f1f1f1 class="008c5e"><font size="2">联系电话</font></td>
              <td bgcolor=#ffffff width=200 class="008c5e" height="25"> <font size="2"><span class="9bang"><span class="9bang"> 
                <input name="t_tel" type="text" class="wenbenkuang" value="" size="20">
                </span></span> </font></td>
            </tr>
            <tr> 
              <td bgcolor=#f1f1f1 class="008c5e" width="100" height="25" align="center"><font size="2">送货地址</font></td>
              <td colspan="3" class="008c5e" bgcolor=#FFFFFF height="25"> <font size="2"> 
                <input name="t_add" type="text" class="wenbenkuang" value="" size="71">
                </font></td>
            </tr>
            <tr> 
              <td bgcolor=#f1f1f1 class="008c5e" height="25" align="center"><font size="2">订单备注</font></td>
              <td colspan="3" class="008c5e" bgcolor=#FFFFFF height="25"><font size="2"> 
                <input name="t_biaozhi" type="text" class="wenbenkuang" value="" size="71">
                </font></td>
            </tr>
            <tr> 
              <td bgcolor=#f1f1f1 class="008c5e" height="25" align="center">配送费用</td>
              <td colspan="3" class="008c5e" bgcolor=#FFFFFF height="25"><font size="2"><span class="9bang"><span class="9bang"> 
                <input name="rmb" type="text" class="wenbenkuang" id="rmb" size="20">
                </span></span></font></td>
            </tr>
            <tr> 
              <td bgcolor=#f1f1f1 class="008c5e" width="100" height="25">&nbsp;</td>
              <td bgcolor=#ffffff class="008c5e" colspan="3" height="25"> <font size="2">&nbsp; 
                <input name="submit" type="submit" class="go-wenbenkuang" value="提交">
                <input name="Reset" type="reset" class="go-wenbenkuang" value="重填">
                <input name="Submit" type="button" class="go-wenbenkuang" onclick="javascript:window.history.go(-1)" value="返回">
                <input name="id" type="hidden" id="id" value="<%=Request("id")%>">
                </font></td>
            </tr>
          </tbody>
        </table>
      </form> <%case "x"
		id=request("id")
set rs = conn.execute("select * from telorder where t_id="&id&"")%>
 <form method="POST" action=?add=b>
        &gt;&gt;修改客户信息&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <a href="add2.asp?id=<%=Request("id")%>">&gt;&gt;修改订单信息</a> 
        <br>
        <br>
        <table bgcolor=#CCCCCC border=0 cellpadding=3 cellspacing=1 
        width="600" align="center" class="9bang">
          <tbody>
            <tr> 
              <td bgcolor=#f1f1f1 width=100 class="008c5e" height="25" align="center"><font size="2">客户名称</font></td>
              <td bgcolor=#ffffff width=200 class="008c5e" height="25"> <font size="2"> 
                <input name=t_name type="text" class="wenbenkuang" id="t_name" value="<%=rs("t_name")%>" size="20">
                </font></td>
              <td width=100 height="25" align="center" bgcolor=#f1f1f1 class="008c5e"><font size="2">联系电话</font></td>
              <td bgcolor=#ffffff width=200 class="008c5e" height="25"> <font size="2"><span class="9bang"><span class="9bang"> 
                <input name="t_tel" type="text" class="wenbenkuang" id="t_tel" value="<%=rs("t_tel")%>" size="20">
                </span></span> </font></td>
            </tr>
            <tr> 
              <td bgcolor=#f1f1f1 class="008c5e" width="100" height="25" align="center"><font size="2">送货地址</font></td>
              <td colspan="3" class="008c5e" bgcolor=#FFFFFF height="25"> <font size="2"> 
                <input name="t_add" type="text" class="wenbenkuang" id="t_add" value="<%=rs("t_add")%>" size="71">
                </font></td>
            </tr>
            <tr> 
              <td bgcolor=#f1f1f1 class="008c5e" height="25" align="center"><font size="2">订单备注</font></td>
              <td colspan="3" class="008c5e" bgcolor=#FFFFFF height="25"><font size="2"> 
                <input name="t_biaozhi" type="text" class="wenbenkuang" id="t_biaozhi" value="<%=rs("t_biaozhi")%>" size="71">
                </font></td>
            </tr>
            <tr> 
              <td bgcolor=#f1f1f1 class="008c5e" height="25" align="center">配送费用</td>
              <td colspan="3" class="008c5e" bgcolor=#FFFFFF height="25"><font size="2"><span class="9bang"><span class="9bang"> 
                <input name="rmb" type="text" class="wenbenkuang" id="rmb" value="<%=rs("rmb")%>" size="20">
                </span></span></font></td>
            </tr>
            <tr> 
              <td bgcolor=#f1f1f1 class="008c5e" width="100" height="25">&nbsp;</td>
              <td bgcolor=#ffffff class="008c5e" colspan="3" height="25"> <font size="2">&nbsp; 
                <input name="submit2" type="submit" class="go-wenbenkuang" value="提交">
                <input name="Reset2" type="reset" class="go-wenbenkuang" value="重填">
                <input name="Submit2" type="button" class="go-wenbenkuang" onclick="javascript:window.history.go(-1)" value="返回">
                <input name="id" type="hidden" id="id" value="<%=Request("id")%>">
                </font></td>
            </tr>
          </tbody>
        </table>
</form>
<%case "a"
conn.execute("Insert into telorder(t_name,t_tel,t_biaozhi,t_add,user_name,rmb)values('"&Request("t_name")&"','"&Request("t_tel")&"','"&Request("t_biaozhi")&"','"&Request("t_add")&"','"&request.cookies("bjx")("shjianame")&"','"&Request("rmb")&"')")
set rs2 = conn.execute("select t_id from telorder where  t_name='"&Request("t_name")&"' and t_tel='"&Request("t_tel")&"'")
Response.redirect "add2.asp?id="&rs2("t_id")&""
case "b"
conn.execute("Update telorder set t_name = '"&Request("t_name")&"',t_tel = '"&Request("t_tel")&"',t_biaozhi='"&Request("t_biaozhi")&"',t_add='"&Request("t_add")&"',rmb="&Request("rmb")&" where t_id="&Request("id")&"")
Response.redirect "add2.asp?id="&Request("id")&""
End Select
 %>    </td>
  </tr>
</table>
</body>
</html>





