From 0c791a1efc539d06742ae14375d4d5ddfd1339f5 Mon Sep 17 00:00:00 2001
From: 疯狂的狮子Li <15040126243@163.com>
Date: 星期二, 25 七月 2023 15:59:35 +0800
Subject: [PATCH] update 优化 封装全局统一请求头

---
 src/views/system/user/index.vue |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/src/views/system/user/index.vue b/src/views/system/user/index.vue
index f8aa2e8..3da644d 100644
--- a/src/views/system/user/index.vue
+++ b/src/views/system/user/index.vue
@@ -305,6 +305,7 @@
 import { RoleVO } from "@/api/system/role/types";
 import { PostVO } from "@/api/system/post/types";
 import { to } from "await-to-js";
+import { globalHeaders } from "@/utils/request";
 
 const router = useRouter();
 const { proxy } = getCurrentInstance() as ComponentInternalInstance
@@ -334,7 +335,7 @@
   // 鏄惁鏇存柊宸茬粡瀛樺湪鐨勭敤鎴锋暟鎹�
   updateSupport: 0,
   // 璁剧疆涓婁紶鐨勮姹傚ご閮�
-  headers: { Authorization: "Bearer " + getToken() },
+  headers: globalHeaders,
   // 涓婁紶鐨勫湴鍧�
   url: import.meta.env.VITE_APP_BASE_API + "/system/user/importData"
 })

--
Gitblit v1.9.3