gyqiankuan.asp
来自「创建和运行动态、交互的Web服务器应用程序」· ASP 代码 · 共 279 行 · 第 1/2 页
ASP
279 行
<td width="6%" bgcolor="#ece9d8"><div align="center">序号</div></td>
<td bgcolor="#ece9d8"> 商品名称</td>
<td bgcolor="#ece9d8"><div align="center">定价</div></td>
<td bgcolor="#ece9d8"><div align="center">数量</div></td>
<td bgcolor="#ece9d8"><div align="center">采购金额</div></td>
<td bgcolor="#ece9d8"><div align="center">应付金额</div></td>
<td bgcolor="#ece9d8"><div align="center">退书金额</div></td>
<td bgcolor="#ece9d8"><div align="center">库存金额</div></td>
</tr>
<% if rs_sx.bof and rs_sx.eof then
response.write "<tr><td colspan=8 align=center bgcolor=#ffffff><div align=center><font color=blue>没有你要查询的记录!</font></td></tr>"
else
'/分页显示上部分
Page = rs_sx.AbsolutePage
rs_sx.PageSize=15
if Not IsEmpty(Request("Page")) then
Page = CInt(Request("Page"))
if Page > rs_sx.PageCount then
rs_sx.AbsolutePage = rs_sx.PageCount
elseif Page <= 0 then
Page = 1
else
rs_sx.AbsolutePage = Page
end if
else
Page = 1
end if
For i =0 to rs_sx.PageSize
if rs_sx.EOF then Exit For
%>
<tr>
<td bgcolor="#ffffff"><div align="center"><%=rs_sx.bookmark%></div></td>
<td bgcolor="#ffffff" STYLE='PADDING-LEFT: 5px'><%=rs_sx("bookname")%></td>
<td bgcolor="#ffffff"><div align="center"><%=formatnumber(rs_sx("shichangjia"),2)%></font></div></td>
<td bgcolor="#ffffff"><div align="center"><font color=blue> <%=rs_sx("cgcount")%></font></div></td>
<td bgcolor="#ffffff"><div align="center"><font color=brown> <%=formatnumber(rs_sx("cgsy"),2)%></font></div></td>
<% t_c=0:t_y=0:t_t=0:t_q=0
t_c=t_c+rs_sx("cgsy")
if rs_sx("Sum_yhksy")=0 then
response.write "<td bgcolor=#ffffff><div align=center><font color=blue>0.00</font></div></td>"
else
response.write "<td bgcolor=#ffffff><div align=center><font color=blue>"&rs_sx("Sum_yhksy")&"</font></div></td>"
end if
t_y=t_y+rs_sx("Sum_yhksy")
if rs_sx("Sum_sumts")=0 then
response.write "<td bgcolor=#ffffff><div align=center><font color=green>0.00</font></div></td>"
else
response.write "<td bgcolor=#ffffff><div align=center><font color=green>"&rs_sx("Sum_sumts")&"</font></div></td>"
end if
t_t=t_t+rs_sx("Sum_sumts")
if rs_sx("Sum_sumkc")=0 then
response.write "<td bgcolor=#ffffff><div align=center><font color=red>0.00</font></div></td>"
else
response.write "<td bgcolor=#ffffff><div align=center><font color=red>"&rs_sx("Sum_sumkc")&"</font></div></td>"
end if
t_q=t_q+rs_sx("Sum_sumkc")
%>
</tr>
<%
//分页显示下部分
rs_sx.MoveNext
next
end if
%>
<tr>
<td colspan=8 bgcolor="#ece9d8" height=40><div align="center">共<font color=blue><%=rs_sx.recordcount%></font>条<font color=blue><%=rs_sx.pagecount%></font>页
<%if request("page")>1 then%>
<a Href="gyqiankuan.asp?action=list_search&s_gyid=<%=s_gyid%>&s_year=<%=s_year%>&s_month=<%=s_month%>&s_day=<%=s_day%>&Page=<%=1%>">首页</a> <a Href="gyqiankuan.asp?action=list_search&s_gyid=<%=s_gyid%>&s_year=<%=s_year%>&s_month=<%=s_month%>&s_day=<%=s_day%>&Page=<%=page-1%>">上一页</a>
<%end if %>
<%if request("page")<>rs_sx.pagecount and page<rs_sx.pagecount then %>
<a Href="gyqiankuan.asp?action=list_search&s_gyid=<%=s_gyid%>&s_year=<%=s_year%>&s_month=<%=s_month%>&s_day=<%=s_day%>&Page=<% =page + 1%>">下一页</a> <a Href="gyqiankuan.asp?action=list_search&s_gyid=<%=s_gyid%>&s_year=<%=s_year%>&s_month=<%=s_month%>&s_day=<%=s_day%>&Page=<%=rs_sx.PageCount%>">尾页</a>
<%end if
if rs_sx.pagecount>0 then %>
第<font color="#FF3300"><%=page%></font>页
<%end if%></font></div></td>
</tr>
</table>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr height=30>
<%
set rs_gy=server.CreateObject("adodb.recordset")
rs_gy.open "SELECT * FROM shop_gongyi where gyid="&s_gyid,conn,1,1
response.write "<td align=center><b>合计</b></td>"
response.write "<td>采购金额:<font color=brown>"
if t_c=0 then
response.write "0:00</td>"
else
response.write t_c
end if
response.write "<td>应付金额:<font color=blue>"
if t_y=0 then
response.write "0.00</td>"
else
response.write t_y
end if
response.write "<td>退书金额:<font color=green>"
if t_t=0 then
response.write "0.00</td>"
else
response.write t_t&"</td>"
end if
response.write "</font><td>欠款金额:<font color=red>"
if t_q=0 then
response.write "0.00</td>"
else
response.write t_q+t_y&"</td>"
end if
%>
</tr>
</table>
<%end select%>
</tr>
</table>
</tr>
</table>
</tr>
</table>
</tr>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?