@ -257,9 +257,9 @@
< span class = "add-game" game-id = "{$vo.id}" promote-type = "3" style = "cursor: pointer;margin-right: 10px;" > < u > 添加推广员游戏< / u > < / span >
< / if >
<?php $downloadUrl = get_apply_dow_url($vo['id'],$vo['promote_id']);?>
< span class = "game-link" data-qrcode = "{:U('Apply/qrcode',['url'=>base64_encode(base64_encode($downloadUrl)),'logo'=>$qrcode])}" data-url = "{$downloadUrl}" data- status= "{$vo.enable_status }" style = "cursor: pointer;margin-right: 10px;" > < u > 复制下载链接< / u > < / span >
< span class = "game-link" data-qrcode = "{:U('Apply/qrcode',['url'=>base64_encode(base64_encode($downloadUrl)),'logo'=>$qrcode])}" data-url = "{$downloadUrl}" data- apply-id= "{$vo.applyid }" style = "cursor: pointer;margin-right: 10px;" > < u > 复制下载链接< / u > < / span >
<?php $flooringPageUrl = 'http://'.C('APPLY_DOWN_DOMAIN').U('Home/promitionofregestion',array('gid'=>$vo['id'],'pid'=>$vo['promote_id']));?>
< span class = "game-link" data-qrcode = "{:U('Apply/qrcode',['url'=>base64_encode(base64_encode($flooringPageUrl)),'logo'=>$qrcode])}" data-url = "{$flooringPageUrl}" data- status= "{$vo.enable_status }" style = "cursor: pointer;margin-right: 10px;" > < u > 落地页链接< / u > < / span >
< span class = "game-link" data-qrcode = "{:U('Apply/qrcode',['url'=>base64_encode(base64_encode($flooringPageUrl)),'logo'=>$qrcode])}" data-url = "{$flooringPageUrl}" data- apply-id= "{$vo.applyid }" style = "cursor: pointer;margin-right: 10px;" > < u > 落地页链接< / u > < / span >
< span class = "down-game-btn" data-id = "{$vo.id}" style = "cursor: pointer;margin-right: 10px;color: #999" > < u > 下架< / u > < / span >
< / div >
< / div >
@ -974,9 +974,33 @@
$('.game-link').on('click', function () {
var url = $(this).attr('data-url');
var qrcode = $(this).attr('data-qrcode');
var enableStatus = parseInt($(this).attr('data-status '));
var applyId = parseInt($(this).attr('data-apply-id '));
if (enableStatus != 1) {
$.ajax({
type: "post",
url: "__URL__/getEnableStatus",
dataType: "json",
data: {'apply_id': applyId},
success: function (data) {
console.log(data);
if (data.status == 0) {
layer.msg(data.msg, {icon: 5});
return false;
}
var enableStatus = parseInt(data.data);
if (enableStatus == 1) {
// $('#download_copy').attr('data-url',url);
$('#game_link_ercode').attr('src',qrcode);
$('#game_link_address').text(url);
$('#game_link_address_copy').text(url);
$('#game_link').show();
$('.game-window-bg').show();
var e = document.getElementById("game_link_address_copy");
e.select(); // 选择对象
document.execCommand("Copy"); // 执行浏览器复制命令
} else {
var iconIndex = 7;
var enableStatusName = '';
@ -997,17 +1021,11 @@
layer.alert(enableStatusName, {icon: iconIndex});
return false;
}
// $('#download_copy').attr('data-url',url);
$('#game_link_ercode').attr('src',qrcode);
$('#game_link_address').text(url);
$('#game_link_address_copy').text(url);
$('#game_link').show();
$('.game-window-bg').show();
var e = document.getElementById("game_link_address_copy");
e.select(); // 选择对象
document.execCommand("Copy"); // 执行浏览器复制命令
},
error: function (result) {
layer.msg('网络异常', {icon: 5});
}
});
});
// $("#download_copy").zclip({