Merge branch 'dev' of 47.111.118.107:/srv/git/platform into dev

master
chenzhi 5 years ago
commit b93b2c59ce

@ -103,7 +103,7 @@ class AjaxController extends ThinkController{
}
public function getUserPlayGameName($user_id=0){
$map['user_id'] = $user_id;
$map['user_account'] = $user_id;
$data = M("UserPlay","tab_")->field("game_id,game_name,bind_balance")->where($map)->group('user_id,game_id')->select();
$this->AjaxReturn($data);
}

@ -129,8 +129,28 @@ class ConsoleController extends Think {
public function deleteRepeatUserPlayInfo()
{
/* INSERT INTO `tab_server`(`game_id`, `game_name`, `server_name`, `server_num`, `recommend_status`, `show_status`, `stop_status`, `server_status`, `icon`, `start_time`, `desride`, `prompt`, `parent_id`, `create_time`, `server_version`, `developers`, `server_id`) VALUES
(148, '王者纷争(安卓版)', 'O3-潜龙于渊', 3294, 1, 1, 0, 0, NULL, 1571399818, NULL, NULL, NULL, 1571399818, 1, 0, '3294'),
(148, '王者纷争(安卓版)', 'O4-攻心为上', 3301, 1, 1, 0, 0, NULL, 1571399818, NULL, NULL, NULL, 1571399818, 1, 0, '3301'),
(148, '王者纷争(安卓版)', 'O5-知人善用', 3311, 1, 1, 0, 0, NULL, 1571399818, NULL, NULL, NULL, 1571399818, 1, 0, '3311'),
(148, '王者纷争(安卓版)', 'O8-剑拔弩张', 3332, 1, 1, 0, 0, NULL, 1571399818, NULL, NULL, NULL, 1571399818, 1, 0, '3332'),
(148, '王者纷争(安卓版)', 'O12-七擒七纵', 3336, 1, 1, 0, 0, NULL, 1571399818, NULL, NULL, NULL, 1571399818, 1, 0, '3336'),
(148, '王者纷争(安卓版)', 'O15-遮空蔽日', 3375, 1, 1, 0, 0, NULL, 1571399818, NULL, NULL, NULL, 1571399818, 1, 0, '3375'); */
// $gameId = 157;
// $gameId = 155;
// $gameId = 153;
// $gameId = 150;
// $gameId = 151;
// 需要先执行上面sql插入区服才能清理干净
// $gameId = 148;
// $gameId = 175;
// $gameId = 142;
// $gameId = 143;
// $gameId = 172;
// $gameId = 173;
// $gameId = 155;
// $gameId = 154;
$gameId = 153;
$sql = 'select id from tab_user_play_info a left join (
select role_id, server_id, game_id, count(1) from tab_user_play_info where server_id="' . $serverId . '" and game_id = ' . $gameId . ' GROUP BY role_id, server_id, game_id, server_name having count(1) > 1
@ -175,4 +195,68 @@ class ConsoleController extends Think {
}
}
}
public function deleteRepeatUserPlayInfo2()
{
// $gameId = 157;
// $gameId = 148;
// $gameId = 150;
// $gameId = 151;
// $gameId = 158;
// $gameId = 175;
// $gameId = 142;
// $gameId = 143;
// $gameId = 172;
// $gameId = 173;
// $gameId = 154;
// $gameId = 155;
// $gameId = 176;
// $gameId = 165;
// $gameId = 164;
// $gameId = 179;
// $gameId = 156;
$gameId = 153;
$sql = 'select id from tab_user_play_info a left join (
select role_id, server_id, game_id, count(1) from tab_user_play_info where server_id="' . $serverId . '" and game_id = ' . $gameId . ' GROUP BY role_id, server_id, game_id, server_name having count(1) > 1
) b on a.role_id=b.role_id where a.server_id=b.server_id and a.game_id=b.game_id and a.server_id="' . $serverId . '" and a.game_id = ' . $gameId . ' order by a.role_id, a.server_id, a.game_id';
$model = new \Think\Model();
$servers = M('server', 'tab_')->field('server_id')->where(['game_id' => $gameId])->group('server_id')->select();
foreach ($servers as $server) {
$serverId = $server['server_id'];
$sql = 'select a.id, a.role_id, a.server_id, a.game_id, a.role_level from tab_user_play_info a left join (
select role_id, server_id, game_id, count(1) from tab_user_play_info where server_id="' . $serverId . '" and game_id = ' . $gameId . ' GROUP BY role_id, server_id, game_id having count(1) > 1
) b on a.role_id=b.role_id where a.server_id=b.server_id and a.game_id=b.game_id and a.server_id="' . $serverId . '" and a.game_id = ' . $gameId . ' order by a.role_id, a.server_id, a.game_id';
// var_dump($sql);
$result = $model->query($sql);
$uniqueRole = null;
$items = [];
foreach ($result as $item) {
$items[$item['role_id']][] = $item;
}
$maxRoleIds = [];
$repeatIds = [];
foreach ($items as $roles) {
$maxRole = null;
foreach ($roles as $role) {
if ($maxRole == null) {
$maxRole = $role;
} elseif ($role['role_level'] >= $maxRole['role_level']) {
$repeatIds[] = $maxRole['id'];
$maxRole = $role;
} else {
$repeatIds[] = $role['id'];
}
}
$maxRoleIds[] = $maxRole['id'];
}
if (count($repeatIds) > 0) {
M('user_play_info', 'tab_')->where(['id' => ['in', $repeatIds], 'game_id' => $gameId, 'server_id' => $serverId])->delete();
echo M()->getLastSql();
echo PHP_EOL;
}
}
}
}

@ -831,12 +831,16 @@ class MemberController extends ThinkController
* @param $id
* @param $lock_status
*/
public function lock_status($id, $lock_status)
public function lock_status($id="", $lock_status, $accounts = "")
{
$map['id'] = ['in', array_unique(explode(',', $id))];
if ($accounts) $map['account'] = ['in', array_unique(explode(',', $accounts))];
if ($id) $map['id'] = ['in', array_unique(explode(',', $id))];
$users = M('user', 'tab_')->where($map)->field('id')->select();
$res = M('user', 'tab_')->where($map)->setField(['lock_status' => $lock_status]);
if ($res) {
\Think\Log::actionLog('Member/lock_status', 'Member', $id);
foreach ($users as $item) {
\Think\Log::actionLog('Member/lock_status', 'Member', $item['id']);
}
$this->success('操作成功!');
} else {
$this->error('操作失败!');

@ -49,12 +49,13 @@
<tr>
<td class="l">玩家账号:</td>
<td class="r" >
<select id="user_id" name="user_id">
<option value="0">请选择账号</option>
<volist name=":get_user_play_group_list()" id="vo">
<option value="{$vo.user_id}" account="{$vo.user_account}">{$vo.user_account}</option>
</volist>
</select>
<!-- <select id="user_id" name="user_id">-->
<!-- <option value="0">请选择账号</option>-->
<!-- <volist name=":get_user_play_group_list()" id="vo">-->
<!-- <option value="{$vo.user_id}" account="{$vo.user_account}">{$vo.user_account}</option>-->
<!-- </volist>-->
<!-- </select>-->
<input type="text" class="txt" id="user_id" name="user_id"/>
</td>
</tr>
<tr>
@ -144,7 +145,7 @@ $(function(){
//$(".balance").text($('#user_id option:selected').attr('coin-balance')+'平台币');
$('#user_id').change(function(){
//$(".balance").text($('#user_id option:selected').attr('coin-balance')+'平台币');
var user_id = $('#user_id option:selected').attr('value');
var user_id = $('#user_id').val();
if(this.value !="请选择账号"){
getUserPlayGameName(user_id);

@ -239,7 +239,7 @@
<else/>
<volist name="list_data" id="data">
<tr>
<td ><input class="ids" type="checkbox" value="{$data.id}" name="ids[]"></td>
<td ><input class="ids" type="checkbox" value="{$data.account}" name="ids[]"></td>
<td >{$data.id}</td>
<if condition="I('type') eq 2">
<td >{:get_registertype($data['register_type'])}</td>
@ -510,8 +510,8 @@ $(function(){
layer.prompt({
formType: 2,
value: text,
placeholder : '账户ID(英文逗号隔开)',
title: '请输入要'+desc+'的账户ID(英文逗号隔开)',
placeholder : '玩家账号(英文逗号隔开)',
title: '请输入要'+desc+'的玩家账号(英文逗号隔开)',
area: ['800px', '350px'] //自定义文本域宽高
}, function(value, index, elem){
if(value=='') {
@ -523,7 +523,7 @@ $(function(){
cache: true,
type: "POST",
url:"{:U('Member/lock_status')}",
data:{id:value, lock_status:status},// 你的formid
data:{accounts:value, lock_status:status},// 你的formid
async: false,
error: function(data) {
layer.alert("服务器故障,请稍后重试!",{icon: 2});

@ -625,10 +625,11 @@ class PromoteCoinController extends BaseController
$level = I('level', 0);
$account = I('account', '');
$mobile = I('mobile', '');
$promote = $this->getLoginPromote();
$map = [];
$map['level'] = $level;
if ($level > 0) {
$map['level'] = $level;
}
$map['chain'] = ['like', $promote['chain'] . $promote['id'] . '/%'];
if ($account) {
@ -638,7 +639,6 @@ class PromoteCoinController extends BaseController
$map['mobile_phone'] = ['like', '%' . $mobile . '%'];
}
$query = M('promote', 'tab_')->field(['id', 'account', 'real_name', 'mobile_phone'])->where($map);
list($promotes, $pagination, $count) = $this->paginate($query);
$records = [];
foreach ($promotes as $promote) {
@ -747,7 +747,6 @@ class PromoteCoinController extends BaseController
} else {
$map['_string'] = '1<>1';
}
$query = M('Game', 'tab_')->field(['id', 'game_name', 'sdk_version', 'icon'])->where($map);
list($games, $pagination, $count) = $this->paginate($query);

@ -1,294 +1,133 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<script src="__JS__/jquery-1.11.3.min.js"></script>
<script type="text/javascript" src="__JS__/getRem.js"></script>
<script type="text/javascript" src="__JS__/swiper.min.js"></script>
<link rel="stylesheet" type="text/css" href="__CSS__/swiper.min.css">
<link rel="stylesheet" type="text/css" href="__CSS__/reset.css">
<link rel="stylesheet" type="text/css" href="__CSS__/index2.css">
<title>home</title>
<meta itemprop="name" content="{$game['relation_game_name']}"/>
<meta itemprop="image" content="{$game['icon']}"/>
<meta name="description" itemprop="description" content="{$game['features']}"/>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1">
<script type="text/javascript" src="__JS__/jquery-1.11.1.min.js"></script>
<script type="text/javascript" src="https://res2.wx.qq.com/open/js/jweixin-1.4.0.js"></script>
<link href="{:get_cover(C('CH_SET_ICO'),'path')}" type="image/x-icon" rel="shortcut icon">
<title>{$game['relation_game_name']}</title>
<link rel="stylesheet" href="__CSS__/20180207/promition.css">
<link rel="stylesheet" href="__CSS__/20180207/game.css">
<link href="__STATIC__/ios9/css/common.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="__CSS__/landing_page.css">
</head>
<body>
<div class="home">
<div class="home-box">
<div class="heard">
<img src="{$game['icon']}" alt="">
<div class="right">
<div>{$game['relation_game_name']}</div>
<div>{$game['features']}</div>
<div>
<?php if ($downloadUrl == 'https://'.$_SERVER['HTTP_HOST']) :?>
<div class="download">免费安装</div>
<?php else :?>
<div class="download">免费安装</div>
<?php endif ;?>
<img src="__IMG__/wenhao.png" class="doubt" alt="">
</div>
</div>
</div>
<div class="evaluate">
<div class="evaluate-box">
<div class="number">
<span>{$game['game_score']}</span>
<div class="start">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start.png" alt="">
</div>
</div>
<div class="grade">14.48K个评分</div>
</div>
<div class="evaluate-box">
<span>#{$game['recommend_level']}</span>
<div class="grade">网络游戏</div>
</div>
<div class="evaluate-box">
<span>16+</span>
<div class="grade">年龄</div>
</div>
</div>
<div class="slide_list">
<ul class="slide-box">
<volist name="game['flooring_page_imgs']" id="item">
<li class="slide-item">
<img src="{$item}" alt="">
</li>
</volist>
</ul>
</div>
<div class="synopsis">
<div>简介</div>
<div id="brief_introduction">{$game['features']}</div>
<div id="look_more">
<div class="bg-blur"></div>
<div class="more">查看更多</div>
</div>
</div>
<div class="appraisal">
<div class="title">评分及评论</div>
<div class="appraisal-box">
<div class="left">
<span>{$game['game_score']}</span>
<span>满分5分</span>
</div>
<div class="right">
<div class="start-number">
<div class="start">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
</div>
<div class="strip">
<div style="width: 2.77rem;"></div>
</div>
</div>
<div class="start-number">
<div class="start">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
</div>
<div class="strip">
<div style="width: 0.24rem;"></div>
</div>
</div>
<div class="start-number">
<div class="start">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
</div>
<div class="strip">
<div style="width: 0.06rem;"></div>
</div>
</div>
<div class="start-number">
<div class="start">
<img src="__IMG__/start1.png" alt="">
<img src="__IMG__/start1.png" alt="">
</div>
<div class="strip">
<div style="width: 0.04rem;"></div>
</div>
</div>
<div class="start-number">
<div class="start">
<img src="__IMG__/start1.png" alt="">
</div>
<div class="strip">
<div style="width: 0;"></div>
</div>
</div>
<div class="mark">14.48K个评分</div>
</div>
</div>
</div>
<div class="device">
<div class="title">新功能</div>
<div class="soon-title">更新说明:</div>
<div class="del">1、优化用户体验</div>
</div>
<div class="information">
<div class="title">信息</div>
<div class="data-box">
<span>大小</span>
<div>{$game['game_size']}MB</div>
</div>
<div class="data-box">
<span>类别</span>
<div>游戏</div>
</div>
<div class="data-box">
<span>语言</span>
<div>英语,简体中文</div>
</div>
<div class="data-box">
<span>年龄分级</span>
<div>限16岁以上</div>
</div>
<div class="data-box">
<span>价格</span>
<div>免费</div>
</div>
<div class="privacy">隐私政策</div>
</div>
</div>
<div class="foot">
<div>
<div>闽ICP备19000000号-0</div>
<div>闽网文{2019}1554-099号</div>
</div>
<div>抵制不良游戏,拒绝盗版游戏。注意自我保护,谨防受骗上当。</div>
<div>适度游戏益脑,沉迷游戏伤身。合理安排时间,享受健康生活。</div>
</div>
</div>
<body class="main_bg" style="background-color: #0a0a0a;height: auto;">
<input type="hidden" name="title" value="{$game['relation_game_name']}">
<input type="hidden" name="icon" value="{$game['icon']}">
<input type="hidden" name="desc" value="{$game['features']}">
<input type="hidden" name="isIOS13" value="<?php if($isIOS13):?>1<?php else:?>0<?php endif;?>">
<?php if ($isWechat):?>
<?php if ($isAndroid):?>
<div class="bn-rule" style="display: none;"><img id="rule-img" src="__STATIC__/ios9/images/android-rule.png"></div>
<?php elseif ($isIOS):?>
<div class="bn-rule" style="display: none;"><img id="rule-img" src="__STATIC__/ios9/images/ios-rule.png"></div>
<?php endif;?>
<?php endif;?>
<div class="window" style="display: none;">
<div class="containner">
<div class="containner-box">
<div class="text"> 购买至尊下载赠送限量至尊超级礼包价值100元</div>
<div class="text">• 至尊下载:永不闪退、不丢数据稳定有保障</div>
<div class="text"> • 同一设备安装一次可在一年内无限次下载重装</div>
<div class="blue-btn" onclick="location.href='mobile.php/Ssg/pay/game_id/{$game[\'id\']}/promote_id/{$promoteId}'">¥10至尊下载</div>
<div class="gray-btn" onclick="location.href='{$downloadUrl}'">普通下载</div>
</div>
<div class="h_wrap">
<div id="data-2">
<volist name="game['flooring_page_imgs']" id="item">
<?php if ($downloadUrl == 'https://'.$_SERVER['HTTP_HOST']) :?>
<a href="#" class="no-package"><img src="{$item}" style="width: 100%;"/></a>
<?php else :?>
<a href="javascript:;" class="down-link" down-link="{$downloadUrl}"><img src="{$item}" style="width: 100%;"/></a>
<?php endif ;?>
</volist>
</div>
</div>
<div class="second" style="display: none;">
<div class="second-box">
<div class="title">升级IOS9后游戏打不开怎么办</div>
<div class="carousel">
<div class="swiper-container">
<div class="swiper-wrapper">
<div class="swiper-slide">
<div class="swiper-slide-box">
<div>一、游戏安装完毕,点击游戏图标弹出如下提示:</div>
<div class="slide-img">
<img src="__IMG__/1.png" alt="" style=" height: 2.86rem;">
<img src="__IMG__/box-scroll.png" alt="" class="case">
</div>
</div>
</div>
<div class="swiper-slide">
<div class="swiper-slide-box">
<div>二、进入[设置] - [通用] - [描述文件]:找到对应证书名称</div>
<div class="slide-img">
<img src="__IMG__/2.png" alt="" style="height: 2.75rem;">
<img src="__IMG__/box-scroll.png" alt="" class="case">
</div>
</div>
</div>
<div class="swiper-slide">
<div class="swiper-slide-box">
<div>三、信任当前证书</div>
<div class="slide-img">
<img src="__IMG__/3.png" alt="" style="height: 2.06rem;">
<img src="__IMG__/box-scroll.png" alt="" class="case">
</div>
</div>
</div>
<div class="swiper-slide">
<div class="swiper-slide-box">
<div>四、下载过程中若出现以下情况,请检查网络和内存再次尝试下载</div>
<div class="slide-img">
<img src="__IMG__/4.png" alt="" style="height: 2.88rem;">
<img src="__IMG__/box-scroll.png" alt="" class="case">
</div>
</div>
</div>
<div class="swiper-slide">
<div class="swiper-slide-box">
<div>五、如果您已验证并正常体验游戏,一段时间后,点击游戏图标再次出现信任提示且无法信任时,请卸载游戏包,重新安装游戏验证</div>
</div>
</div>
</div>
<!-- Add Pagination -->
<div class="swiper-pagination"></div>
</div>
</div>
<div class="blue-btn">点我去信任</div>
</div>
</div>
</body>
</html>
<script>
$(function(){
if ($("#brief_introduction").length<80) {
$("#look_more").hide();
<script src="__STATIC__/layer/layer.js"></script>
<script src="__STATIC__/ios9/js/layer/layer.js?VerNo=20190923" type="text/javascript"></script>
<script type="text/javascript">
$('.down-link').on('click', function () {
if ($('.bn-rule').length > 0) {
$('.bn-rule').css('display','block')
$('.bn-rule').css('z-index','12')
return
}
$(".more").click(function(){
$("#look_more").hide();
$("#brief_introduction").css("overflow", "visible");
});
if ($('input[name=isIOS13]').val() == 1) {
if (parseInt("{:I('get.status', 0)}") > 0) {
location.href = "{:U('iosDown',array('gid'=>$apply['game_id'],'pid'=>$apply['promote_id'],'status'=>1))}"
return
} else {
layer.confirm('请先到官网注册', {title: '提示'}, function () {
location.href = "/mobile.php?s=/User/login/pid/" + "{$apply.promote_id}" + "/gid/" + "{$apply.game_id}" + ".html"
})
return
}
}
var downLink = $(this).attr('down-link')
location.href = downLink
});
function swiperGet(){
var swiper = new Swiper('.swiper-container', {
loop: true,
// autoplay: img > 1,
pagination: {
el: '.swiper-pagination',
clickable: true,
},
autoplay: {
delay: 3000,
stopOnLastSlide: false,
disableOnInteraction: false,
},
});
};
swiperGet();
$(".download").click(function(){
$(".window").show();
document.body.style.overflow = 'hidden';
});
$(".window").click(function(){
$(".window").hide();
document.body.style.overflow = 'auto';
});
$(".gray-btn").click(function(){
event.stopPropagation();
$(".second").show();
swiperGet();
document.body.style.overflow = 'hidden';
$(".window").hide();
})
$(".second").click(function(){
$(".second").hide();
document.body.style.overflow = 'auto';
})
$(".doubt").click(function(){
$(".second").show();
document.body.style.overflow = 'hidden';
swiperGet();
$('.no-package').click(function() {
layer.msg('暂无下载', {
icon: 7,
time: 2000
})
})
$.ajax({
url: "{:U('Home/generateWechatSign')}",
dataType: 'json',
type: 'post',
data: {url: window.location.href},
success: function(response) {
if (response.status) {
wx.config({
// debug: true, // 开启调试模式,调用的所有api的返回值会在客户端alert出来若要查看传入的参数可以在pc端打开参数信息会通过log打出仅在pc端时才会打印。
appId: response.data.appid,
timestamp: response.data.time,
nonceStr: response.data.randStr,
signature: response.data.sign,
jsApiList: ['onMenuShareAppMessage', 'onMenuShareTimeline', 'onMenuShareQQ', 'onMenuShareWeibo', 'onMenuShareQZone']
})
var title = $('[name=title]').val();
var description = $('[name=desc]').val();
var icon = $('[name=icon]').val();
wxReady(title, description, icon)
}
}
});
function wxReady(title, description, img) {
wx.ready(function () {
wx.onMenuShareAppMessage({
title: title,
desc: description,
link: window.location.href,
imgUrl: img,
type: '',
dataUrl: ''
});
wx.onMenuShareTimeline({
title: title,
link: window.location.href,
imgUrl: img
});
wx.onMenuShareQQ({
title: title,
desc: description,
link: window.location.href,
imgUrl: img
});
wx.onMenuShareWeibo({
title: title,
desc: description,
link: window.location.href,
imgUrl: img
});
wx.onMenuShareQZone({
title: title,
desc: description,
link: window.location.href,
imgUrl: img
});
});
}
</script>
</body>
</html>

@ -9,6 +9,7 @@
<div class="trunk-content article">
<div class="trunk-search clearfix" style="margin-bottom: 10px;">
<form action="{:U('PromoteCoin/subPromotes', array('row'=>I('get.row')))}" method="post" class="clearfix">
<input type="hidden" name="level" value="{:I('level', 0)}">
<div class="form-group normal_space fr">
<input type="submit" class="submit" value="查询">
</div>

@ -9,6 +9,7 @@
<div class="trunk-content article">
<div class="trunk-search clearfix" style="margin-bottom: 10px;">
<form action="{:U('PromoteCoin/userGames', array('row'=>I('get.row')))}" method="post" class="clearfix">
<input type="hidden" name="user_id" value="{:I('user_id', 0)}">
<div class="form-group normal_space fr">
<input type="submit" class="submit" value="查询">
</div>

Loading…
Cancel
Save