公会统计5

master
chenzhi 5 years ago
parent 86db958ca7
commit 904b707cf4

@ -561,35 +561,48 @@ class FinancePromoteController extends AdminController
$gameId = implode(',',array_column($gameId,'id'));
$map['tab_spend.game_id'] = ['in',$gameId];
}
if (!empty(I('timestart'))) {
$timestart = strtotime(I('timestart'));
$map['_string'] = "pay_time > {$timestart}";
if (!empty(I("game_id"))) {
$map['tab_spend.game_id'] = I("game_id");
}
if (!empty(I('timeend'))) {
$timeend = strtotime(I('timeend'));
$map['_string'] .= " and pay_time < {$timeend}";
if (isset($_REQUEST['time_start']) && isset($_REQUEST['time_end'])) {
$map['pay_time'] = ['between', [strtotime($_REQUEST['time_start']), strtotime($_REQUEST['time_end']) + 86399]];
} elseif (isset($_REQUEST['time_start'])) {
$map['pay_time'] = ['GT', strtotime($_REQUEST['time_start'])];
} elseif (isset($_REQUEST['time_end'])) {
$map['pay_time'] = ['LT', strtotime($_REQUEST['time_end']) + 86399];
}
if (!empty(I("promote_id"))) {
$promote_id[] = I("promote_id");
if ($_REQUEST['promote_id'] != '') {
if ($_REQUEST['promote_id'] == 0 || $_REQUEST['promote_type'] == 2) {
$map['tab_spend.promote_id'] = $_REQUEST['promote_id'];
} else {
$promoter_ids = D("Promote")->where("chain like '%/{$_REQUEST['promote_id']}/%' or id={$_REQUEST['promote_id']}")->field('id')->select();
if ($promoter_ids) {
$map['tab_spend.promote_id'] = ['in', implode(',', array_column($promoter_ids, 'id'))];
}
}
}
if (!empty(I("root_id"))) {
$root_id = I("root_id");
$promote_id = $this->getPromoteList($root_id);
array_push($promote_id, $root_id);
}
// if (!empty(I("promote_id"))) {
// $promote_id[] = I("promote_id");
// }
if ($_REQUEST['root_id']=='0') {
$map['tab_spend.promote_id'] = $_REQUEST['root_id'];
}
// if (!empty(I("root_id"))) {
// $root_id = I("root_id");
// $promote_id = $this->getPromoteList($root_id);
// array_push($promote_id, $root_id);
// }
$promote_id = implode(',',$promote_id);
if ($promote_id) {
$map['tab_spend.promote_id'] = ['in',$promote_id];
}
// if ($_REQUEST['root_id']=='0') {
// $map['tab_spend.promote_id'] = $_REQUEST['root_id'];
// }
// $promote_id = implode(',',$promote_id);
// if ($promote_id) {
// $map['tab_spend.promote_id'] = ['in',$promote_id];
// }
$page = intval($p);
$page = $page ? $page : 1; //默认显示第一页数据
@ -599,9 +612,7 @@ class FinancePromoteController extends AdminController
$row = 10;
}
$map['pay_status'] = 1;
if (!empty(I("game_id"))) {
$map['tab_spend.game_id'] = I("game_id");
}
if (!empty(I('user_account'))) {
$map['tab_spend.user_account'] = array('like','%'.I("user_account").'%');
}

@ -13,12 +13,15 @@
<script type="text/javascript" src="__STATIC__/jquery-2.0.3.min.js"></script>
</head>
<style>
html {
min-width:100%;
}
body {
padding: 0px;
}
</style>
<body>
<div id="main" class="main" style="min-height: 342px;width: 90%;">
<div id="main" class="main" style="min-height: 342px;">
<!-- 标题栏 -->
<div class="cf top_nav_list">

@ -13,12 +13,15 @@
<script type="text/javascript" src="__STATIC__/jquery-2.0.3.min.js"></script>
</head>
<style>
html {
min-width:100%;
}
body {
padding: 0px;
}
</style>
<body>
<div id="main" class="main" style="min-height: 342px;width: 90%;">
<div id="main" class="main" style="min-height: 342px;">
<!-- 标题栏 -->
<div class="cf top_nav_list">

Loading…
Cancel
Save