|
|
@ -283,9 +283,7 @@ class FinancePromoteController extends AdminController
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$map['s.pay_status']=1;
|
|
|
|
$map['s.pay_status']=1;
|
|
|
|
$map['s.is_check']=1;
|
|
|
|
$map['s.is_check']=1;
|
|
|
|
if(IS_SUBSITE){
|
|
|
|
D("Spend")->addSubsiteWhere($map,"s");
|
|
|
|
$map['s.partner_type']=PARTNER_TYPE;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
$field= "SUM(CASE WHEN pay_way > 0 THEN pay_amount ELSE 0 END) as cash_count,
|
|
|
|
$field= "SUM(CASE WHEN pay_way > 0 THEN pay_amount ELSE 0 END) as cash_count,
|
|
|
|
SUM(CASE WHEN pay_way = 0 THEN pay_amount ELSE 0 END) as balance_coin_count,
|
|
|
|
SUM(CASE WHEN pay_way = 0 THEN pay_amount ELSE 0 END) as balance_coin_count,
|
|
|
|
SUM(CASE WHEN pay_way = -1 THEN pay_amount ELSE 0 END) as bind_coin_count,
|
|
|
|
SUM(CASE WHEN pay_way = -1 THEN pay_amount ELSE 0 END) as bind_coin_count,
|
|
|
@ -516,9 +514,7 @@ class FinancePromoteController extends AdminController
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$map['s.pay_status']=1;
|
|
|
|
$map['s.pay_status']=1;
|
|
|
|
$map['s.is_check']=1;
|
|
|
|
$map['s.is_check']=1;
|
|
|
|
if(IS_SUBSITE){
|
|
|
|
D("Spend")->addSubsiteWhere($map,"s");
|
|
|
|
$map['s.partner_type']=PARTNER_TYPE;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
// dd($map);
|
|
|
|
// dd($map);
|
|
|
|
$field= "SUM(CASE WHEN pay_way > 0 THEN pay_amount ELSE 0 END) as cash_count,
|
|
|
|
$field= "SUM(CASE WHEN pay_way > 0 THEN pay_amount ELSE 0 END) as cash_count,
|
|
|
|
SUM(CASE WHEN pay_way = 0 THEN pay_amount ELSE 0 END) as balance_coin_count,
|
|
|
|
SUM(CASE WHEN pay_way = 0 THEN pay_amount ELSE 0 END) as balance_coin_count,
|
|
|
@ -608,9 +604,7 @@ class FinancePromoteController extends AdminController
|
|
|
|
$map['promote.admin_id'] = ['gt', 0];
|
|
|
|
$map['promote.admin_id'] = ['gt', 0];
|
|
|
|
$map['s.market_admin_id'] = ['gt', 0];
|
|
|
|
$map['s.market_admin_id'] = ['gt', 0];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if(IS_SUBSITE){
|
|
|
|
D("Spend")->addSubsiteWhere($map,"s");
|
|
|
|
$map['s.partner_type']=PARTNER_TYPE;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
//获取推广员
|
|
|
|
//获取推广员
|
|
|
|
$title = '';
|
|
|
|
$title = '';
|
|
|
|
self::setPromoteMap($map,"s.promote_id",$title,false);
|
|
|
|
self::setPromoteMap($map,"s.promote_id",$title,false);
|
|
|
@ -746,9 +740,7 @@ class FinancePromoteController extends AdminController
|
|
|
|
if ($adminId > 0) {
|
|
|
|
if ($adminId > 0) {
|
|
|
|
$map['market_admin_id'] = $adminId;
|
|
|
|
$map['market_admin_id'] = $adminId;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if(IS_SUBSITE){
|
|
|
|
D("Spend")->addSubsiteWhere($map);
|
|
|
|
$map['partner_type']=PARTNER_TYPE;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
/* if (!empty(I('develop_type'))) {
|
|
|
|
/* if (!empty(I('develop_type'))) {
|
|
|
|
$map['company.develop_type'] = I('develop_type');
|
|
|
|
$map['company.develop_type'] = I('develop_type');
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -1019,6 +1011,7 @@ class FinancePromoteController extends AdminController
|
|
|
|
if (!empty(I('user_nickname'))) {
|
|
|
|
if (!empty(I('user_nickname'))) {
|
|
|
|
$map['tab_spend.game_player_name'] = array('like',I("user_nickname").'%');
|
|
|
|
$map['tab_spend.game_player_name'] = array('like',I("user_nickname").'%');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
D("Spend")->addSubsiteWhere($map,"s");
|
|
|
|
$field = "pay_order_number,FROM_UNIXTIME(payed_time) as pay_time,tab_spend.user_account,
|
|
|
|
$field = "pay_order_number,FROM_UNIXTIME(payed_time) as pay_time,tab_spend.user_account,
|
|
|
|
tab_spend.user_nickname,tab_spend.game_name,tab_spend.promote_account,spend_ip,tab_spend.server_name,tab_spend.sdk_version,
|
|
|
|
tab_spend.user_nickname,tab_spend.game_name,tab_spend.promote_account,spend_ip,tab_spend.server_name,tab_spend.sdk_version,
|
|
|
|
game_player_name,pay_amount,cost,pay_way";
|
|
|
|
game_player_name,pay_amount,cost,pay_way";
|
|
|
|