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
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mooho-base-admin-plus",
3
3
  "description": "MOOHO basic framework for admin by Vue3",
4
- "version": "0.1.40",
4
+ "version": "0.1.41",
5
5
  "author": "jinyifan <jinyifan@mooho.com.cn>",
6
6
  "dotnetVersion": "1.3.97",
7
7
  "license": "MIT",
@@ -25,7 +25,7 @@ function errorLog(err) {
25
25
  }
26
26
  });
27
27
  // 打印到控制台
28
- if (window.$env.MODE === 'development') {
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.$env.MODE === 'development' ? Setting.apiBaseURL.dev : Setting.apiBaseURL.prd;
53
+ let baseURL = window.$mode === 'development' ? Setting.apiBaseURL.dev : Setting.apiBaseURL.prd;
54
54
  config.url = baseURL + config.url;
55
55
 
56
56
  // 在请求发送之前做一些处理
@@ -16,7 +16,7 @@ export default {
16
16
  }
17
17
  });
18
18
  // 只在开发模式下打印 log
19
- if (window.$env.MODE === 'development') {
19
+ if (window.$mode === 'development') {
20
20
  util.log.capsule('Admin Plus', 'ErrorHandler', 'error');
21
21
  util.log.error('>>>>>> 错误信息 >>>>>>');
22
22
  console.log(info);
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.$env = import.meta.env;
15
+ // 环境模式
16
+ window.$mode = import.meta.env.MODE;
17
17
 
18
18
  // 页面
19
19
  const files = import.meta.globEager('./pages/**/*.vue');