save([ 'money' => $this['money'] - $money, 'freeze_money' => $this['freeze_money'] + $money, ]); } /** * 累计分销商成员数量 * @param $dealer_id * @param $level * @return int|true * @throws \think\Exception * @throws \think\exception\DbException */ public static function setMemberInc($dealer_id, $level) { $fields = [1 => 'first_num', 2 => 'second_num', 3 => 'third_num']; $model = static::detail($dealer_id); return $model->setInc($fields[$level]); } }