|
@@ -19,6 +19,8 @@ import shop.alien.entity.store.vo.LifePinglunVo;
|
|
|
import shop.alien.entity.store.vo.LifeUserDynamicsVo;
|
|
import shop.alien.entity.store.vo.LifeUserDynamicsVo;
|
|
|
import shop.alien.mapper.*;
|
|
import shop.alien.mapper.*;
|
|
|
import shop.alien.util.common.constant.CommentSourceTypeEnum;
|
|
import shop.alien.util.common.constant.CommentSourceTypeEnum;
|
|
|
|
|
+import shop.alien.util.type.PhoneTypeIdResult;
|
|
|
|
|
+import shop.alien.util.type.TypeUtil;
|
|
|
|
|
|
|
|
import java.util.*;
|
|
import java.util.*;
|
|
|
import java.util.concurrent.CompletableFuture;
|
|
import java.util.concurrent.CompletableFuture;
|
|
@@ -63,6 +65,9 @@ public class LifeUserDynamicsService extends ServiceImpl<LifeUserDynamicsMapper,
|
|
|
|
|
|
|
|
private final CommonRatingMapper commonRatingMapper;
|
|
private final CommonRatingMapper commonRatingMapper;
|
|
|
|
|
|
|
|
|
|
+ private final TypeUtil typeUtil;
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
public int addLiulanCount(String id) {
|
|
public int addLiulanCount(String id) {
|
|
|
LambdaUpdateWrapper<LifeUserDynamics> lambdaUpdateWrapper = new LambdaUpdateWrapper<>();
|
|
LambdaUpdateWrapper<LifeUserDynamics> lambdaUpdateWrapper = new LambdaUpdateWrapper<>();
|
|
|
lambdaUpdateWrapper.eq(LifeUserDynamics::getId, id);
|
|
lambdaUpdateWrapper.eq(LifeUserDynamics::getId, id);
|
|
@@ -100,6 +105,12 @@ public class LifeUserDynamicsService extends ServiceImpl<LifeUserDynamicsMapper,
|
|
|
|
|
|
|
|
public int addOrUpdateStore(LifeUserDynamics store) {
|
|
public int addOrUpdateStore(LifeUserDynamics store) {
|
|
|
if (StringUtils.isEmpty(store.getId())) {
|
|
if (StringUtils.isEmpty(store.getId())) {
|
|
|
|
|
+
|
|
|
|
|
+ //调用工具包,把电话号转换为用户分类和用户id
|
|
|
|
|
+ PhoneTypeIdResult phoneTypeIdResult =typeUtil.resolveTypeAndId(store.getPhoneId());
|
|
|
|
|
+ store.setPhoneUserType(phoneTypeIdResult.getType());
|
|
|
|
|
+ store.setPhoneRefId(phoneTypeIdResult.getId());
|
|
|
|
|
+
|
|
|
Date nowDate = new Date(System.currentTimeMillis());
|
|
Date nowDate = new Date(System.currentTimeMillis());
|
|
|
store.setCreatedTime(new java.sql.Timestamp(nowDate.getTime()));
|
|
store.setCreatedTime(new java.sql.Timestamp(nowDate.getTime()));
|
|
|
return lifeUserDynamicsMapper.insert(store);
|
|
return lifeUserDynamicsMapper.insert(store);
|