下级用户绑定手机号会绑定到上级的问题修复

This commit is contained in:
evoxwht 2023-06-20 17:31:33 +08:00
parent 6d92c7f1b1
commit 0272a3ac74

View File

@ -85,7 +85,7 @@ class WechatUserServices extends BaseServices
*/
public function openidToUid($openid, string $openidType = 'openid')
{
$uid = $this->dao->value([[$openidType, '=', $openid], ['user_type', '<>', 'h5']], 'uid');
$uid = $this->dao->value([$openidType => $openid, 'is_del' => 0], 'uid');
if (!$uid)
throw new AdminException(400710);
return $uid;