推广后台优化

master
ELF 4 years ago
parent df933cc6b1
commit 919791c0c7

@ -2907,9 +2907,9 @@ public function iosDetailExcelInfo($id,$map) {
foreach ($data as $key1 => $value1) {
$value1['user_account'] = $this->encryption($value1['user_account']);
if($value1['create_time'] == 0) {
$value1['create_time'] = date('Y-m-d H:i:s', $value['play_time']);
$value1['create_time'] = date('Y-m-d H:i:s', $value1['play_time']);
} else {
$value1['create_time'] = date('Y-m-d H:i:s', $value['create_time']);
$value1['create_time'] = date('Y-m-d H:i:s', $value1['create_time']);
}
if (isset($users[$value1['user_id']])) {
$user = $users[$value1['user_id']];

@ -1687,7 +1687,13 @@ class QueryController extends BaseController
$levelPromote = $this->getLevelPromote();
$queryPromote = $this->getQueryPromote($levelPromote);
$map[] = [
$promoteService = new PromoteService();
$subInSql = $promoteService->subInSql($queryPromote);
$map = [];
$map['_string'] = '1=1';
$map['_string'] .= ' and promote_id in (' . $subInSql . ')';
/* $map[] = [
'_logic' => 'or',
'id' => $queryPromote['id'],
'chain' => ['like', $queryPromote['chain'] . $queryPromote['id'] . '/%']
@ -1699,7 +1705,7 @@ class QueryController extends BaseController
$map = ['promote_id' => ['in', $ids]];
} else {
$map['_string'] = '1<>1';
}
} */
if ($relationGameId != 0 || $sdkVersion != 0) {
$gameIds = gameSearch($relationGameId, $sdkVersion);
@ -1740,6 +1746,13 @@ class QueryController extends BaseController
$query = M('user_play_info', 'tab_')->where($map)->order('create_time desc');
list($records, $pagination, $count) = $this->paginate($query);
$countRow = M('user_play_info', 'tab_')->field(['count(distinct user_id) user_count'])->where($map)->find();
$countMap = $map;
$subSql = M('user', 'tab_')->field('id')->where(['is_repeat' => 0])->select(false);
$countMap['_string'] .= ' and user_id in (' . $subSql . ')';
$uniqueCountRow = M('user_play_info', 'tab_')->field(['count(distinct user_id) user_count, count(*) count'])->where($countMap)->find();
$users = [];
if (count($records) > 0) {
$userIds = array_column($records, 'user_id');
@ -1785,6 +1798,10 @@ class QueryController extends BaseController
$games = get_promote_serach_game();
$this->assign('user_count', $countRow['user_count']);
$this->assign('unique_user_count', $uniqueCountRow['user_count']);
$this->assign('unique_count', $uniqueCountRow['count']);
$this->assign('games', $games);
$this->assign('records', $records);
$this->assign('pagination', $pagination);

@ -10,6 +10,9 @@
line-height: 34px;
height: 34px;
}
.pointer-hand {
cursor: pointer;
}
</style>
</block>
<block name="body">
@ -80,19 +83,19 @@
<table class="table normal_table">
<tr class="odd">
<th>账号(姓名)</th>
<th>创角数</th>
<th>创角用户</th>
<th>新创角用户</th>
<th class="pointer-hand" title="统计时间范围内,成功创建角色数量">创角数</th>
<th class="pointer-hand" title="统计时间范围内,成功创角的用户数(去重)">创角用户</th>
<th class="pointer-hand" title="统计时间范围内,首次创建角色的用户数">新创角用户</th>
<!-- <th>新创角设备</th> -->
<th>新创角IP</th>
<th>登录用户数</th>
<th class="pointer-hand" title="统计时间范围内首次创建角色IP总数去重">创角IP</th>
<th class="pointer-hand" title="统计时间范围内,登录的用户数(去重)">登录用户数</th>
<?php if($canViewUserRecharge):?>
<th>充值人数</th>
<th>充值次数</th>
<th>充值总额</th>
<th>现金充值</th>
<th>通用币充值</th>
<th>绑定币充值</th>
<th class="pointer-hand" title="统计时间范围内,在游戏内充值成功的订单的用户数(去重)">充值人数</th>
<th class="pointer-hand" title="统计时间范围内,在游戏内充值成功的订单数量">充值次数</th>
<th class="pointer-hand" title="统计时间范围内,在游戏内充值成功的订单金额总和">充值总额</th>
<th class="pointer-hand" title="统计时间范围内,在游戏内充值成功的订单,使用现金支付金额总和">现金充值</th>
<th class="pointer-hand" title="统计时间范围内,在游戏内充值成功的订单,使用通用币支付金额总和">通用币充值</th>
<th class="pointer-hand" title="统计时间范围内,在游戏内充值成功的订单,使用绑定币支付金额总和">绑定币充值</th>
<?php endif;?>
<?php if($parent['level'] < 4):?>
<th>操作</th>

@ -114,11 +114,17 @@
</div>
<div class="pagenation clearfix">
<?php if ($loginer['level'] !== 4) :?>
<a id="sch-btn" data-href="{:U('download/userRoles_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a>
<?php endif ;?>
<?php if ($loginer['level'] !== 4) :?>
<a id="sch-btn" data-href="{:U('download/userRoles_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$pagination}
</div>
<div class="summary">
<div class="item">注册数:{$user_count}</div>
<div class="item">去重后注册数:{$unique_user_count}</div>
<div class="item">创角数:{$count}</div>
<div class="item">去重后创角数:{$unique_count}</div>
</div>
</div>
<div class="page-explain promote-mychlid-explain">
<div class="trunk-content article border_normal">

@ -400,6 +400,20 @@ input,select,button{outline:none;font-size:14px;font-family:inherit;}
color: #06C
}
.page-list .summary{
margin-bottom: 10px;
}
.page-list .summary .item {
display: inline-block;
margin-right: 10px;
}
.page-list .summary + .pagenation {
padding-top: 0px;
}
.page-list .summary + .pagenation .rows {
top: 0px;
}
.el-button {
display: inline-block;
line-height: 1;

Loading…
Cancel
Save