微信网页登录

This commit is contained in:
starrySky
2024-04-09 10:17:49 +08:00
parent b2f6921ef1
commit e8b6c8e0aa
128 changed files with 2861 additions and 4243 deletions

View File

@@ -0,0 +1,43 @@
package com.starry.admin.common.conf;
import com.alibaba.ttl.TransmittableThreadLocal;
import com.starry.admin.modules.clear.module.entity.PlayClerkUserInfoEntity;
import com.starry.admin.modules.custom.module.entity.PlayCustomUserInfoEntity;
/**
* @author : huchuansai
* @since : 2024/4/2 12:10 AM
*/
public class ThreadLocalRequestDetail {
private static final TransmittableThreadLocal<Object> threadLocal = new TransmittableThreadLocal<>();
/**
* 设置请求信息到当前线程中
*/
public static void setRequestDetail(Object data) {
threadLocal.set(data);
}
/**
* 从当前线程中获取请求信息
*/
public static Object getRequestDetail() {
return threadLocal.get();
}
public static PlayClerkUserInfoEntity getClerkUserInfo() {
return (PlayClerkUserInfoEntity) threadLocal.get();
}
public static PlayCustomUserInfoEntity getCustomUserInfo() {
return (PlayCustomUserInfoEntity) threadLocal.get();
}
/**
* 销毁
*/
public static void remove() {
threadLocal.remove();
}
}