?? excel.asp
字號:
<% Option Explicit %>
<%
server.ScriptTimeOut=900
response.contentType="application/vnd.ms-excel"%>
<%
'-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
' 功能:訂單處理提交頁
' OriAuthor: 鄧健
' @Language=VBscript
' Create: 2002-10-10
' Modify:
'-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
%>
<!--#include file="_ccwlib/orderform_lib.asp"-->
<%
Dim RS,Sql,sAdminid,sunGrade,prors,receiverRS,subrs
Dim sStartPage,sPageNum,sRecordNum,i,sOrderid,sim
Dim sorderlimtnum,sordernownum,MSG,orderUserGrade
orderUserGrade=false
DB_Connect(strconn)
'獲得管理員在訂單管理子系統中的權限
sOrderid=getForm("orderid")
sim=getForm("im")
sStartPage=request("stp")
Set RS=oConn.Execute("select * from order_detail_view where odr_id="&sOrderid)
if rs.eof and rs.bof then
rs.close
response.redirect("index.asp")
response.end
elseif not rs.eof and not rs.bof then
%>
<%
set prors=oConn.execute("select * from orderproduct where odr_id="&sOrderid)
if not prors.eof and not prors.bof then%>
<TABLE CELLSPACING=1 CELLPADDING=1 BORDER=1 WIDTH=600>
<TR BGCOLOR=#558BFF>
<TD ALIGN=center CLASS=txt width="7%"><FONT COLOR=#ffffff>序號</FONT></TD>
<TD ALIGN=center CLASS=txt width="21%"><FONT COLOR=#ffffff>訂購物品名稱</FONT></TD>
<TD ALIGN=center CLASS=txt width="15%"><FONT COLOR=#ffffff>訂購數量</FONT></TD>
<TD ALIGN=center CLASS=txt width="13%"><font color="#FFFFFF">發送次數</font></TD>
<TD ALIGN=center CLASS=txt width="13%"><font color="#FFFFFF">實際發送量</font></TD>
<TD ALIGN=center CLASS=txt width="12%"><font color=#ffffff>訂購線</font></TD>
<TD ALIGN=center CLASS=txt width="19%"><FONT COLOR=#ffffff>庫存剩余</FONT></TD>
</TR>
<%
i=1
do while not prors.eof
set subrs=oConn.execute("select Ste_nownum,Ste_orderlimit from storeproduct where ste_id="&prors("ste_id"))
if not subrs.eof and not subrs.bof then
sorderlimtnum=subrs(1)
sordernownum=subrs(0)
else
sorderlimtnum="物品已刪除"
sordernownum="物品已刪除"
end if
subrs.close
%>
<TR BGCOLOR=#E1E1E1>
<TD ALIGN=center CLASS=txt width="7%"><% response.write i%></TD>
<TD ALIGN=center CLASS=txt width="21%"><% response.write prors("ste_name")%></TD>
<TD ALIGN=center CLASS=txt width="15%"><% response.write prors("List_num")%></TD>
<TD ALIGN=center CLASS=txt width="13%"><% response.write rs("ordrr_sendnum")%></TD>
<TD ALIGN=center CLASS=txt width="13%"><%response.write cint( prors("List_num"))*cint( rs("ordrr_sendnum"))%></TD>
<TD ALIGN=center CLASS=txt width="12%"><% response.write sorderlimtnum%></TD>
<TD ALIGN=center CLASS=txt width="19%"><%response.write sordernownum%></TD>
</TR>
<%
prors.movenext
i=i+1
loop
prors.close %>
</TABLE>
<% end if %>
<TABLE WIDTH=600 BORDER=1 cellspacing="0" cellpadding="3" bordercolordark="#ffffff" bordercolorlight="#666666">
<TR>
<TD ALIGN=right CLASS=txt width="400" bgcolor="#558BFF" colspan=2 align="center"><font color="#ffffff">訂單人信息</font></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" height="20" bgcolor="#E1E1E1" ><font color="#000000">訂單號:</font></TD>
<TD width="77%" height="20" align="left"><%response.write RS("Odr_no")%></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" height="20" bgcolor="#E1E1E1"><font color="#000000">訂單日期:</font></TD>
<TD width="77%" height="20" align="left"><%response.write RS("Odr_time")%></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="" bgcolor="#E1E1E1"><font color="#000000">訂單人真實姓名:</font></TD>
<TD width="77%"><%response.write RS("Usr_realname")%></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" height="20" bgcolor="#E1E1E1"><font color="#000000">訂單用戶名:</font></TD>
<TD width="77%" height="20"><%response.write RS("Usr_name")%></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" height="20" bgcolor="#E1E1E1"><font color="#000000">訂單用戶公司:</font></TD>
<TD width="77%" height="20"><%response.write RS("Usr_company")%></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" height="20" bgcolor="#E1E1E1"><font color="#000000">訂單用戶電話:</font></TD>
<TD width="77%" height="20" align="left"><%response.write RS("Usr_tel")%></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" bgcolor="#E1E1E1"><font color="#000000">用戶名Email:</font></TD>
<TD width="77%"><%response.write RS("Usr_email")%></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" bgcolor="#E1E1E1"><font color="#000000">是否多人發送:</font></TD>
<TD width="77%">
<% if RS("Odr_mul")="y" then response.write "是" %>
<% if RS("Odr_mul")<>"y" then response.write "否" %></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" bgcolor="#E1E1E1"><font color="#000000">訂單發送次數:</font></TD>
<TD width="77%" align="left"><%response.write RS("ordrr_sendnum")%></TD>
</TR>
<TR>
<TD ALIGN=right CLASS=txt width="23%" bgcolor="#E1E1E1"><font color="#000000">訂單發送狀態:</font></TD>
<TD width="77%"><% select case cint(RS("Odr_sendstate"))
Case 1 response.write "全部"
Case 2 response.write "部分"
Case 3 response.write "未發送"
case else response.write "未知"
End select %></TD>
</TR>
</TABLE>
<%
End if
rs.close
%>
<%
Set RS=oConn.Execute("select * from orderreceiverdetail where odr_id="&sOrderid)
if not rs.eof and not rs.bof then
%>
<table width=600 border=1 cellspacing=1 cellpadding=5>
<tr bgcolor="#558BFF" valign="middle">
<td class=ttable width="100" nowrap align="center"><FONT COLOR="#ffffff">接收人</FONT></td>
<td class=ttable align=center width="300" nowrap><FONT COLOR="#ffffff">接收地址</FONT></td>
<td class=ttable align=center width="200" nowrap><FONT COLOR="#ffffff">接收郵編</FONT></td>
</tr>
<% do while not rs.eof %>
<tr>
<td class=ko width="11%" nowrap bgcolor="#e1e1e1"><%response.write RS("odrr_name")%></td>
<td class=ko align=center nowrap width="30%" bgcolor="#e1e1e1"><%response.write RS("odrr_add")%></td>
<td class=ko align=center nowrap width="13%" bgcolor="#e1e1e1"><%response.write RS("odrr_zip")%></td>
</tr>
<%
rs.movenext
loop
%>
</table>
</TD>
</TR>
</TABLE>
<%end if %>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -