lihao преди 4 години
родител
ревизия
a0a062b7ec
променени са 1 файла, в които са добавени 4 реда и са изтрити 2 реда
  1. 4 2
      src/main.js

+ 4 - 2
src/main.js

@@ -25,10 +25,12 @@ Vue.use(Element, {
 Vue.prototype.$api = process.env.NODE_ENV == 'development' ? "/api" : "http://localhost:9000";
 Vue.http.options.emulateJSON = true;
 Vue.prototype.$md5 = md5;
-Vue.http.options.xhr = { withCredentials: true,}
+Vue.http.options.xhr = { 
+  // withCredentials: true,
+}
 Vue.http.interceptors.push(function (request, next) {//拦截器
   // 跨域携带cookie
-  request.credentials = true;
+  //request.credentials = true;
   next()
 })
 new Vue({