feat(ckbox): 重构联系人列表获取逻辑并优化登录流程
- 将联系人列表从模拟数据改为从API获取 - 优化登录处理流程,分离存客宝和触客宝的token获取 - 添加messageApi统一处理消息提示 - 修复路径引用问题并移除未使用的导入
This commit is contained in:
@@ -28,7 +28,6 @@ const instance: AxiosInstance = axios.create({
|
||||
instance.interceptors.request.use((config: any) => {
|
||||
// 在每次请求时动态获取最新的 token2
|
||||
const { token2 } = useUserStore.getState();
|
||||
|
||||
if (token2) {
|
||||
config.headers = config.headers || {};
|
||||
config.headers["Authorization"] = `bearer ${token2}`;
|
||||
|
||||
Reference in New Issue
Block a user