Merge branch 'release-1.0.0' of 47.111.118.107:wmtx/platform into release-1.0.0

master
zhanglingsheng 5 years ago
commit 043de55e0b

@ -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();

@ -112,6 +112,10 @@ class MemberController extends ThinkController
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) {

@ -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'] = "官方渠道";

@ -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']})" : "");
}

@ -1909,9 +1909,16 @@ 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['game_player_id'] = "";
$v['game_player_name'] = "";
}
$v['promote_id']= $promoteInfo['account'];
if(empty($v['extend'])) {
$v['extend'] = $v['order_id'];
@ -1921,7 +1928,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'];

@ -80,10 +80,17 @@ 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]['game_player_id'] = "";
$rs[$key]['game_player_name'] = "";
}
$rs[$key]['promote_id']= $promoteInfo['account'];
}

Loading…
Cancel
Save