v1.20.0 更新

This commit is contained in:
click33
2021-06-16 20:24:23 +08:00
parent 1df8465e20
commit c6d3cda4a4
38 changed files with 81 additions and 51 deletions
+2 -2
View File
@@ -14,7 +14,7 @@ Sa-token默认将会话数据保存在内存中,此模式读写速度最快,
<dependency>
<groupId>cn.dev33</groupId>
<artifactId>sa-token-dao-redis</artifactId>
<version>1.19.0</version>
<version>1.20.0</version>
</dependency>
```
优点:兼容性好,缺点:Session序列化后基本不可读,对开发者来讲等同于乱码
@@ -26,7 +26,7 @@ Sa-token默认将会话数据保存在内存中,此模式读写速度最快,
<dependency>
<groupId>cn.dev33</groupId>
<artifactId>sa-token-dao-redis-jackson</artifactId>
<version>1.19.0</version>
<version>1.20.0</version>
</dependency>
```
优点:Session序列化后可读性强,可灵活手动修改,缺点:兼容性稍差
+1 -1
View File
@@ -14,7 +14,7 @@
``` java
// 标记当前会话登录的账号id
// 建议的参数类型:long | int | String, 不可以传入复杂类型,如:User、Admin等等
StpUtil.login(Object id);
StpUtil.login(Object id);
// 当前会话注销登录
StpUtil.logout();
+1 -1
View File
@@ -33,7 +33,7 @@ public class StpUserUtil {
/**
* 账号体系标识
*/
public static final String KEY = "user"; // 将 LoginType 从`login`改为`user`
public static final String TYPE = "user"; // 将 LoginType 从`login`改为`user`
// 其它代码 ...