|
|
<!DOCTYPE HTML>
|
|
|
<html xmlns:th="http://www.thymeleaf.org" lang="zh">
|
|
|
<head>
|
|
|
<meta charset="UTF-8">
|
|
|
<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=0">
|
|
|
<meta http-equiv="cache-control" content="max-age=0">
|
|
|
<meta http-equiv="cache-control" content="no-cache">
|
|
|
<meta http-equiv="expires" content="0">
|
|
|
<meta http-equiv="expires" content="Tue, 01 Jan 1980 1:00:00 GMT">
|
|
|
<meta http-equiv="pragma" content="no-cache">
|
|
|
<title>RoyalPay红包返现福利</title>
|
|
|
<script type="text/javascript" src="/static/lib/jquery/jquery-2.1.4.min.js"></script>
|
|
|
<script type="text/javascript" src="//res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
|
|
|
<link rel="stylesheet" href="/static/lib/weui/weui.min.css">
|
|
|
<script type="text/javascript" src="/static/templates/disable_wechat_menu.js?t=201612160231"></script>
|
|
|
<style type="text/css">
|
|
|
|
|
|
.promotion_logo {
|
|
|
background-image: url("/static/images/promotion_logo.png");
|
|
|
background-repeat: no-repeat;
|
|
|
background-size: 100%;
|
|
|
}
|
|
|
|
|
|
.pclass {
|
|
|
width: 60%;
|
|
|
border-radius: 20px;
|
|
|
height: 35px;
|
|
|
font-size: 14px;
|
|
|
}
|
|
|
</style>
|
|
|
|
|
|
|
|
|
</head>
|
|
|
<body style="margin: 0;padding: 0;">
|
|
|
<div id="wdiv" class="weui_loading_toast" style="display:none;">
|
|
|
<div class="weui_mask_transparent"></div>
|
|
|
<div class="weui_toast">
|
|
|
<div class="weui_loading">
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_0"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_1"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_2"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_3"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_4"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_5"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_6"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_7"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_8"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_9"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_10"></div>
|
|
|
<div class="weui_loading_leaf weui_loading_leaf_11"></div>
|
|
|
</div>
|
|
|
<p class="weui_toast_content"></p>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div style="text-align: center">
|
|
|
<img src="/static/images/promotion_head.png" style="width: 100%">
|
|
|
<div class="promotion_logo">
|
|
|
<img src="/static/images/promotion_s.png" style="padding-top: -10px;width: 100%;height: 60px">
|
|
|
</div>
|
|
|
<p style="font-size: 12px">推荐微信支付成功 微信福利红包返现</p>
|
|
|
<p style="color: #04be02;font-size: 14px"><span style="font-size: 18px">1RMB-188RMB</span>不等</p>
|
|
|
<p style="color: #04be02;font-size: 14px">敬请参与</p>
|
|
|
<img src="/static/images/promotion_s.png" style="width: 100%;height: 40px">
|
|
|
<p style="font-size: 12px">(每单消费需要满50澳币)</p>
|
|
|
<img src="/static/images/promotion_s.png" style="width: 100%;height: 30px">
|
|
|
<p style="font-size: 14px" id="client_name"></p>
|
|
|
<p style="padding-bottom: 5px"><input id="invitationCode" class="weui_btn weui_btn_default pclass" style="width: 60%;" placeholder="输入邀请码,参加返现"></input></p>
|
|
|
<p><a id="participate" class="weui_btn weui_btn_primary pclass" style="font-size: 16px">立刻参与</a></p>
|
|
|
<p><a id="haveParticipated" class="weui_btn weui_btn_primary" style="width: 60%;border-radius: 20px;display: none">报名成功</a>
|
|
|
</p>
|
|
|
<p style="font-size: 10px;padding-top: 5px"><a style="color:darkgrey;" href="https://www.royalpay.com.au">RoyalPay皇家支付</a>
|
|
|
</p>
|
|
|
</div>
|
|
|
</body>
|
|
|
<script type="text/javascript" data-th-inline="javascript">
|
|
|
window.clientMoniker = /*[[*{clientMoniker}]]*/null;
|
|
|
$(function () {
|
|
|
$('#participate').click(function () {
|
|
|
|
|
|
var invitationCode = $('#invitationCode')[0].value;
|
|
|
if (invitationCode.length==0){
|
|
|
alert("请先输入邀请码");
|
|
|
return;
|
|
|
}
|
|
|
var postData = {'invitationCode':invitationCode};
|
|
|
// var isParticipate = confirm("本微信账号将作为RoyalPay微信福利红包返现对象,是否确认绑定?");
|
|
|
// if (isParticipate) {
|
|
|
//
|
|
|
// }
|
|
|
$.ajax({
|
|
|
url: '/sys/lucky_money/partner/wechat/' + window.clientMoniker + '/2',
|
|
|
method: 'post',
|
|
|
data: JSON.stringify(postData),
|
|
|
dataType: 'json',
|
|
|
contentType: 'application/json',
|
|
|
success: function (resp) {
|
|
|
// $('#wdiv').hide();
|
|
|
alert("Success");
|
|
|
checkParticipateStatus();
|
|
|
},
|
|
|
error: function (jqXhr) {
|
|
|
alert(JSON.parse(jqXhr.responseText).message);
|
|
|
// $('#wdiv').hide();
|
|
|
}
|
|
|
})
|
|
|
});
|
|
|
var checkParticipateStatus = function () {
|
|
|
// $('#wdiv').show();
|
|
|
$.ajax({
|
|
|
url: '/partner/lucky_money/'+2+'/' + window.clientMoniker + '/partner_wechats',
|
|
|
method: 'get',
|
|
|
// data: JSON.stringify(data),
|
|
|
dataType: 'json',
|
|
|
contentType: 'application/json',
|
|
|
success: function (resp) {
|
|
|
$('#client_name')[0].innerHTML = resp.client_name;
|
|
|
//"status"-0:商户未被绑定,微信未参加过活动;1:商户已被绑定,存在bindInfo;2:商户未被绑定,但此微信已参加过活动;3:商户已被此微信绑定;
|
|
|
// $('#wdiv').hide();
|
|
|
if (resp.status == 0) {
|
|
|
}
|
|
|
if (resp.status == 1) {
|
|
|
$('#invitationCode').hide();
|
|
|
$('#participate').hide();
|
|
|
|
|
|
$('#haveParticipated').click(function () {
|
|
|
alert("如需修改红包返现人员,请登陆ROYALPAY商户后台修改");
|
|
|
});
|
|
|
|
|
|
$('#haveParticipated')[0].innerHTML = "<span style='font-size: 14px'>活动被</span> " + resp.bindInfo.nickname + " <span style='font-size: 14px'>抢先啦</span>";
|
|
|
$('#haveParticipated').show();
|
|
|
}
|
|
|
if (resp.status == 2) {
|
|
|
$('#invitationCode').hide();
|
|
|
$('#participate').hide();
|
|
|
$('#haveParticipated')[0].innerHTML = "你已参加过活动";
|
|
|
$('#haveParticipated').show();
|
|
|
}
|
|
|
if (resp.status == 3) {
|
|
|
$('#invitationCode').hide();
|
|
|
$('#participate').hide();
|
|
|
$('#haveParticipated').show();
|
|
|
}
|
|
|
},
|
|
|
error: function (jqXhr) {
|
|
|
$('#wdiv').hide();
|
|
|
alert(jqXhr.responseJSON.message);
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
var listLuckyMoney = function () {
|
|
|
$.ajax({
|
|
|
url: '/partner/lucky_money/2/logs/wechat',
|
|
|
method: 'get',
|
|
|
// data: JSON.stringify(data),
|
|
|
dataType: 'json',
|
|
|
contentType: 'application/json',
|
|
|
success: function (resp) {
|
|
|
if (resp.length > 0) {
|
|
|
}
|
|
|
},
|
|
|
error: function (jqXhr) {
|
|
|
alert(jqXhr.responseJSON.message);
|
|
|
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
checkParticipateStatus();
|
|
|
});
|
|
|
</script>
|
|
|
<script>
|
|
|
var _hmt = _hmt || [];
|
|
|
(function () {
|
|
|
var hm = document.createElement("script");
|
|
|
hm.src = "https://hm.baidu.com/hm.js?d7e727bd889ea69d369cba051844dfe5";
|
|
|
var s = document.getElementsByTagName("script")[0];
|
|
|
s.parentNode.insertBefore(hm, s);
|
|
|
})();
|
|
|
</script>
|
|
|
</html> |