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

master
chenxiaojun 5 years ago
commit ef4443cd4c

@ -1916,6 +1916,25 @@ class ExportController extends Controller
} }
break; break;
case 23: case 23:
$params = I('get.');
$map['tab_game_supersign.pay_status'] = 1;
if (isset($params['order_id'])) {
$map['tab_game_supersign.order_id'] = $params['order_id'];
}
if (isset($params['account'])) {
$map['tab_user.account'] = $params['account'];
}
if (isset($params['promote_id'])) {
$promoteId = $params['promote_id'];
if ($promoteId == 0) {
$map['promote_id'] = 0;
} else {
$promoteMap['chain'] = ['like', "%/$promoteId/%"];
$promoteIds = M('Promote', 'tab_')->where($promoteMap)->getField('id', true);
$promoteIds[] = $promoteId;
$map['tab_user.promote_id'] = ['in', $promoteIds];
}
}
$xlsCell = array( $xlsCell = array(
array('order_id', '订单号'), array('order_id', '订单号'),
array('account', '游戏账号'), array('account', '游戏账号'),
@ -1925,7 +1944,7 @@ class ExportController extends Controller
array('pay_time', '购买时间'), array('pay_time', '购买时间'),
array('super_money', '超级签金额'), array('super_money', '超级签金额'),
); );
$xlsData = M('game_supersign', 'tab_')->field('tab_game_supersign.id,tab_game_supersign.order_id,tab_user.account,tab_user.promote_account,tab_user.device_number,tab_game.game_name,tab_game_supersign.pay_time')->join('tab_user on tab_game_supersign.user_id = tab_user.id')->join('tab_game on tab_game_supersign.game_id = tab_game.id')->where(['tab_game_supersign.pay_status' => 1])->order('id DESC')->select(); $xlsData = M('game_supersign', 'tab_')->field('tab_game_supersign.id,tab_game_supersign.order_id,tab_user.account,tab_user.promote_account,tab_user.device_number,tab_game.game_name,tab_game_supersign.pay_time')->join('tab_user on tab_game_supersign.user_id = tab_user.id')->join('tab_game on tab_game_supersign.game_id = tab_game.id')->where($map)->order('id DESC')->select();
foreach($xlsData as $k => $v) { foreach($xlsData as $k => $v) {
$xlsData[$k]['pay_time'] = date('Y-m-d H:i:s',$v['pay_time']); $xlsData[$k]['pay_time'] = date('Y-m-d H:i:s',$v['pay_time']);
} }

@ -102,8 +102,27 @@ class SuperStatisticalController extends ThinkController
public function superDetail($p = 1,$row = 10) { public function superDetail($p = 1,$row = 10) {
$page = $p ? $p : 1; $page = $p ? $p : 1;
$row = $row ? $row : 10; $row = $row ? $row : 10;
$data = M('game_supersign', 'tab_')->field('tab_game_supersign.id,tab_game_supersign.order_id,tab_user.account,tab_user.promote_account,tab_user.device_number,tab_game.game_name,tab_game_supersign.pay_time')->join('tab_user on tab_game_supersign.user_id = tab_user.id')->join('tab_game on tab_game_supersign.game_id = tab_game.id')->where(['tab_game_supersign.pay_status' => 1])->page($page,$row)->order('id DESC')->select(); $params = I('get.');
$count = M('game_supersign', 'tab_')->field('tab_game_supersign.order_id,tab_user.account,tab_user.promote_account,tab_user.device_number,tab_game.game_name,tab_game_supersign.pay_time')->join('tab_user on tab_game_supersign.user_id = tab_user.id')->join('tab_game on tab_game_supersign.game_id = tab_game.id')->where(['tab_game_supersign.pay_status' => 1])->count(); $map['tab_game_supersign.pay_status'] = 1;
if (isset($params['order_id'])) {
$map['tab_game_supersign.order_id'] = $params['order_id'];
}
if (isset($params['account'])) {
$map['tab_user.account'] = $params['account'];
}
if (isset($params['promote_id'])) {
$promoteId = $params['promote_id'];
if ($promoteId == 0) {
$map['promote_id'] = 0;
} else {
$promoteMap['chain'] = ['like', "%/$promoteId/%"];
$promoteIds = M('Promote', 'tab_')->where($promoteMap)->getField('id', true);
$promoteIds[] = $promoteId;
$map['tab_user.promote_id'] = ['in', $promoteIds];
}
}
$data = M('game_supersign', 'tab_')->field('tab_game_supersign.id,tab_game_supersign.order_id,tab_user.account,tab_user.promote_account,tab_user.device_number,tab_game.game_name,tab_game_supersign.pay_time')->join('tab_user on tab_game_supersign.user_id = tab_user.id')->join('tab_game on tab_game_supersign.game_id = tab_game.id')->where($map)->page($page,$row)->order('id DESC')->select();
$count = M('game_supersign', 'tab_')->field('tab_game_supersign.order_id,tab_user.account,tab_user.promote_account,tab_user.device_number,tab_game.game_name,tab_game_supersign.pay_time')->join('tab_user on tab_game_supersign.user_id = tab_user.id')->join('tab_game on tab_game_supersign.game_id = tab_game.id')->where($map)->count();
$super_money_all = $count * $this->super_money; $super_money_all = $count * $this->super_money;
$page = set_pagination($count, $row); $page = set_pagination($count, $row);

@ -102,7 +102,6 @@
</div> </div>
</div> </div>
<div class="page"> <div class="page">
<a class="sch-btn" href="{:U('Export/expUser',array_merge(array('id'=>21,'xlsname'=>'游戏充值预下单'),I('get.')))}">导出</a>
{$_page|default=''} {$_page|default=''}
</div> </div>

@ -11,8 +11,10 @@
<link rel="stylesheet" type="text/css" href="__CSS__/module.css"> <link rel="stylesheet" type="text/css" href="__CSS__/module.css">
<link rel="stylesheet" type="text/css" href="__CSS__/style.css" media="all"> <link rel="stylesheet" type="text/css" href="__CSS__/style.css" media="all">
<link rel="stylesheet" type="text/css" href="__CSS__/default_color.css" media="all"> <link rel="stylesheet" type="text/css" href="__CSS__/default_color.css" media="all">
<link rel="stylesheet" href="__CSS__/select2.min.css" type="text/css"/>
<script type="text/javascript" src="__STATIC__/jquery-2.0.3.min.js"></script> <script type="text/javascript" src="__STATIC__/jquery-2.0.3.min.js"></script>
<script type="text/javascript" src="__JS__/jquery.mousewheel.js"></script> <script type="text/javascript" src="__JS__/jquery.mousewheel.js"></script>
<script type="text/javascript" src="__JS__/select2.min.js"></script>
</head> </head>
<style> <style>
body { body {
@ -26,6 +28,41 @@
<link rel="stylesheet" type="text/css" href="__CSS__/admin_table.css" media="all"> <link rel="stylesheet" type="text/css" href="__CSS__/admin_table.css" media="all">
<script type="text/javascript" src="__STATIC__/uploadify/jquery.uploadify.min.js"></script> <script type="text/javascript" src="__STATIC__/uploadify/jquery.uploadify.min.js"></script>
<div class="jssearch fl cf search_list">
<div class="input-list search-title-box">
<label>搜索:</label>
</div>
<div class="input-list">
<input type="text" name="order_id" class="" placeholder="请输入支付订单" value="{:I('order_id')}"/>&nbsp;
</div>
<div class="input-list">
<input type="text" name="account" class="" placeholder="请输入玩家账号" value="{:I('account')}"/>&nbsp;
</div>
<div class="input-list search_item input-list-gamenoticestatus">
<select name="promote_level" style="color:#444" class="select_gallery" id="promote_level">
<option value="">请选择推广员等级</option>
<option value="1" <?php if ($_GET['promote_level'] == 1):?>selected<?php endif;?>>会长</option>
<option value="2" <?php if ($_GET['promote_level'] == 2):?>selected<?php endif;?>>部门长</option>
<option value="3" <?php if ($_GET['promote_level'] == 3):?>selected<?php endif;?>>组长</option>
<option value="4" <?php if ($_GET['promote_level'] == 4):?>selected<?php endif;?>>组员</option>
</select>
-
</div>
<div class="input-list search_item input-list-gamenoticestatus">
<select name="promote_id" style="color:#444" class="select_gallery" id="promote_id">
<option value="">请选择推广员</option>
<option value="0" <?php if ($_POST['promote_id'] == 0):?>selected<?php endif;?>>官方渠道</option>
<option value="UC" <?php if ($_POST['promote_id'] == 'UC'):?>selected<?php endif;?>>UC用户</option>
</select>
</div>
<input type="hidden" name="" value="" class="sortBy">
<div class="input-list search_item">
<a class="sch-btn" href="javascript:;" id="search"
url="{:U('SuperStatistical/superDetail','model='.$model['name'] . '&row='.I('row'),false)}">搜索</a>
</div>
</div>
<!-- 数据列表 --> <!-- 数据列表 -->
<div class="data_list box_mt"> <div class="data_list box_mt">
<div class=""> <div class="">
@ -74,4 +111,54 @@
</div> </div>
</div> </div>
</body> </body>
<script type="text/javascript">
$(function(){
$(".select_gallery").select2();
$("#search").click(function(){
var url = $(this).attr('url');
var query = $('.jssearch').find('input').serialize();
query += "&" + $('.jssearch').find('select').serialize();
query = query.replace(/(&|^)(\w*?\d*?\-*?_*?)*?=?((?=&)|(?=$))/g,'');
query = query.replace(/^&/g,'');
if( url.indexOf('?')>0 ){
url += '&' + query;
}else{
url += '?' + query;
}
var start = $("#time_start").val();
var end = $("#time_end").val();
if(start !='' && end != ''){
if (Date.parse(start) > Date.parse(end)){
layer.msg('开始时间必须小于等于结束时间');
return false;
}
}
window.location.href = url;
});
var promote_id = "{:I('promote_id')}";
$("#promote_level").change(function(){
$.ajax({
url:"{:U('Ajax/getPromotersByLevel')}",
type:"get",
data:{level:$("#promote_level option:selected").val()},
dataType:'json',
success:function(response){
str = '<option value="">请选择推广员</option><option value="0"'+(promote_id && 0 == promote_id?'selected':'')+'>官方渠道</option><option value="UC"'+(promote_id && 'UC' == promote_id?'selected':'')+'>UC渠道</option>';
// $.each(response.data, function(index, item){
// console.log(item.id);
// str += '<option value="'+item.id+' '+(promote_id && item.id == promote_id?'selected':'')+'">'+item.nickname+'</option>';
// });
data = response.data;
for (var i in data){
str += "<option value='"+data[i].id+"' "+(promote_id && data[i].id == promote_id?'selected':'')+">"+data[i].nickname+"</option>"
}
$("#promote_id").empty();
$("#promote_id").append(str);
$("#promote_id").select2();
}
})
});
$("#promote_level").change();
})
</script>
</html> </html>
Loading…
Cancel
Save