Commit 9e032c77 by 冷斌

update

parent 94ede389
...@@ -55,10 +55,13 @@ class PromotersController extends AdminbaseController{ ...@@ -55,10 +55,13 @@ class PromotersController extends AdminbaseController{
foreach($users as $k=>$v){ foreach($users as $k=>$v){
$path=setpath($v['id']); $path=setpath($v['id']);
$uids=$Proxy->where("type = 0 and path like '%{$path}%'")->getField('uid',true); $uids=$Proxy->where("type = 0 and path like '%{$path}%'")->getField('uid',true);
var_dump($uids);
if(!$uids){ if(!$uids){
$uids=[]; $uids=[];
array_push($uids,'0'); array_push($uids,'0');
} }
var_dump($uids);
die;
$map=[]; $map=[];
$map['uid'] = array('in',$uids); $map['uid'] = array('in',$uids);
...@@ -75,8 +78,7 @@ class PromotersController extends AdminbaseController{ ...@@ -75,8 +78,7 @@ class PromotersController extends AdminbaseController{
// $total_coin='0'; // $total_coin='0';
// } // }
// $v['total_coin']=$total_coin; // $v['total_coin']=$total_coin;
var_dump($uids);
die;
$total_coin = M('users_coinrecord') $total_coin = M('users_coinrecord')
// ->select("sum('totalcoin') as sum") // ->select("sum('totalcoin') as sum")
->where("uid in ('{$uids}') and type='expend' and action in ('sendgift','sendbarrage')") ->where("uid in ('{$uids}') and type='expend' and action in ('sendgift','sendbarrage')")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment