<?php
/*
 本代码由 焕岱科技 创建
 技术支持 WX：15285007200
 严禁反编译、逆向等任何形式的侵权行为，违者将追究法律责任
*/

namespace app\admin\controller\bbfxshop\paihangbang;

use app\admin\controller\bbfxshop\Base;
use think\Db;


class User extends Base
{

    public $model = null;
    public function _initialize(){
        parent::_initialize();
        $this->model = new \app\common\model\bbfxshop\Paihangbang;
    }
    
    public function getList(){
        $current = intval($this->param("current/d"));
        $result = $this->model->getRankingUser($current);
        __result($result);
    }
    
    public function setAbonus(){
        $result = $this->model->setAbonusReward(true);
        if($result['code'] == 1){
            \app\admin\model\AdminLog::record("排行榜-手动结算","手动结算排行榜上一期排名分红",['abonus_money'=>$result['data']['abonus_money']]);
        }
        __result($result);
    }
}