wangzhihui 4 лет назад
Родитель
Сommit
31e30e1b65
1 измененных файлов с 7 добавлено и 1 удалено
  1. 7 1
      src/apis/config.js

+ 7 - 1
src/apis/config.js

@@ -1,4 +1,10 @@
-const baseurl = "https://interface.huihenduo.com.cn/hhd-pat/";
+const baseurl = `${
+  window.location.href.indexOf("localhost") == -1
+    ? "https://interface.huihenduo.com.cn/hhd-pat/"
+    : "https://interface.huihenduo.com.cn/hhd-pat-dev/"
+}`;
+// const baseurl = "https://interface.huihenduo.com.cn/hhd-pat/";
+
 const uploadUrl = `${baseurl}cos/upload`;
 import axios from "axios";