Эх сурвалжийг харах

fix: 用户登录之后没有相关头像

max 7 сар өмнө
parent
commit
e5b413a1a9

+ 4 - 4
src/modules/base/service/sys/user.ts

@@ -126,12 +126,12 @@ export class BaseSysUserService extends BaseService {
 
     if (merchant) {
       // 分别查询个人或企业信息
-      individualInfo = await this.individualEntity.findOne({
-        where: { merchant: { id: merchant.id } },
+      individualInfo = await this.individualEntity.findOneBy({
+        merchantId: merchant.mchId
       });
 
-      businessInfo = await this.businessEntity.findOne({
-        where: { merchant: { id: merchant.id } },
+      businessInfo = await this.businessEntity.findOneBy({
+        merchantId: merchant.mchId
       });
     }