📄 demand.asp
字号:
<!--#include file="../config.asp"-->
<!--#include file="../inc/check_login.asp"-->
<!--#include file="../inc/functions.asp"-->
<%
Application_ID = 1000100 '本功能编号,含义请查看编码表
if not CheckAuth(Session("Employee_ID"),Application_ID) then '验证权限
Server.Transfer "../err/un_authorized.htm"
response.end
end if
%>
<!--**************身份验证部分****************-->
<%
Customer_ID = request("Customer_ID")
if not IsNot(Customer_ID,"n") then
response.write "客户编号丢失"
response.end
end if
Set conn = Server.CreateObject("ADODB.Connection")
Set rs = Server.CreateObject("ADODB.Recordset")
conn.open connstr
'取得客户名称
sql = "sp_Customer_Get_Customer_Name " & Customer_ID
set rs = conn.execute(sql)
if not rs.eof then
Customer_Name = rs("Customer_Name")
else
response.write "没有该客户"
response.end
end if
rs.close
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Untitled</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<LINK rel="stylesheet" type="text/css" href="../style.css">
<script language="JavaScript" type="text/javascript" src="../js/functions.js"></script>
</head>
<body>
<table border=0 cellpadding=1 cellspacing=1 width="100%">
<tr>
<td><a href="list.asp">客户管理</a> → <%=Customer_Name%> → <a href="demand_new.asp?Customer_ID=<%= Customer_ID %>" target="foot">添加客户需求</a></td>
<td align="right">◆ <a href="list.asp?UseResult=yes">返回上次客户查询结果</a></td>
</tr>
</table>
<hr size=1>
<table border="0" cellpadding=0 cellspacing=0 bgcolor="#EEEEEE">
<tr>
<td><a href="detail.asp?Customer_ID=<%= Customer_ID %>">客户信息</a> </td>
<td width="1" bgcolor="#FFFFFF"></td>
<td> <a href="buy_rec.asp?Customer_ID=<%= Customer_ID %>">采购记录</a> </td>
<td width="1" bgcolor="#FFFFFF"></td>
<td> <a href="pursue_rec.asp?Customer_ID=<%= Customer_ID %>">跟进记录</a> </td>
<td width="1" bgcolor="#FFFFFF"></td>
<td> <a href="relapse_rec.asp?Customer_ID=<%= Customer_ID %>">回访记录</a> </td>
<td width="1" bgcolor="#FFFFFF"></td>
<td bgcolor="#000000"> <font color="#FFFFFF">需求表</font> </td>
<td width="1" bgcolor="#FFFFFF"></td>
<td> <a href="contact_person.asp?Customer_ID=<%= Customer_ID %>">联系人</a> </td>
<td width="1" bgcolor="#FFFFFF"></td>
<td> <a href="docs.asp?Customer_ID=<%= Customer_ID %>">客户文档</a> </td>
<td width="50" bgcolor="#FFFFFF"></td>
</tr>
<tr>
<td colspan="14" bgcolor="#999999" height="1"></td>
</tr>
</table>
<table border=0 cellpadding=1 cellspacing=1 width="100%">
<tr bgcolor="#EFEFEF">
<td>添加日期</td>
<td>需求项目</td>
<td>大约金额</td>
<td>简要说明</td>
<td>业务员</td>
<td>操作</td>
</tr>
<%
'取得需求记录
sql = "select Customers_Demand.*,Employee.Employee_Name from Customers_Demand,Employee where Customers_Demand.Customer_ID = " & Customer_ID & " and Customers_Demand.Employee_ID = Employee.Employee_ID order by Customers_Demand.Demand_ID DESC"
'response.write sql
rs.open sql,conn,1
if rs.eof then
response.write "<tr><td colspan=18>暂时没有记录</td></tr></table>"
response.end
end if
PageSize = request.Cookies("PageSize")
if not IsNot(PageSize,"n") then PageSize = DefaultPageSize
rs.pagesize = PageSize
PageCount = rs.PageCount
PageNo = request("PageNo")
if PageNo = "" or CInt(PageNo) < 1 then PageNo = 1
if CInt(PageNo) > PageCount then PageNo = PageCount
rs.absolutepage = PageNo
i = 0
while not rs.eof and i < rs.pagesize
Demand_ID = rs("Demand_ID")
Demand_Date = rs("Demand_Date")
Demand_Item = rs("Demand_Item")
Demand_Account = rs("Demand_Account")
Description = rs("Description")
Employee_ID = rs("Employee_ID")
Employee_Name = rs("Employee_Name")
if i mod 2 = 0 then
response.write "<tr>"
else
response.write "<tr bgcolor=#EFEFEF>"
end if
%>
<td><nobr><%= FormatDate(Demand_Date,1) %></nobr></td>
<td><%= Demand_Item %></td>
<td>¥<%= Demand_Account %></td>
<td><%= Description %></td>
<td><nobr><a href="../employee/detail.asp?Employee_ID=<%= Employee_ID %>" target="foot"><%= Employee_Name %></a></nobr></td>
<td><nobr><a href="demand_modi.asp?Demand_ID=<%=Demand_ID%>" target="foot">修改</a>/<a href="demand_del.asp?Demand_ID=<%=Demand_ID%>" target="foot" onClick="return ConfirmOption('删除需求记录');">删除</a></nobr></td>
</tr>
<%
i = i + 1
rs.movenext
wend
rs.close
set rs = nothing
conn.close
set conn = nothing
%>
<tr bgcolor="#EFEFEF">
<td colspan="6">
<a href="demand.asp?PageNo=1&Customer_ID=<%= Customer_ID %>"><font face="Webdings">5</font>第一页</a>
<a href="demand.asp?PageNo=<%= PageNo - 1 %>&Customer_ID=<%= Customer_ID %>"><font face="Webdings">3</font>上一页</a>
<a href="demand.asp?PageNo=<%= PageNo + 1 %>&Customer_ID=<%= Customer_ID %>"><font face="Webdings">4</font>下一页</a>
<a href="demand.asp?PageNo=<%= PageCount %>&Customer_ID=<%= Customer_ID %>"><font face="Webdings">6</font>最后一页</a>
</td>
</tr>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -