访客,用户资料列表新增增加访客计数
This commit is contained in:
parent
d910c996c6
commit
420e9b1b39
@ -1,6 +1,7 @@
|
||||
package com.red.circle.other.app.command.user.query;
|
||||
|
||||
import com.red.circle.common.business.core.AppBusinessUtils;
|
||||
import com.red.circle.common.business.dto.cmd.app.AppUserIdCmd;
|
||||
import com.red.circle.component.redis.service.RedisService;
|
||||
import com.red.circle.framework.core.asserts.ResponseAssert;
|
||||
import com.red.circle.framework.core.response.CommonErrorCode;
|
||||
@ -8,6 +9,7 @@ import com.red.circle.other.app.convertor.user.UserProfileAppConvertor;
|
||||
import com.red.circle.other.app.dto.clientobject.user.user.UserLevelCO;
|
||||
import com.red.circle.other.app.dto.cmd.user.user.UserProfileQryCmd;
|
||||
import com.red.circle.other.app.service.room.RoomProfileService;
|
||||
import com.red.circle.other.app.service.user.relation.UserSupportRelationService;
|
||||
import com.red.circle.other.domain.gateway.user.UserProfileGateway;
|
||||
import com.red.circle.other.domain.gateway.user.ability.UserRegionGateway;
|
||||
import com.red.circle.other.domain.model.user.UserProfile;
|
||||
@ -39,6 +41,7 @@ public class UserProfileUseQryExe {
|
||||
private final UserProfileAppConvertor userProfileAppConvertor;
|
||||
private final RoomProfileManagerService roomProfileManagerService;
|
||||
private final RedisService redisService;
|
||||
private final UserSupportRelationService userRelationInterviewService;
|
||||
|
||||
public UserProfileDTO execute(UserProfileQryCmd cmd) {
|
||||
UserProfile userProfile = getUserProfile(cmd);
|
||||
@ -74,6 +77,16 @@ public class UserProfileUseQryExe {
|
||||
}
|
||||
String isUpdateCountry = redisService.getString("IS_UPDATE_COUNTRY:" + cmd.requiredReqUserId());
|
||||
userProfileDTO.setIsUpdateCountry(StringUtils.isNotBlank(isUpdateCountry) ? isUpdateCountry : "0");
|
||||
|
||||
// 增加访客记录
|
||||
if (!Objects.equals(userProfile.getId(), cmd.requiredReqUserId())) {
|
||||
AppUserIdCmd userIdCmd = new AppUserIdCmd();
|
||||
userIdCmd.setUserId(cmd.getUserId());
|
||||
userIdCmd.setReqUserId(cmd.requiredReqUserId());
|
||||
userIdCmd.setReqSysOrigin(cmd.getReqSysOrigin());
|
||||
userRelationInterviewService.addVisitor(userIdCmd);
|
||||
}
|
||||
|
||||
return userProfileDTO;
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user