实名认证 未完成二次实名数据修改
This commit is contained in:
@@ -316,18 +316,29 @@ class UserData extends Model
|
||||
//查询是否已经提交过数据了
|
||||
$is_real = db::name('user_auth')->where(['card_id' => $id_card,'mobile' =>$user_mobile])->find();
|
||||
if($is_real){
|
||||
return ['code' => 0, 'msg' => '已经审核通过!请勿重复提交!','data' =>null];
|
||||
if($is_real['is_real'] == 1){
|
||||
return ['code' => 0, 'msg' => '已经审核通过!请勿重复提交!','data' =>null];
|
||||
}else{
|
||||
$auth = [
|
||||
'mobile' => $user_mobile,
|
||||
'real_name' => $real_name,
|
||||
'card_id' => $id_card,
|
||||
'is_real' => 3,
|
||||
'updatetime' => time(),
|
||||
];
|
||||
db::name('user_auth')->where(['id' => $is_real['id']])->update($auth);
|
||||
}
|
||||
}else{
|
||||
$auth = [
|
||||
'mobile' => $user_mobile,
|
||||
'real_name' => $real_name,
|
||||
'card_id' => $id_card,
|
||||
'is_real' => 3,
|
||||
'createtime' => time(),
|
||||
];
|
||||
db::name('user_auth')->insert($auth);
|
||||
}
|
||||
|
||||
$auth = [
|
||||
'mobile' => $user_mobile,
|
||||
'real_name' => $real_name,
|
||||
'card_id' => $id_card,
|
||||
'is_real' => 3,
|
||||
'createtime' => time(),
|
||||
];
|
||||
db::name('user_auth')->insert($auth);
|
||||
|
||||
$config = get_system_config();
|
||||
//获取Access Token
|
||||
$access_token = $this->redis->get('access_token_'.$config['tencent_app_id']);
|
||||
|
||||
Reference in New Issue
Block a user