|
|
|
@ -1,17 +1,11 @@
|
|
|
|
|
package com.luoo.user.service;
|
|
|
|
|
|
|
|
|
|
import java.util.*;
|
|
|
|
|
import java.util.concurrent.TimeUnit;
|
|
|
|
|
|
|
|
|
|
import javax.persistence.criteria.CriteriaBuilder;
|
|
|
|
|
import javax.persistence.criteria.CriteriaQuery;
|
|
|
|
|
import javax.persistence.criteria.Predicate;
|
|
|
|
|
import javax.persistence.criteria.Root;
|
|
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
|
|
|
|
|
|
|
import com.luoo.user.constants.Constants;
|
|
|
|
|
import com.luoo.user.dao.UserDao;
|
|
|
|
|
import com.luoo.user.pojo.User;
|
|
|
|
|
import com.luoo.user.util.NickNameUtil;
|
|
|
|
|
import org.apache.commons.lang3.RandomStringUtils;
|
|
|
|
|
import org.springframework.amqp.rabbit.core.RabbitTemplate;
|
|
|
|
|
import org.springframework.beans.BeanUtils;
|
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
|
import org.springframework.data.domain.Page;
|
|
|
|
|
import org.springframework.data.domain.PageRequest;
|
|
|
|
@ -19,20 +13,18 @@ import org.springframework.data.jpa.domain.Specification;
|
|
|
|
|
import org.springframework.data.redis.core.RedisTemplate;
|
|
|
|
|
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
|
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
import util.IdWorker;
|
|
|
|
|
|
|
|
|
|
import com.apifan.common.random.RandomSource;
|
|
|
|
|
import com.luoo.user.constants.Constants;
|
|
|
|
|
import com.luoo.user.dao.UserDao;
|
|
|
|
|
import com.luoo.user.dto.response.UserRespDTO;
|
|
|
|
|
import com.luoo.user.enumerate.Gender;
|
|
|
|
|
import com.luoo.user.pojo.User;
|
|
|
|
|
import com.luoo.user.util.NickNameUtil;
|
|
|
|
|
|
|
|
|
|
import util.JwtUtil;
|
|
|
|
|
|
|
|
|
|
import javax.persistence.criteria.CriteriaBuilder;
|
|
|
|
|
import javax.persistence.criteria.CriteriaQuery;
|
|
|
|
|
import javax.persistence.criteria.Predicate;
|
|
|
|
|
import javax.persistence.criteria.Root;
|
|
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
|
|
import java.util.*;
|
|
|
|
|
import java.util.concurrent.TimeUnit;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 服务层
|
|
|
|
|
*
|
|
|
|
@ -119,6 +111,11 @@ public class UserService {
|
|
|
|
|
return userDao.findById(id).get();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public List<User> findByIds(List<String> ids) {
|
|
|
|
|
return userDao.findUserByIds(ids);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 增加
|
|
|
|
|
*
|
|
|
|
|