From ce58d63aa5343ed309be5d9e04816a8f90b124b0 Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Thu, 19 Dec 2019 13:34:40 +0800 Subject: [PATCH 1/6] =?UTF-8?q?=E5=85=85=E5=80=BC=E6=B1=87=E6=80=BBbug?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Admin/Controller/RechargeSumController.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Application/Admin/Controller/RechargeSumController.class.php b/Application/Admin/Controller/RechargeSumController.class.php index 9cbf9358e..23d3ba12b 100644 --- a/Application/Admin/Controller/RechargeSumController.class.php +++ b/Application/Admin/Controller/RechargeSumController.class.php @@ -83,7 +83,7 @@ class RechargeSumController extends ThinkController $accumulated = D('Spend')->where($map)->sum('pay_amount'); $data[$key]['date'] = date('Y-m-d', $start); - $data[$key]['game_id'] = empty($_REQUEST['game_id']) ? "全部" : get_game_name($_REQUEST['game_id']); + $data[$key]['game_id'] = empty($_REQUEST['game_name']) ? "全部" : $_REQUEST['game_name']; switch ($_REQUEST['promote_id']) { case 'GUANFANG': $data[$key]['promote_id'] = "官方渠道"; From 1cd4e94840cfd801184966c1e05c84b635a83fa9 Mon Sep 17 00:00:00 2001 From: sunke <18850253506@163.com> Date: Thu, 19 Dec 2019 14:01:33 +0800 Subject: [PATCH 2/6] =?UTF-8?q?=E5=B9=B3=E5=8F=B0=E5=B8=81=E5=85=85?= =?UTF-8?q?=E5=80=BC=E5=8C=BA=E6=9C=8D=E9=9A=90=E8=97=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Home/Controller/DownloadController.class.php | 15 ++++++++++----- .../Home/Controller/PlayersController.class.php | 13 +++++++++---- 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/Application/Home/Controller/DownloadController.class.php b/Application/Home/Controller/DownloadController.class.php index 64a0138bb..e63c0e3cb 100644 --- a/Application/Home/Controller/DownloadController.class.php +++ b/Application/Home/Controller/DownloadController.class.php @@ -1909,9 +1909,14 @@ class DownloadController extends BaseController { foreach($data as $key => $v) { $v['create_time'] = date('Y-m-d H:i:s',$v['create_time']); $promoteInfo = M('promote','tab_')->field("account")->where(['id' => intval($v['promote_id'])])->find(); - $serverId = $v['server_id']; - $gameId = $v['game_id']; - $serverInfo = M('server','tab_')->field('server_name')->where(['server_num'=>$serverId,'game_id'=>$gameId])->find(); + if($v['server_id'] != 0) { + $serverId1 = $v['server_id']; + $gameId = $v['game_id']; + $serverInfo = M('server','tab_')->field('server_name')->where(['server_num'=>$serverId1,'game_id'=>$gameId])->find(); + $servername = $serverInfo['server_name']; + }else { + $servername = ""; + } $v['promote_id']= $promoteInfo['account']; if(empty($v['extend'])) { $v['extend'] = $v['order_id']; @@ -1921,7 +1926,7 @@ class DownloadController extends BaseController { $csvData['user_account'] = $v['user_account']; $csvData['game_name'] = $v['game_name']; $csvData['promote_id'] = $v['promote_id']; - $csvData['server_name'] = $serverInfo['server_name']; + $csvData['server_name'] = $servername; $csvData['user_id'] = $v['game_player_id']; $csvData['game_player_name'] = $v['game_player_name']; $csvData['price'] = $v['price']; @@ -1975,7 +1980,7 @@ class DownloadController extends BaseController { ->field('account,device_number,promote_account,register_time,register_ip,login_time,login_ip') ->where($map) ->limit(($i-1)*$perSize ,$perSize) - ->order('tab_user.id desc') + ->order('tab_user.id desc') ->select(); foreach($data as $value1) { $csvData['account'] = $this->encryption($value1['account']); diff --git a/Application/Home/Controller/PlayersController.class.php b/Application/Home/Controller/PlayersController.class.php index 4ae5e27b7..950edaee1 100644 --- a/Application/Home/Controller/PlayersController.class.php +++ b/Application/Home/Controller/PlayersController.class.php @@ -80,10 +80,15 @@ class PlayersController extends BaseController { $rs[$key]['extend'] = encryption($v['extend']); $rs[$key]['create_time'] = date('Y-m-d H:i:s',$v['create_time']); $promoteInfo = M('promote','tab_')->field("account")->where(['id' => intval($v['promote_id'])])->find(); - $serverId1 = $v['server_id']; - $gameId = $v['game_id']; - $serverInfo = M('server','tab_')->field('server_name')->where(['server_num'=>$serverId1,'game_id'=>$gameId])->find(); - $rs[$key]['server_name'] = $serverInfo['server_name']; + if($v['server_id'] != 0) { + $serverId1 = $v['server_id']; + $gameId = $v['game_id']; + $serverInfo = M('server','tab_')->field('server_name')->where(['server_num'=>$serverId1,'game_id'=>$gameId])->find(); + $rs[$key]['server_name'] = $serverInfo['server_name']; + }else { + $rs[$key]['server_name'] = ""; + } + $rs[$key]['promote_id']= $promoteInfo['account']; } From b2ab2c9df095e7b7b91bafcec74695229fbfb172 Mon Sep 17 00:00:00 2001 From: sunke <18850253506@163.com> Date: Thu, 19 Dec 2019 14:11:19 +0800 Subject: [PATCH 3/6] =?UTF-8?q?=E9=9A=90=E8=97=8F=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Home/Controller/DownloadController.class.php | 2 ++ Application/Home/Controller/PlayersController.class.php | 2 ++ 2 files changed, 4 insertions(+) diff --git a/Application/Home/Controller/DownloadController.class.php b/Application/Home/Controller/DownloadController.class.php index e63c0e3cb..36903bcbd 100644 --- a/Application/Home/Controller/DownloadController.class.php +++ b/Application/Home/Controller/DownloadController.class.php @@ -1916,6 +1916,8 @@ class DownloadController extends BaseController { $servername = $serverInfo['server_name']; }else { $servername = ""; + $v['game_player_id'] = ""; + $v['game_player_name'] = ""; } $v['promote_id']= $promoteInfo['account']; if(empty($v['extend'])) { diff --git a/Application/Home/Controller/PlayersController.class.php b/Application/Home/Controller/PlayersController.class.php index 950edaee1..47a2e07f2 100644 --- a/Application/Home/Controller/PlayersController.class.php +++ b/Application/Home/Controller/PlayersController.class.php @@ -87,6 +87,8 @@ class PlayersController extends BaseController { $rs[$key]['server_name'] = $serverInfo['server_name']; }else { $rs[$key]['server_name'] = ""; + $rs[$key]['game_player_id'] = ""; + $rs[$key]['game_player_name'] = ""; } $rs[$key]['promote_id']= $promoteInfo['account']; From ce0e9f943d15c16941f38f57ff7b495b08307f00 Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Thu, 19 Dec 2019 14:46:04 +0800 Subject: [PATCH 4/6] =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=9D=83=E9=99=90bug?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Admin/Common/extend.php | 20 +++++++++++-------- .../Admin/Model/PromoteModel.class.php | 8 +++++--- 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/Application/Admin/Common/extend.php b/Application/Admin/Common/extend.php index b532ae572..882be5ec0 100644 --- a/Application/Admin/Common/extend.php +++ b/Application/Admin/Common/extend.php @@ -1625,10 +1625,12 @@ function setPowerPromoteIds(&$map, $column = 'promote_id') { function get_promote_listOther($select='') { - $promoteRoot = getPowerPromoteIds(); - if ($promoteRoot) { - $map['id'] =array('in',$promoteRoot); - } +// $promoteRoot = getPowerPromoteIds(); +// if ($promoteRoot) { +// $map['id'] =array('in',$promoteRoot); +// } + + setPowerPromoteIds($map,'id'); $list = M("Promote","tab_")->field('id,account,balance_coin')->where($map)->select();//where("status=1")-> if (empty($list)){return '';} @@ -1652,10 +1654,12 @@ function promote_listsOther($type){ $map = ''; } - $promoteRoot = getPowerPromoteIds(); - if ($promoteRoot) { - $map['id'] =array('in',$promoteRoot); - } +// $promoteRoot = getPowerPromoteIds(); +// if ($promoteRoot) { +// $map['id'] =array('in',$promoteRoot); +// } + + setPowerPromoteIds($map,'id'); $data = M('promote','tab_')->where($map)->select(); diff --git a/Application/Admin/Model/PromoteModel.class.php b/Application/Admin/Model/PromoteModel.class.php index 22ce7b8cd..5190c4bcc 100644 --- a/Application/Admin/Model/PromoteModel.class.php +++ b/Application/Admin/Model/PromoteModel.class.php @@ -388,9 +388,11 @@ class PromoteModel extends Model{ public function getPromotersByLevelOther($level=1) { - $result = []; - $promoteRoot = getPowerPromoteIds(); - $result = $this->field("*")->where("level={$level} and id IN({$promoteRoot})")->select(); + + $where['level'] = $level; + setPowerPromoteIds($where,'id'); + + $result = $this->field("*")->where($where)->select(); foreach ($result as &$item) { $item['nickname'] = $item['account'] . ($item['nickname'] ? "({$item['nickname']})" : ""); } From e7b2f57a9363bde7981a6246576c73862ba9604c Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Thu, 19 Dec 2019 14:49:52 +0800 Subject: [PATCH 5/6] =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=9D=83=E9=99=90bug?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Admin/Controller/MemberController.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Application/Admin/Controller/MemberController.class.php b/Application/Admin/Controller/MemberController.class.php index 8f71e70a2..2d1408ff4 100644 --- a/Application/Admin/Controller/MemberController.class.php +++ b/Application/Admin/Controller/MemberController.class.php @@ -109,7 +109,7 @@ class MemberController extends ThinkController $map['tab_user.promote_id'] = 0; } else { - if ($promoteRoot) { + if ($promoteRoot||$promoteRoot!='all') { $promoteRoot = " and id IN({$promoteRoot})"; } From 5f3e71e8a840c137c9798156bd6223384158df32 Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Thu, 19 Dec 2019 14:51:32 +0800 Subject: [PATCH 6/6] =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=9D=83=E9=99=90bug?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Admin/Controller/MemberController.class.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Application/Admin/Controller/MemberController.class.php b/Application/Admin/Controller/MemberController.class.php index 2d1408ff4..d6baa0d01 100644 --- a/Application/Admin/Controller/MemberController.class.php +++ b/Application/Admin/Controller/MemberController.class.php @@ -109,9 +109,13 @@ class MemberController extends ThinkController $map['tab_user.promote_id'] = 0; } else { - if ($promoteRoot||$promoteRoot!='all') { + if ($promoteRoot) { $promoteRoot = " and id IN({$promoteRoot})"; } + if ($promoteRoot!='all') { + $promoteRoot = ''; + } + $promoter_ids = D("Promote")->where("(chain like '%/{$_REQUEST['promote_id']}/%' or id={$_REQUEST['promote_id']})".$promoteRoot)->field('id')->select(); if ($promoter_ids) {