📄 index.asp
字号:
<% Option Explicit %>
<!-- #include virtual="/admin/orderForm/_lib/orderform_lib.asp" -->
<%
Dim RS,Sql,sAdminid,sunGrade
Dim sStartPage,sPageNum,sRecordNum,i
Dim scst,ssst,soid,sds,sde
DB_Connect(strconn)
'---验证身份----
Call AdminCheck
sql="select b.Usr_name,a.Odr_no,a.Odr_time,a.Odr_ispass,a.Odr_sendState from t_UserOrderCon a , t_UserInfo b where a.Usr_Id=b.Usr_Id order by Odr_time desc"
Set RS=Server.CreateObject("ADODB.RecordSet")
RS.PageSize=5
sStartPage=request("stp")
if sStartPage="" or not(IsNumeric(sStartPage)) then
sStartpage=1
End if
RS.open sql,oConn,1
sRecordNum=RS.Recordcount
sPageNum=RS.pagecount
if sRecordNum=-1 then
sRecordNum=0
End if
%>
<HTML>
<HEAD>
<title>电子商城</title>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=gb2312">
<LINK REL="stylesheet" HREF="/inc/css/pub.css" TYPE="TEXT/CSS">
</HEAD>
<BODY BGCOLOR=#ffffff TOPMARGIN=0 LEFTMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>
<!--#include virtual="/admin/inc/all_top.asp" -->
<!--#include virtual="/admin/inc/all_first_top.asp" -->
<!--#include virtual="/admin/inc/all_second_top.asp" -->
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH=710>
<TR>
<TD COLSPAN=3><IMG SRC="/images/dot.gif" WIDTH="1" HEIGHT="10" BORDER=0 ></TD>
</TR>
<TR>
<TD WIDTH=170 ALIGN=right VALIGN=top>
<!--#include virtual="/admin/inc/default_left.asp" -->
</TD>
<TD WIDTH=20><IMG SRC="/images/dot.gif" WIDTH="20" HEIGHT="1" BORDER=0 ></TD>
<TD WIDTH=520 VALIGN=top CLASS=txt>
<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0>
<TR BGCOLOR="#000000">
<TD><IMG SRC="/images/dot.gif" WIDTH="1" HEIGHT="1" BORDER=0 ></TD>
</TR>
</TABLE>
<TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=2 dwcopytype="CopyTableRow">
<TR>
<TD ALIGN=left height="25" valign="middle" colspan="2">
</TD>
</TR>
<tr>
<td align=left height="25" valign="middle">
<%if sStartPage=1 then
%>首页
<% elseif sStartPage>1 then%>
<a href="javascript:openpage(1)" >首页</a>
<% End if %>
<%if sStartPage>1 then %>
<a href="javascript:openpage('<%response.write sStartPage-1%>')" ><<上一页</a>
<%
else %>
<<上一页
<% end if %>
<%
if cint(sPageNum)>cint(sStartPage) then
%>
<a href="javascript:openpage('<%response.write sStartPage+1%>')" >下一页>></a>
<%else%>
下一页>>
<%End if %>
<%if sPageNum=1 then
%>尾页
<% elseif sPageNum>1 then%>
<a href="javascript:openpage('<%response.write sPageNum%>')" >尾页</a>
<% End if %>
</td>
<td class="ko" align=right valign="middle">
<%if sPageNum=0 or sPageNum="" or spagenum=-1 then sPageNum=1%>
<form name="frmjump" method="post" action="index.asp" onsubmit="javascript:jumpto(document.frmjump.stp.value)">
第<%response.write sStartPage %>页|共<%Response.write sPageNum%>页 进入第 <input type="text" name="stp" size="3" style="font-family:arial; width:30px;">
页
<input type="image" border="0" name="imageField3" src="/images/go.gif" width="27" height="14">
</form>
</td>
</td>
</tr>
</TABLE>
<HR SIZE=1>
<FORM METHOD=POST name=frmOrderList ACTION="oderdetails1.asp">
<input type="hidden" name="stp" value=<%response.write sStartPage%>>
<%
If Not RS.Eof And Not RS.Bof Then
RS.AbsolutePage=sStartPage
i=0
Do while not RS.eof and i<5
%>
<table width=520 border=0 cellspacing=1 cellpadding=0>
<tr>
<td bgcolor=#548BFF>
<table width=100% border=0 cellspacing=1 cellpadding=0>
<tr>
<td bgcolor=#ffffff>
<table width=100% border=0 cellspacing=1 cellpadding=3>
<tr>
<td class=ttable bgcolor=#548BFF width="6%">订号</td>
<td class=v9 bgcolor=#E6E6E6><a href="orderdetail.asp?im=1&orderid=<%response.write RS("Odr_no")%>"><%response.write RS("Odr_no")%></a></td>
<td class=ttable bgcolor=#548BFF width="11%">订购人</td>
<td class=v9 bgcolor=#E6E6E6 width="20%"><%response.write RS("Usr_name")%></td>
<td class=ttable bgcolor=#548BFF width="11%">订购状态</td>
<td class=v9 bgcolor=#E6E6E6 width="10%">
<%
If RS("Odr_ispass")="0" then
%>
<input type="checkbox" name="ckbpass" value="<%response.write RS("Odr_no")%>">确定
<%Else
Response.write "已确定"
End If %>
</td>
</tr>
<tr>
<td class=ttable bgcolor=#548BFF width="11%">订购日期</td>
<td class=v9 bgcolor=#E6E6E6 width="20%"><%response.write year(RS("Odr_time"))&"-"&month(RS("Odr_time"))&"-"&day(RS("Odr_time")) %></td>
<td class=ttable bgcolor=#548BFF width="11%">发送状态</td>
<td class=v9 bgcolor=#E6E6E6 width="11%"> <%
Select Case RS("Odr_sendstate")
Case 1 response.write "发送"
Case 0 response.write "未发送"
End Select
%></td>
<td class=ttable colspan=2 bgcolor=#548BFF align=right><a href="orderdetail.asp?orderid=<%response.write RS("Odr_no")%>"><u><font color="#FFFFFF">订单详细信息>></font></u></A>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<table width=100% border=0 cellspacing=1 cellpadding=3>
<tr>
<td colspan=9><img src="/images/dot.gif" width="1" height="5" border=0 ></td>
</tr>
</table>
<%
Rs.movenext
i=i+1
loop
Else %>
<table width=100% border=0 cellspacing=1 cellpadding=0>
<tr>
<td >
<table width=100% border=0 cellspacing=1 cellpadding=0>
<tr>
<td bgcolor=#ffffff align="center" height="25"> 没有订单 </td>
</tr>
</table>
</td>
</tr>
</table>
<%
End If
DB_RSConnect(RS)
%>
<HR SIZE=1>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td align=left height="25" valign="middle">
<%if sStartPage=1 then
%>首页
<% elseif sStartPage>1 then%>
<a href="javascript:openpage(1)" >首页</a>
<% End if %>
<%if sStartPage>1 then %>
<a href="javascript:openpage('<%response.write sStartPage-1%>')" ><<上一页</a>
<%
else %>
<<上一页
<% end if %>
<%
if cint(sPageNum)>cint(sStartPage) then
%>
<a href="javascript:openpage('<%response.write sStartPage+1%>')" >下一页>></a>
<%else%>
下一页>>
<%End if %>
<%if sPageNum=1 then
%>尾页
<% elseif sPageNum>1 then%>
<a href="javascript:openpage('<%response.write sPageNum%>')" >尾页</a>
<% End if %>
</td>
<td align="right">每页:5 页次:<%response.write sStartpage%>/
<%Response.write sPageNum%>
订单总数:<%Response.write sRecordNum%></td>
</tr>
</table>
<% if sRecordNum>0 then %>
<TABLE ALIGN=center>
<TR>
<TD>
<input type="hidden" name="imgsub" value="订单确认">
<input type="button" name="gogook" value="订单确认" onclick="javascript:document.frmOrderList.imgsub.value='订单确认';document.frmOrderList.submit();"> </TD>
</TR>
</TABLE>
<% End if %>
</FORM>
</TD>
</TR>
</TABLE>
<BR>
<!--#include virtual="/inc/default_end.asp" -->
<BR>
</BODY>
</HTML>
<SCRIPT LANGUAGE=javascript>
<!--
function jumpto(a){
//a=document.frmjump.stp.value;
if(isNaN(a) || parseInt(a) != a || a<=0){
alert("请输入1到"+<%=sPageNum%>+"之间的正整数!");
document.frmjump.stp.value="";
return false;
}
if (a><%=sPageNum%>){
alert("您只能输入1到"+<%=sPageNum%>+"之间的正整数!");
document.frmjump.stp.value="";
return false;
}
}
function openpage(b){
document.frmjump.stp.value=b;
document.frmjump.submit();
}
//-->
</SCRIPT>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -