|
|
@ -13,6 +13,7 @@ import java.util.function.Function;
|
|
|
|
import java.util.stream.Collectors;
|
|
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
|
|
|
|
|
|
import com.github.houbb.sensitive.word.bs.SensitiveWordBs;
|
|
|
|
import com.github.houbb.sensitive.word.bs.SensitiveWordBs;
|
|
|
|
|
|
|
|
import com.luoo.user.dao.UserMessageDao;
|
|
|
|
import com.luoo.user.dto.TotalCommentVo;
|
|
|
|
import com.luoo.user.dto.TotalCommentVo;
|
|
|
|
import com.luoo.user.pojo.*;
|
|
|
|
import com.luoo.user.pojo.*;
|
|
|
|
import com.luoo.user.service.*;
|
|
|
|
import com.luoo.user.service.*;
|
|
|
@ -102,6 +103,9 @@ public class MyController extends BaseController {
|
|
|
|
@Autowired
|
|
|
|
@Autowired
|
|
|
|
private RedisTemplate redisTemplate;
|
|
|
|
private RedisTemplate redisTemplate;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private UserMessageDao userMessageDao;
|
|
|
|
|
|
|
|
|
|
|
|
@ApiOperation(value = "1.获取个人信息", notes = "游客无法获取个人信息")
|
|
|
|
@ApiOperation(value = "1.获取个人信息", notes = "游客无法获取个人信息")
|
|
|
|
@GetMapping("/userInfo")
|
|
|
|
@GetMapping("/userInfo")
|
|
|
|
@GlobalInterceptor(checkAppUserLogin = true)
|
|
|
|
@GlobalInterceptor(checkAppUserLogin = true)
|
|
|
@ -356,7 +360,12 @@ public class MyController extends BaseController {
|
|
|
|
userRespDTO.setThumbUpCount(totalCommentVo.getTotalThumbup());
|
|
|
|
userRespDTO.setThumbUpCount(totalCommentVo.getTotalThumbup());
|
|
|
|
userRespDTO.setCommentReplyCount(totalCommentVo.getTotalComment());
|
|
|
|
userRespDTO.setCommentReplyCount(totalCommentVo.getTotalComment());
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
UserMessage userMessage = userMessageDao.findTopByUserIdOrderBySendTimeDesc(user.getId());
|
|
|
|
|
|
|
|
userRespDTO.setHaveNewMessage(false);
|
|
|
|
|
|
|
|
if (null!=userMessage) {
|
|
|
|
|
|
|
|
int read = userMessage.getHaveRead();
|
|
|
|
|
|
|
|
userRespDTO.setHaveNewMessage(read==0?true:false);
|
|
|
|
|
|
|
|
}
|
|
|
|
return userRespDTO;
|
|
|
|
return userRespDTO;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|