mooho-base-admin-plus 0.1.40 → 0.1.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -25,7 +25,7 @@ function errorLog(err) {
|
|
|
25
25
|
}
|
|
26
26
|
});
|
|
27
27
|
// 打印到控制台
|
|
28
|
-
if (window.$
|
|
28
|
+
if (window.$mode === 'development') {
|
|
29
29
|
util.log.error('>>>>>> Error >>>>>>');
|
|
30
30
|
console.log(err);
|
|
31
31
|
}
|
|
@@ -50,7 +50,7 @@ service.interceptors.request.use(
|
|
|
50
50
|
config => {
|
|
51
51
|
store.commit('admin/loader/start');
|
|
52
52
|
|
|
53
|
-
let baseURL = window.$
|
|
53
|
+
let baseURL = window.$mode === 'development' ? Setting.apiBaseURL.dev : Setting.apiBaseURL.prd;
|
|
54
54
|
config.url = baseURL + config.url;
|
|
55
55
|
|
|
56
56
|
// 在请求发送之前做一些处理
|
package/test/main.js
CHANGED
|
@@ -12,8 +12,8 @@ import routes from './router/routes';
|
|
|
12
12
|
// 自定义css
|
|
13
13
|
import './styles/css/custom.css';
|
|
14
14
|
|
|
15
|
-
//
|
|
16
|
-
window.$
|
|
15
|
+
// 环境模式
|
|
16
|
+
window.$mode = import.meta.env.MODE;
|
|
17
17
|
|
|
18
18
|
// 页面
|
|
19
19
|
const files = import.meta.globEager('./pages/**/*.vue');
|