久久福利影视-久久成人综合网-久久成人亚洲-久久成人性色生活片-免费的黄色小视频-免费的黄视频

歡迎來到安信科技官方網站!【www.www122sihucom3.cn】
18112005550
工作時間: 8:30-21:30
新聞中心
News Center

【解決方案】安信多用戶商城按日期導出訂單的實現代碼

資訊分類: 二次開發  瀏覽: 2015年11月26日

1.表單提交文件的寫法:anxinMall.ordertoExcel.asp

 <!--#include file="common.asp"-->

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>訂單導入報表Excel</title>
<style type="text/css">
<!--
body,td,th {
font-size: 12px;
}
-->
</style></head>
 
<body>
<form action="dingdanExcel.asp" method="get" name="form1" target="_blank">
<br>
  <table width="680" height="360" border="0" align="center">
    <tr>
      <td>
        <fieldset style="border : 1px solid #217fbb;">
        <legend>訂單導入報表Excel</legend>
<br><br><br>
        <table width="400" border="0" align="center">
 <tr>
            <td width="158" height="13" align="right">選擇導出日期:</td>
            <td width="232">
<select name="riqi" style="position:relative;left:0px;top:0px;font-size:14px;width:120px;line-height:14px;border:#ccc solid 1px;">
<base target=Right>
<option value="0">請選擇日期</option>
<%
set rs=anxinMall.db("select distinct(format(addtime,'yyyy-mm-dd')) as temp from [anxinMall_dingdan] order by format(addtime,'yyyy-mm-dd') desc",3)
do while not rs.eof
response.write"<option value='"&rs("temp")&"'>"&rs("temp")&"</option>"
rs.movenext
loop
rs.close
set rs=nothing
%>
</select>
</td>
 </tr>
 
          <tr align="center">
            <td height="54" colspan="2"><input type="submit" name="Submit" value="導出Excel">
                         </td>
          </tr>
        </table>
<br><br><br>
      </fieldset></td>
    </tr>
  </table>
</form>
</body>
</html>
 
2.訂單下載頁的寫法:訂單.asp
 
<%
 
function getDingdanZongerByid(dingdanhao)'根據訂單dingdanhao獲得訂單總額
getDingdanZongerByid = anxinMall.db("select sum(zonger) from [anxinMall_dingdan_prodlist] where dingdanhao='"&dingdanhao&"'",2)(0)
end function
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>無標題文檔</title>
<style type="text/css">
<!--
body,td,th {
font-size: 12px;
}
-->
</style></head>
 
<body>
<%response.ContentType="application/vnd.ms-excel"%>
<table width="" height="41" border="1" align="center">
<tr>
<td width="60" height="28" align="center"><span class="style4">日期</span></td><!-- addtime -->
<td width="150" height="28" align="center"><span class="style4">訂單號</span></td><!-- dingdanhao -->
<td width="140" height="28" align="center"><span class="style4">訂單金額</span></td><!-- getDingdanZongerByid(dingdanhao) -->
<td width="100" height="28" align="center"><span class="style4">訂單狀態</span></td><!-- zhuangtai -->
</tr>
<%
dim riqi : riqi =request("riqi")
if request("riqi")=0 then
call anxinMall.alert("請選擇導出日期","back")
end if
set rs=anxinMall.db("select * from [anxinMall_dingdan] where addtime=#"&riqi&"#",3)
do while not rs.eof
%>
<tr>
<td height="28" align="center"><span class="style4"><%=rs("addtime")%></span></td><!-- userid -->
<td height="28" align="center"><span class="style4">'<%=rs("dingdanhao")%></span></td><!-- 訂單號 -->
<td height="28" align="center"><span class="style4"><%=getDingdanZongerByid(rs("dingdanhao"))%></span></td><!-- 訂單總額 -->
<td height="28" align="center"><span class="style4"><%select case rs("zhuangtai")
case 1:response.write"未作任何處理"
case 2:response.write"買家已經付款"
case 3:response.write"商家已確認收款"
case 4:response.write"商家已經發貨"
case 5:response.write"<font color=#008750>買家已收到貨</font>"
end select%></span></td><!-- zhuangtai -->
</tr>
<%
rs.movenext
loop
rs.close
set rs=nothing
conn.close
set conn=nothing
%>
</table>
</body>
</html>
 

 

Copyright © 2007-2022 安信科技(十五周年紀念版) All Rights Reserved  備案號:蘇ICP備15047094號-3 
網站首頁 |  新聞資訊 |  服務項目 |  軟件產品 |  試用下載 |  需求提交 |  模版建站 |  關于安信 |  產品授權 |  聯系我們 |  定制開發 | 
服務熱線:181-1200-5550  客服QQ: 120094883  | 郵箱:120094883#qq.com(#改@)