mirror of
https://gitee.com/bookshelfplus/bookshelfplus
synced 2025-09-14 20:41:38 +08:00
用户注册功能实现;用户表添加email字段
This commit is contained in:
@@ -8,8 +8,8 @@ public interface UserService {
|
||||
/**
|
||||
* 用户登录
|
||||
*
|
||||
* @param username
|
||||
* @param encryptPwd
|
||||
* @param username 用户名
|
||||
* @param encryptPwd 加密后密码
|
||||
*/
|
||||
UserModel userLogin(String username, String encryptPwd);
|
||||
|
||||
@@ -17,7 +17,7 @@ public interface UserService {
|
||||
* 通过用户Id获取用户
|
||||
*
|
||||
* @param id 用户Id
|
||||
* @return
|
||||
* @return UserModel
|
||||
*/
|
||||
UserModel getUserById(Integer id);
|
||||
|
||||
@@ -25,8 +25,17 @@ public interface UserService {
|
||||
* 检查用户令牌是否有效,并返回令牌对应的用户 UserModel
|
||||
* (令牌无效直接抛出异常)
|
||||
*
|
||||
* @param token
|
||||
* @return
|
||||
* @param token 用户令牌
|
||||
* @return UserModel
|
||||
*/
|
||||
UserModel getUserByToken(RedisTemplate redisTemplate, String token) throws BusinessException;
|
||||
|
||||
/**
|
||||
* 用户注册
|
||||
*
|
||||
* @param username 用户名
|
||||
* @param encryptPwd 加密后密码
|
||||
* @return 注册成功返回true,否则返回false
|
||||
*/
|
||||
Boolean userRegister(String username, String encryptPwd) throws BusinessException;
|
||||
}
|
||||
|
Reference in New Issue
Block a user