fix h5 redirect url encode

master
luoyang 5 years ago
parent 1a3fa95ddd
commit ce9582ea52

@ -8,6 +8,8 @@ $(function () {
} else {
location.href = window.target_href;
}
decode();
$('.close-weixin-tip').bind('touchstart', function () {
$(".weixin-tip").hide();
checkOrderStd(window.client_moniker, window.partner_order_id, true);
@ -19,6 +21,17 @@ $(function () {
location.href = window.target_href;
});
function decode() {
var redirect = window.redirect;
while (redirect.indexOf('://') < 0) {
redirect = decodeURIComponent(redirect);
if (redirect == window.redirect) {
break;
}
window.redirect = redirect;
}
}
function checkOrderStd(clientMoniker, merchantOrderId, needLoop) {
if (!clientMoniker || !merchantOrderId) {
return;

Loading…
Cancel
Save