修改bug

master
ELF 5 years ago
parent 14e36e31bb
commit 7acf0e13bf

@ -755,7 +755,7 @@ class QueryController extends BaseController
$timeout = 0;
$records = [];
if (intval($endTime - $beginTime) / (24 * 3600) <= 30) {
if (intval($endTime - $beginTime) / (24 * 3600) <= 31) {
$userRepository = new UserRepository();
$spendRepository = new SpendRepository();
$payGameCountList = $spendRepository->getPayGameCountGroupByDay($params);
@ -2009,13 +2009,21 @@ class QueryController extends BaseController
$rows = [];
if (count($ids) > 0) {
$rows = M('promote', 'tab_')->field(['id', 'parent_id'])->where(['parent_id' => ['in', $ids]])->select();
$rows = M('promote', 'tab_')
->field(['id', 'chain'])
->where(['chain' => ['like', [$parent['chain'] . $parent['id'] . '/%']], 'level' => ['gt', $parent['level'] + 1]])
->select();
}
$basicPromotes = [];
foreach ($rows as $row) {
$basicPromotes[$row['id']] = $row['parent_id'];
foreach ($ids as $id) {
foreach ($rows as $row) {
$needChain = $parent['chain'] . $parent['id'] . '/' . $id . '/';
if (strpos($row['chain'], $needChain) !== false) {
$basicPromotes[$row['id']] = $id;
}
}
}
$params = [
'isContainSubs' => true,
'basicPromotes' => $basicPromotes,
@ -2035,7 +2043,7 @@ class QueryController extends BaseController
list($beginTime, $endTime) = $this->getBetweenTime($time);
$params['begin_time'] = $beginTime;
$params['end_time'] = $endTime;
$promoteRepository = new PromoteRepository();
$createRoleCountList = $promoteRepository->getCreateRoleCountByIds($ids, $params);
$createRoleUserCountList = $promoteRepository->getCreateRoleUserCountByIds($ids, $params);

@ -242,7 +242,7 @@
<script type="text/javascript" src="__JS__/common.js"></script>
<eq name='timeout' value='1'>
<script>
layer.msg('时间间隔不能超过30天');
layer.msg('时间间隔不能超过31天');
</script>
</eq>
<script>

Loading…
Cancel
Save