修改内容

master
elf@home 5 years ago
parent 0fbfd868bc
commit 2bc1f3c567

@ -1731,7 +1731,7 @@ class QueryController extends BaseController
$map['game_id'] = $gameId; $map['game_id'] = $gameId;
} }
if ($serverId != 0) { if ($serverId != 0) {
$map['serverId'] = $serverId; $map['server_id'] = $serverId;
} }
if ($roleName != '') { if ($roleName != '') {
$map['role_name'] = ['like', '%' . $roleName . '%']; $map['role_name'] = ['like', '%' . $roleName . '%'];

@ -721,6 +721,15 @@ class UserEvent extends BaseEvent {
public function arpu_analysis() { public function arpu_analysis() {
$promote = M('promote', 'tab_')->where(['id' => session('promote_auth.pid')])->find();
$map = [
'_logic' => 'or',
'id' => $promote['id'],
'parent_id' => $promote['id'],
'grand_id' => $promote['id'],
];
$ids = M('promote', 'tab_')->where($map)->getField('id', true);
if (IS_POST && $_POST['time_start'] && $_POST['time_end']) { if (IS_POST && $_POST['time_start'] && $_POST['time_end']) {
$request = $_REQUEST; $request = $_REQUEST;
$game_id = $request['game_id']; $game_id = $request['game_id'];
@ -761,19 +770,14 @@ class UserEvent extends BaseEvent {
$promote_id = PID.','.$id; $promote_id = PID.','.$id;
} }
} else { } else {
if(PID == $promote_id) { if(PID == $promote_id) {
} else { } else {
$pro_id1 = get_prmoote_chlid_account($promote_id); $pro_id1 = get_prmoote_chlid_account($promote_id);
$pro_arr = array_column($pro_id1,'id'); $pro_arr = array_column($pro_id1,'id');
$pro_arr[] = $promote_id; $pro_arr[] = $promote_id;
$promote_id=implode(',',$pro_arr); $promote_id=implode(',',$pro_arr);
} }
} }
$datelist = get_date_list($start,$end); $datelist = get_date_list($start,$end);
$user = D('User'); $user = D('User');
@ -924,7 +928,6 @@ class UserEvent extends BaseEvent {
//file_put_contents(dirname(__FILE__) . '/../Controller/arpu'.PID.'.txt',json_encode($data)); //file_put_contents(dirname(__FILE__) . '/../Controller/arpu'.PID.'.txt',json_encode($data));
$this->assign('list_data',$data); $this->assign('list_data',$data);
$this->display(); $this->display();
} }

@ -28,7 +28,7 @@
<select id="game-select" name="game_id" class="reselect select_gallery" style="width: 220px;" > <select id="game-select" name="game_id" class="reselect select_gallery" style="width: 220px;" >
<option value="0">请选择游戏</option> <option value="0">请选择游戏</option>
<volist name="games" id="game"> <volist name="games" id="game">
<option value="{$game.game_id}" <if condition="I('game_id') === $game['id']">selected</if>>{$game.game_name}</option> <option value="{$game.game_id}" <if condition="I('game_id') === $game['game_id']">selected</if>>{$game.game_name}</option>
</volist> </volist>
</select> </select>
</div> </div>
@ -47,22 +47,22 @@
<option value="2" <if condition="I('sdk_version') === '2'">selected</if>>IOS</option> <option value="2" <if condition="I('sdk_version') === '2'">selected</if>>IOS</option>
</select> </select>
</div> </div>
<if condition="$grand_id eq 0"> <if condition="$parent_id eq 0">
<div class="form-group normal_space"> <div class="form-group normal_space">
<select id="group-select" name="promote_id" class="reselect select_gallery" style="width: 220px;" > <select id="group-select" name="headman_promote_id" class="reselect select_gallery" style="width: 220px;" >
<option value="0">请选择推广员</option> <option value="0">请选择组长</option>
<volist name="promotes" id="promote"> <volist name="groupPromotes" id="promote">
<option ba-id="{$promote.id}" value="{$promote.id}">{$promote.account}</option> <option ba-id="{$promote.id}" value="{$promote.id}" <if condition="I('headman_promote_id') == $promote['id']">selected</if>>{$promote.account}</option>
</volist> </volist>
</select> </select>
</div> </div>
</if> </if>
<if condition="$parent_id eq 0"> <if condition="$grand_id eq 0">
<div class="form-group normal_space"> <div class="form-group normal_space">
<select id="promote-select" name="headman_promote_id" class="reselect select_gallery" style="width: 220px;" > <select id="promote-select" name="promote_id" class="reselect select_gallery" style="width: 220px;" >
<option value="0">请选择组长</option> <option value="0">请选择推广员</option>
<volist name="groupPromotes" id="promote"> <volist name="promotes" id="promote">
<option ba-id="{$promote.id}" value="{$promote.id}">{$promote.account}</option> <option ba-id="{$promote.id}" value="{$promote.id}" <if condition="I('promote_id') == $promote['id']">selected</if>>{$promote.account}</option>
</volist> </volist>
</select> </select>
</div> </div>

@ -28,7 +28,7 @@
<select id="game-select" name="game_id" class="reselect select_gallery" style="width: 220px;" > <select id="game-select" name="game_id" class="reselect select_gallery" style="width: 220px;" >
<option value="0">请选择游戏</option> <option value="0">请选择游戏</option>
<volist name="games" id="game"> <volist name="games" id="game">
<option value="{$game.game_id}" <if condition="I('game_id') === $game['id']">selected</if>>{$game.game_name}</option> <option value="{$game.game_id}" <if condition="I('game_id') eq $game['game_id']">selected</if>>{$game.game_name}</option>
</volist> </volist>
</select> </select>
</div> </div>
@ -58,7 +58,7 @@
<select id="group-select" name="headman_promote_id" class="reselect select_gallery" style="width: 220px;" > <select id="group-select" name="headman_promote_id" class="reselect select_gallery" style="width: 220px;" >
<option value="0">请选择组长</option> <option value="0">请选择组长</option>
<volist name="groupPromotes" id="promote"> <volist name="groupPromotes" id="promote">
<option ba-id="{$promote.id}" value="{$promote.id}" <if condition="I('promote_id') === $promote['id']">selected</if>>{$promote.account}</option> <option ba-id="{$promote.id}" value="{$promote.id}" <if condition="I('headman_promote_id') == $promote['id']">selected</if>>{$promote.account}</option>
</volist> </volist>
</select> </select>
</div> </div>
@ -68,7 +68,7 @@
<select id="promote-select" name="promote_id" class="reselect select_gallery" style="width: 220px;" > <select id="promote-select" name="promote_id" class="reselect select_gallery" style="width: 220px;" >
<option value="0">请选择推广员</option> <option value="0">请选择推广员</option>
<volist name="promotes" id="promote"> <volist name="promotes" id="promote">
<option ba-id="{$promote.id}" value="{$promote.id}" <if condition="I('promote_id') === $promote['id']">selected</if>>{$promote.account}</option> <option ba-id="{$promote.id}" value="{$promote.id}" <if condition="I('promote_id') == $promote['id']">selected</if>>{$promote.account}</option>
</volist> </volist>
</select> </select>
</div> </div>

Loading…
Cancel
Save