DESKTOP-CVS3R96\我恁爹
2022-11-15 c523ce0e8f371ed6c5a503eaa0a938b202daf8c2
src/axios/index.js
@@ -21,6 +21,7 @@
// 在ajax发送之前拦截 比如对所有请求统一添加header token
axios.interceptors.request.use(
  config => {
    config.headers["lang"] = localStorage.getItem("language") ? localStorage.getItem("language") : "zh-CN";
    if (window.localStorage.getItem("USERTOKEN")) {
        // config.headers.Authorization = `USER_TOKEN = ${store.state.token}`;
        config.headers["USERTOKEN"] = window.localStorage.getItem("USERTOKEN");