⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 user_payment.asp

📁 正版创力4.1SQL商业版!!!ASP版。
💻 ASP
字号:
<!--#include file="Inc/Const.asp"-->
<%
const PageSize=20
dim Action,PaymentID,SearchType,Field,Keyword
Action		= Trim(request("Action"))
PaymentID	= Trim(request("PaymentID"))
CurrentPage	= Cl.GetClng(request("page"))
SearchType	= Cl.GetClng(request("SearchType"))
Field		= Trim(request("Field"))
Keyword		= Trim(request("Keyword"))
FileName	= "User_Payment.asp"
Header
%>
<script language="JavaScript" type="text/javascript">
function unselectall(){
    if(document.myform.chkAll.checked){
 document.myform.chkAll.checked = document.myform.chkAll.checked&0;
    }
}
function CheckAll(form){
  for (var i=0;i<form.elements.length;i++){
    var e = form.elements[i];
    if (e.name != 'chkAll'&&e.disabled==false)
       e.checked = form.chkAll.checked;
    }
  }
function ConfirmDel(){
 if(document.myform.Action.value=='Del'){
     if(confirm('确定要删除选中的在线支付记录吗?'))
         return true;
     else
         return false;
 }
}
</script>
<table width="100%" border="0" align="center" cellpadding="2" cellspacing="1" class="border">  
	<tr class="title">     
	<td height="22" colspan="2" align="center"><b>在 线 支 付 记 录 查 询</b></td>  
	</tr>    
  <tr class="tdbg" height="30">
	<form action="User_Payment.asp" method="get" name="form1" id="form1">
	<td>快速查找:
	<select size="1" name="SearchType" id="SearchType" onChange="javascript:submit()">
	<option value="1" selected="selected">所有在线支付记录</option>
	<option value="2">今 天 的支付记录</option>
	<option value="3">本 周 的支付记录</option>
	<option value="4">本 月 的支付记录</option>
	<option value="5">三个月内的支付记录</option>
	<option value="6">支 付 失败的记录</option>
	<option value="7">支 付 成功的记录</option>
	</select>&nbsp;&nbsp;&nbsp;&nbsp;<a href="User_Payment.asp">在线支付记录首页</a></td>
	</form>
	<form action="User_Payment.asp" method="post" name="form2" id="form2">
	<td>高级查询:
	<select name="Field" id="Field">
	<option value="PaymentID">支付ID</option>
	<option value="PaymentNum" selected="selected">支付编号</option>
	</select>
	<input name="Keyword" type="text" id="Keyword" size="20" maxlength="30" />
	<input type="submit" name="Submit2" value=" 查 询 " />
	<input name="SearchType" type="hidden" id="SearchType" value="8" /> 
	</td>
	</form>
</tr>
</table>
<script language="JavaScript" type="text/javascript">
CheckSel('SearchType','<%=SearchType%>');
</script>
<br />
<%
Main()
%>
<P>&nbsp;&nbsp;<b><font color="blue">支付成功说明:</font></b>
①--常规支付接口处理的结果,
②--自动对账接口处理的结果,
③--手动设置成功处理的结果。
<%
Footer

Sub Main()
	SQL="Select PaymentID,UserID,UserName,OrderID,PaymentNum,eBankID,PayMoney,TrueMoney,PayTime,Status,eBankInfo,Remark from Cl_Payment where UserID="&Cl.UserID&" "
	Select Case SearchType
	Case 0,1
		SQL=SQL & " order by PaymentID Desc"
	Case 2
		If IsSqlDataBase=1 Then
			SQL=SQL & " and datediff(d,PayTime," & SqlNowString & ")<1 order by PaymentID Desc"
		else
			SQL=SQL & " and datediff('d',PayTime," & SqlNowString & ")<1 order by PaymentID Desc"
		end if
	Case 3
		If IsSqlDataBase=1 Then
			SQL=SQL & " and datediff(week,PayTime," & SqlNowString & ")<1 order by PaymentID Desc"
		else
			SQL=SQL & " and datediff('w',PayTime," & SqlNowString & ")<1 order by PaymentID Desc"
		end if
	Case 4
		If IsSqlDataBase=1 Then
			SQL=SQL & " and datediff(month,PayTime," & SqlNowString & ")<1 order by PaymentID Desc"
		else
			SQL=SQL & " and datediff('m',PayTime," & SqlNowString & ")<1 order by PaymentID Desc"
		end if
	Case 5
		If IsSqlDataBase=1 Then
			SQL=SQL & " and datediff(month,PayTime," & SqlNowString & ")<3 order by PaymentID Desc"
		else
			SQL=SQL & " and datediff('m',PayTime," & SqlNowString & ")<3 order by PaymentID Desc"
		end if
	Case 6
		SQL=SQL & " and Status=0 order by PaymentID Desc"
	Case 7
		SQL=SQL & " and Status=1 order by PaymentID Desc"
	Case 8
		If Keyword="" Then
			Cl.ShowErr("错误,关键字不能为空!")
		End if
		Keyword=Cl.ReplaceBadChar(Keyword)
		SQL=SQL & " and "
		Select Case Field
		Case "PaymentID"
			SQL=SQL & "PaymentID="&Cl.GetClng(Keyword)&" "
		Case "PaymentNum"
			SQL=SQL & "PaymentNum Like '%"&Keyword&"%' "
		Case Else
			SQL=SQL & "PaymentNum Like '%"&Keyword&"%' "
		End Select
		SQL=SQL & " Order by PaymentID Desc"
	Case Else
		SQL=SQL & " Order by PaymentID Desc"
	End Select
	Set rs= Server.CreateObject("ADODB.Recordset")
	OpenConn : rs.open sql,Conn,1,1
	if rs.eof and rs.bof then
		TotalPut=0
		response.write "<p align='center'><br />暂时没有在线支付记录!<br /></p>"
		rs.close:set rs=Nothing:Exit Sub
	End if
   	TotalPut=rs.recordcount
   	if (TotalPut mod PageSize)=0 then
    	TotalPages = TotalPut \ PageSize
	else
	  	TotalPages = TotalPut \ PageSize + 1
	end if
	if CurrentPage > TotalPages then CurrentPage=TotalPages
	if CurrentPage < 1 then CurrentPage=1
   	rs.move (CurrentPage-1)*PageSize
	SQL = rs.GetRows(PageSize)
	rs.close:set rs=Nothing
	%>
<table width="100%" border="0" cellpadding="2" cellspacing="1" class="border" align="center">
	<tr align="center" class="title">
		<td width="80">支付序号</td>
		<td width="60">用户姓名</td>
		<td width="70">支付平台</td>
		<td width="120">交易时间</td>
		<td width="80">汇款金额</td>
		<td width="80">实际金额</td>
		<td width="60">交易状态</td>
		<td width="70">银行信息</td>
		<td>备注</td>
	</tr>
	<%
    For i=0 to Ubound(SQL,2)
	%>
	<tr class="tdbg" onmouseout="this.classname='tdbg'" onmouseover="this.classname='tdbg2'">
		<td width="80" align="center"><%=SQL(4,i)%></td>
		<td width="60" align="center"><%=SQL(2,i)%></td>
		<td width="70" align="center">网银在线</td>
		<td width="120" align="center"><%=SQL(8,i)%></td>
		<td width="80" align="right"><%=Cl.FormatNum(SQL(6,i),2)%></td>
		<td width="80" align="right"><%=Cl.FormatNum(SQL(7,i),2)%></td>
		<td width="60" align="center"><%
	if SQL(9,i)=1 then
		response.write "<font color=blue>支付成功</font>"
	else
		response.write "<font color=red>支付失败</font>"
	end if
	%></td>
		<td width="80" align="center"><%=SQL(10,i)%></td>
		<td><%=SQL(11,i)%></td>
	</tr>
	<%
        'Select Case RsPayment("eBankID")
        'Case 1
        '    Response.Write "网银在线"
        'Case else
        '    Response.Write "网银在线"
        'End Select
	Next
	%>
    </table>
	<%=Cl.ShowPage(FileName,TotalPut,PageSize,"条","记录")%>
	<%
End Sub
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -