Upload cashier.php
Browse files
26913352-632f-4dfc-bc33-14b5a4e592c0_clha5mng.php
ADDED
|
@@ -0,0 +1,132 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
$is_defend = true;
|
| 3 |
+
$nosession = true;
|
| 4 |
+
require './includes/common.php';
|
| 5 |
+
|
| 6 |
+
@header('Content-Type: text/html; charset=UTF-8');
|
| 7 |
+
|
| 8 |
+
$other=isset($_GET['other'])?true:false;
|
| 9 |
+
$trade_no=daddslashes($_GET['trade_no']);
|
| 10 |
+
$sitename=base64_decode(daddslashes($_GET['sitename']));
|
| 11 |
+
$row=$DB->getRow("SELECT * FROM pre_order WHERE trade_no='{$trade_no}' limit 1");
|
| 12 |
+
if(!$row)sysmsg('该订单号不存在,请返回来源地重新发起请求!');
|
| 13 |
+
if($row['status']==1)sysmsg('该订单已完成支付,请勿重复支付');
|
| 14 |
+
$gid = $DB->getColumn("SELECT gid FROM pre_user WHERE uid='{$row['uid']}' limit 1");
|
| 15 |
+
$paytype = \lib\Channel::getTypes($row['uid'], $gid);
|
| 16 |
+
|
| 17 |
+
if(strpos($_SERVER['HTTP_USER_AGENT'], 'MicroMessenger')!==false){
|
| 18 |
+
$paytype = array_values($paytype);
|
| 19 |
+
foreach($paytype as $i=>$s){
|
| 20 |
+
if($s['name']=='wxpay'){
|
| 21 |
+
$temp = $paytype[$i];
|
| 22 |
+
$paytype[$i] = $paytype[0];
|
| 23 |
+
$paytype[0] = $temp;
|
| 24 |
+
}
|
| 25 |
+
}
|
| 26 |
+
}
|
| 27 |
+
?>
|
| 28 |
+
<!DOCTYPE html>
|
| 29 |
+
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
| 30 |
+
<meta content="width=device-width, initial-scale=1, maximum-scale=1.0, user-scalable=0" name="viewport">
|
| 31 |
+
<title>收银台 | <?php echo $sitename?$sitename:$conf['sitename']?> </title>
|
| 32 |
+
<link href="/assets/css/reset.css" rel="stylesheet" type="text/css">
|
| 33 |
+
<link href="/assets/css/main12.css?v=2" rel="stylesheet" type="text/css">
|
| 34 |
+
</head>
|
| 35 |
+
<body style="background-color:#f9f9f9">
|
| 36 |
+
<!--导航-->
|
| 37 |
+
<div class="w100 navBD12">
|
| 38 |
+
<div class="w1080 nav12">
|
| 39 |
+
<div class="nav12-left">
|
| 40 |
+
<img src="/assets/img/logo.png">
|
| 41 |
+
</div>
|
| 42 |
+
<div class="nav12-right">
|
| 43 |
+
收银台
|
| 44 |
+
</div>
|
| 45 |
+
|
| 46 |
+
</div>
|
| 47 |
+
</div>
|
| 48 |
+
<input type="hidden" name="trade_no" value="<?php echo $trade_no?>"/>
|
| 49 |
+
<!--订单金额-->
|
| 50 |
+
<?php if($other){?>
|
| 51 |
+
<div class="w1080 order-amount12" style="height: auto;">
|
| 52 |
+
<h2><font style="color: red">当前支付方式暂时关闭维护,请更换其他方式支付</font></h2>
|
| 53 |
+
</div>
|
| 54 |
+
<div class="w1080 order-amount12" style="height: auto;">
|
| 55 |
+
<h2 style="font-size:18px"><font style="color: green">如果您需要微信支付请将微信余额转到QQ再选择QQ钱包支付!</font></h2>
|
| 56 |
+
<h3><a href="./wx.html" style="font-size:20px;color:blue">点击查看微信余额转到QQ钱包教程</a></h3>
|
| 57 |
+
</div>
|
| 58 |
+
<?php }else{?>
|
| 59 |
+
<div class="w1080 order-amount12">
|
| 60 |
+
<ul class="order-amount12-left">
|
| 61 |
+
<li>
|
| 62 |
+
<span>商品名称:</span>
|
| 63 |
+
<span><?php echo $row['name']?></span>
|
| 64 |
+
</li>
|
| 65 |
+
<li>
|
| 66 |
+
<span>订单号:</span>
|
| 67 |
+
<span><?php echo $trade_no?></span>
|
| 68 |
+
</li>
|
| 69 |
+
<li>
|
| 70 |
+
<span>创建时间:</span>
|
| 71 |
+
<span><?php echo $row['addtime']?></span>
|
| 72 |
+
</li>
|
| 73 |
+
</ul>
|
| 74 |
+
<div class="order-amount12-right">
|
| 75 |
+
<span>订单金额:</span>
|
| 76 |
+
<strong><?php echo $row['money']?></strong>
|
| 77 |
+
<span>元</span>
|
| 78 |
+
</div>
|
| 79 |
+
</div>
|
| 80 |
+
<?php }?>
|
| 81 |
+
<!--支付方式-->
|
| 82 |
+
<div class="w1080 PayMethod12">
|
| 83 |
+
<div class="row">
|
| 84 |
+
<h2>支付方式</h2>
|
| 85 |
+
<ul class="types">
|
| 86 |
+
<?php foreach($paytype as $rows){?>
|
| 87 |
+
<li class="pay_li" value="<?php echo $rows['id']?>">
|
| 88 |
+
<img src="/assets/icon/<?php echo $rows['name']?>.ico">
|
| 89 |
+
<span><?php echo $rows['showname']?></span>
|
| 90 |
+
</li>
|
| 91 |
+
<?php }?>
|
| 92 |
+
</ul>
|
| 93 |
+
</div>
|
| 94 |
+
</div>
|
| 95 |
+
<!--立即支付-->
|
| 96 |
+
<div class="w1080 immediate-pay12">
|
| 97 |
+
<div class="immediate-pay12-right">
|
| 98 |
+
<span>需支付:<strong><?php echo $row['realmoney']?$row['realmoney']:$row['money']?></strong>元<?php if($row['realmoney'] && $row['realmoney']!=$row['money'])echo '(包含'.($row['realmoney']-$row['money']).'元手续费)';?></span>
|
| 99 |
+
<a class="immediate_pay">立即支付</a>
|
| 100 |
+
</div>
|
| 101 |
+
</div>
|
| 102 |
+
<div class="mt_agree">
|
| 103 |
+
<div class="mt_agree_main">
|
| 104 |
+
<h2>提示信息</h2>
|
| 105 |
+
<p id="errorContent" style="text-align:center;line-height:36px;"></p>
|
| 106 |
+
<a class="close_btn">确定</a>
|
| 107 |
+
</div>
|
| 108 |
+
</div>
|
| 109 |
+
<!--底部-->
|
| 110 |
+
<div class="w1080 footer12">
|
| 111 |
+
<p> <?php echo $sitename?$sitename:$conf['sitename']?></p>
|
| 112 |
+
</div>
|
| 113 |
+
|
| 114 |
+
<script src="<?php echo $cdnpublic?>jquery/1.12.4/jquery.min.js"></script>
|
| 115 |
+
<script type="text/javascript">
|
| 116 |
+
$(document).ready(function(){
|
| 117 |
+
$(".types li").click(function(){
|
| 118 |
+
$(".types li").each(function(){
|
| 119 |
+
$(this).attr('class','');
|
| 120 |
+
});
|
| 121 |
+
$(this).attr('class','active');
|
| 122 |
+
});
|
| 123 |
+
$(document).on("click", ".immediate_pay", function () {
|
| 124 |
+
var value = $(".types").find('.active').attr('value');
|
| 125 |
+
var trade_no = $("input[name='trade_no']").val();
|
| 126 |
+
window.location.href='./submit2.php?typeid='+value+'&trade_no='+trade_no;
|
| 127 |
+
});
|
| 128 |
+
$(".types li:first").click();
|
| 129 |
+
})
|
| 130 |
+
</script>
|
| 131 |
+
</body>
|
| 132 |
+
</html>
|