From 7b428dc9abf2670c27d2caa7b508bbf5efee9579 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E9=92=8A?= Date: Wed, 7 Jan 2026 19:15:50 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=AC=E4=BC=9A=E6=8B=A6=E6=88=AA=E5=AE=9E?= =?UTF-8?q?=E5=90=8D=E8=AE=A4=E8=AF=81=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/api/model/Guild.php | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/application/api/model/Guild.php b/application/api/model/Guild.php index 561377bb..51186753 100644 --- a/application/api/model/Guild.php +++ b/application/api/model/Guild.php @@ -122,7 +122,7 @@ class Guild extends Model // return ['code' => 0, 'msg' => '参数错误', 'data' => null]; // } //查询是否实名认证 - $is_real = model('UserData')->real_name_info($user_id); + $is_real = model('api/UserData')->real_name_info($user_id); if($is_real['code']==0){ return ['code' => 0, 'msg' => '请先实名认证','data' => null]; }else{ @@ -1124,12 +1124,18 @@ class Guild extends Model */ public function join_guild($guild_id,$user_id=0,$settlement_ratio = 0) { - $user_info = model('User')->get_user_info($user_id); + $user_info = db::name('user')->where(['id'=>$user_id])->find(); if(!$user_info){ return ['code' => 0, 'msg' => '参数错误', 'data' => null]; } - if($user_info['is_real']!=1 || empty($user_info['card_id'])){ - return ['code' => 0, 'msg' => '请先实名认证', 'data' => null]; + //查询是否实名认证 + $is_real = model('api/UserData')->real_name_info($user_id); + if($is_real['code']==0){ + return ['code' => 0, 'msg' => '请先实名认证','data' => null]; + }else{ + if($is_real['data']['is_real'] !=1){ + return ['code' => 0, 'msg' => '请先实名认证','data' => null]; + } } //公会是否存在 $guild_info = db::name('vs_guild')->where(['id'=>$guild_id,'delete_time'=>0])->find();