Explorar o código

http 地址 根据localhost获取

zhangsijie %!s(int64=2) %!d(string=hai) anos
pai
achega
d875d08dfb
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      pingpu_vue/src/main.js

+ 2 - 1
pingpu_vue/src/main.js

@@ -24,7 +24,8 @@ const Qs = require("qs");
 Vue.prototype.$axios = axios;
 // import qs from 'qs'
 Vue.prototype.qs = Qs; // 全局注册,使用方法为:this.qs
-Vue.prototype.$http = "http://106.119.196.18:10004";
+// Vue.prototype.$http = "http://106.119.196.18:10004";
+Vue.prototype.$http = window.location.host;
 /* eslint-disable no-new */
 const ElementUI = require("element-ui");
 Vue.use(ElementUI);