📄 pohistoryprice.asp
字号:
<!--#include file="../config.ini"-->
<!--#include file="../commfunction.inc" -->
<%sysid=1%>
<html>
<head>
<title>型号:<%=Request.QueryString("themodel")%>最近10次历史价格</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<LINK href="../global.css" rel=stylesheet type=text/css>
</head>
<script language="JavaScript" type="text/JavaScript">
function pickup2(theprice,thepoaccountid,thepoaccount){
window.opener.form1.poprice.value=theprice;
window.opener.form1.Manufacturer.value=thepoaccountid;
window.opener.form1.Manufacturername.value=thepoaccount;
window.close();
}
</script>
<body>
<%
set conn=server.CreateObject("adodb.connection")
conn.Open connstring
sql = "select top 10 * from v_MaterialTransaction_history where returnqty='' and productid="&Request.QueryString("theproductid")&" and transactcode='收货单收货' and sysaccountid="&sysid
set rs=conn.Execute(sql)
%>
<font class=title>型号:<%=Request.QueryString("themodel")%></font><br>
<font color="#330000" size=2><b>最近10次历史价格</b></font>
<table align="center" border='2' cellpadding='0' cellspacing='0' style='border-collapse: collapse' bordercolor='#C0C0C0' width='100%' bordercolorlight='#CCCCCC' bordercolordark='#808080'>
<tr><td width='100%' align='center'>
<table border=1 cellpadding=0 cellspacing=0 style="border-collapse: collapse" bordercolor="#FFFFFF" width="100%">
<tr bgcolor='#FFE6FF'>
<td align=center nowrap height="22" width=5%>序号</td>
<td align=center nowrap width=20%>价格</td>
<td align=center nowrap >采购单号</td>
<td align=center nowrap width=30%>成交日期</td>
</tr>
<%
refcost=getfieldvalue("product","productid",Request.QueryString("theproductid"),"cost")
refsupplier=getfieldvalue("product","productid",Request.QueryString("theproductid"),"supplier")
refsuppliername=getfieldvalue("account","accountid",refsupplier,"account")
%>
<tr bgcolor="#D6CCFF">
<td align="center" nowrap height="22"><%=1%></a></td>
<td align="center" nowrap><font color=red><a href="javascript:pickup2('<%=refcost%>','<%=refsupplier%>','<%=refsuppliername%>');"><%=formatnumber(refcost,2)%></a></font></td>
<td align="center" nowrap>--</td>
<td align="center" nowrap><font color="#990000">参考成本</font></td>
</tr>
<%
if not rs.EOF and not rs.BOF then
j=1:while not rs.EOF
if j mod 2 = 1 then
%>
<tr bgcolor="#E6FDFF">
<%else%>
<tr bgcolor="#FDFFD7">
<%end if%>
<td align="center" nowrap height="22"><%=j+1%></a></td>
<td align="center" nowrap><font color=red><a href="javascript:pickup2('<%=rs("cost")%>','<%=rs("poaccountid")%>','<%=rs("poaccount")%>');"><%=formatnumber(rs("cost"),2)%></a></font></td>
<td align="center" nowrap><%=rs("pono")%></td>
<td align="center" nowrap><%=rs("Transactdate")%></td>
</tr>
<tr bgcolor="#EFEFEF">
<td height="16"> </td>
<td colspan=3><font color="#666666"><%=rs("poaccount")%>《数量:<%=rs("qty")%>》</font></td>
</tr>
<%
j=j+1
rs.MoveNext
wend
else
Response.Write "<tr bgcolor=white><td colspan=4>无历史记录</td></tr>"
end if
%>
</table></td></tr></table>
<%
rs.close
Set rs = nothing
conn.Close
set conn = nothing
%>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -