mooho-base-admin-plus 2.0.24 → 2.0.26
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/mooho-base-admin-plus.min.esm.js +2408 -1000
- package/package/mooho-base-admin-plus.min.js +48 -52
- package/package.json +1 -1
- package/src/index.js +6 -19
- package/src/libs/request/index.js +2 -6
- package/src/libs/util.js +2 -2
- package/src/mixins/page.js +2 -5
- package/src/pages/account/login.vue +2 -1
- package/src/plugins/index.js +2 -2
- package/src/router/dynamic.js +2 -2
- package/src/router/index.js +12 -18
- package/src/store/modules/admin/modules/account.js +10 -4
- package/src/store/modules/admin/modules/db.js +6 -6
- package/src/store/modules/admin/modules/menu.js +4 -4
- package/src/store/modules/admin/modules/page.js +10 -10
- package/test/main.js +2 -5
- package/test/pages/test/logReport.vue +1 -1
- package/test/pages/test/testPage.vue +1 -1
- package/vite.config.js +4 -2
- package/src/api/customTable.js +0 -24
- package/src/api/movePlan.js +0 -29
- package/src/api/roleProperty.js +0 -36
- package/src/libs/util.log.js +0 -88
- package/src/plugins/error/index.js +0 -31
- /package/src/api/{i18nText → i18nText.js} +0 -0
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -33,7 +33,7 @@ import menuHeader from './menu/header';
|
|
|
33
33
|
import i18n from './i18n';
|
|
34
34
|
|
|
35
35
|
// 路由工厂
|
|
36
|
-
import {
|
|
36
|
+
import router, { initRouter } from './router';
|
|
37
37
|
|
|
38
38
|
// 方法
|
|
39
39
|
//import { getHeaderName, getMenuSider, getSiderSubmenu } from './libs/system';
|
|
@@ -165,10 +165,7 @@ Object.keys(files).forEach(key => {
|
|
|
165
165
|
pages[key.replace(/(\.\/pages\/)/g, '')] = files[key].default;
|
|
166
166
|
});
|
|
167
167
|
|
|
168
|
-
|
|
169
|
-
let isFirstRouteChange = true;
|
|
170
|
-
|
|
171
|
-
const created = async app => {
|
|
168
|
+
const created = async (app, pages, routes, layout = basicLayout) => {
|
|
172
169
|
if (window) {
|
|
173
170
|
// 将根实例存全局,可在特殊场景下调用
|
|
174
171
|
window.$app = getCurrentInstance();
|
|
@@ -177,12 +174,10 @@ const created = async app => {
|
|
|
177
174
|
window.$app.$Notice = app.config.globalProperties.$Notice;
|
|
178
175
|
}
|
|
179
176
|
|
|
177
|
+
// 初始化路由
|
|
178
|
+
initRouter(pages, layout, routes);
|
|
180
179
|
// 加载多语言
|
|
181
180
|
store.dispatch('admin/i18n/load', app);
|
|
182
|
-
// 初始化动态路由
|
|
183
|
-
//let dynamicRoutes = await dynamicRouter.init(router, pages, layout);
|
|
184
|
-
// 处理路由 得到每一级的路由设置
|
|
185
|
-
//store.commit('admin/page/init', [...frameInRoutes, ...dynamicRoutes]);
|
|
186
181
|
// 设置顶栏菜单
|
|
187
182
|
store.commit('admin/menu/setHeader', menuHeader);
|
|
188
183
|
// 加载用户登录的数据
|
|
@@ -194,21 +189,12 @@ const created = async app => {
|
|
|
194
189
|
|
|
195
190
|
// 所有页面
|
|
196
191
|
app.config.globalProperties.$pages = pages;
|
|
197
|
-
|
|
198
|
-
// // 加载远程 i18n
|
|
199
|
-
// if (Setting.i18n.remote) loadRemoteLocaleMessages(i18n);
|
|
200
192
|
};
|
|
201
193
|
|
|
202
194
|
const routeChanged = to => {
|
|
203
195
|
// 监听路由 控制侧边栏显示 标记当前顶栏菜单(如需要)
|
|
204
196
|
store.dispatch('admin/menu/setMenuList', to);
|
|
205
197
|
|
|
206
|
-
if (isFirstRouteChange) {
|
|
207
|
-
isFirstRouteChange = false;
|
|
208
|
-
// 每次进入 app 时,获取一次菜单
|
|
209
|
-
//store.dispatch('admin/menu/getMenuList', to);
|
|
210
|
-
}
|
|
211
|
-
|
|
212
198
|
// TODO 权限判断
|
|
213
199
|
//this.appRouteChange(to, from);
|
|
214
200
|
};
|
|
@@ -231,7 +217,8 @@ export {
|
|
|
231
217
|
taskApi,
|
|
232
218
|
applicationApi,
|
|
233
219
|
util,
|
|
234
|
-
|
|
220
|
+
router,
|
|
221
|
+
initRouter,
|
|
235
222
|
created,
|
|
236
223
|
routeChanged
|
|
237
224
|
};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import store from '../../store';
|
|
2
2
|
import axios from 'axios';
|
|
3
3
|
import util from '../util';
|
|
4
|
-
import { getRouter } from '../../router';
|
|
5
4
|
import swal from 'sweetalert2';
|
|
6
5
|
import Setting from '../../setting';
|
|
7
6
|
|
|
@@ -26,7 +25,7 @@ function errorLog(err) {
|
|
|
26
25
|
});
|
|
27
26
|
// 打印到控制台
|
|
28
27
|
if (window.$mode === 'development') {
|
|
29
|
-
util.log.error('>>>>>> Error >>>>>>');
|
|
28
|
+
//util.log.error('>>>>>> Error >>>>>>');
|
|
30
29
|
console.log(err);
|
|
31
30
|
}
|
|
32
31
|
|
|
@@ -153,10 +152,7 @@ service.interceptors.response.use(
|
|
|
153
152
|
store.commit('admin/loader/end');
|
|
154
153
|
|
|
155
154
|
if (error && error.response && error.response.status === 401) {
|
|
156
|
-
|
|
157
|
-
getRouter().push('/login?redirect=' + getRouter().options.history.location);
|
|
158
|
-
}
|
|
159
|
-
|
|
155
|
+
store.dispatch('admin/account/authFailed');
|
|
160
156
|
return;
|
|
161
157
|
}
|
|
162
158
|
|
package/src/libs/util.js
CHANGED
package/src/mixins/page.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import util from '../libs/util';
|
|
2
|
-
import
|
|
2
|
+
import router from '../router';
|
|
3
3
|
import { mapState, mapActions } from 'vuex';
|
|
4
4
|
import dateFormat from 'date-fns/format';
|
|
5
5
|
import Setting from '../setting';
|
|
@@ -72,9 +72,6 @@ export default {
|
|
|
72
72
|
...mapState('admin/user', ['info']),
|
|
73
73
|
...mapState('admin/cache', ['userNames', 'enums', 'dicts', 'caches']),
|
|
74
74
|
...mapState('admin/menu', ['userPermissions']),
|
|
75
|
-
router() {
|
|
76
|
-
return getRouter();
|
|
77
|
-
},
|
|
78
75
|
rootPath() {
|
|
79
76
|
return Setting.rootPath;
|
|
80
77
|
},
|
|
@@ -109,7 +106,7 @@ export default {
|
|
|
109
106
|
} else {
|
|
110
107
|
// 页面权限点
|
|
111
108
|
//console.log('router.currentRoute', router.currentRoute.value.fullPath);
|
|
112
|
-
let url =
|
|
109
|
+
let url = router.currentRoute.value.fullPath.substr(1);
|
|
113
110
|
|
|
114
111
|
if (this.userPermissions[url + '$' + key] == true) {
|
|
115
112
|
return true;
|
|
@@ -26,6 +26,7 @@
|
|
|
26
26
|
<script>
|
|
27
27
|
import { mapActions } from 'vuex';
|
|
28
28
|
import mixinPage from '../../mixins/page';
|
|
29
|
+
import router from '../../router';
|
|
29
30
|
//import permissionApi from '../../api/permission';
|
|
30
31
|
|
|
31
32
|
export default {
|
|
@@ -67,7 +68,7 @@
|
|
|
67
68
|
|
|
68
69
|
// 重定向对象不存在则返回顶层路径
|
|
69
70
|
setTimeout(() => {
|
|
70
|
-
|
|
71
|
+
router.replace(this.$route.query.redirect || '/home');
|
|
71
72
|
});
|
|
72
73
|
}
|
|
73
74
|
},
|
package/src/plugins/index.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* */
|
|
4
4
|
|
|
5
5
|
// 错误捕获
|
|
6
|
-
import pluginError from './error';
|
|
6
|
+
//import pluginError from './error';
|
|
7
7
|
// 日志插件
|
|
8
8
|
//import pluginLog from './log';
|
|
9
9
|
// 鉴权指令
|
|
@@ -14,7 +14,7 @@ import sweetalert2 from './sweetalert2';
|
|
|
14
14
|
export default {
|
|
15
15
|
async install(app) {
|
|
16
16
|
// 插件
|
|
17
|
-
app.use(pluginError);
|
|
17
|
+
//app.use(pluginError);
|
|
18
18
|
//app.use(pluginLog);
|
|
19
19
|
app.use(sweetalert2);
|
|
20
20
|
|
package/src/router/dynamic.js
CHANGED
|
@@ -182,7 +182,7 @@ function PermissionDeep(per, perArry) {
|
|
|
182
182
|
|
|
183
183
|
// 获取多语言名称
|
|
184
184
|
function getNameI18n(item) {
|
|
185
|
-
if (Setting.layout.
|
|
185
|
+
if (Setting.layout.showI18n) {
|
|
186
186
|
let key = 'Permission_' + item.url.split('?')[0];
|
|
187
187
|
let text = window.$app.$t(key);
|
|
188
188
|
if (text == key) {
|
|
@@ -197,7 +197,7 @@ function getNameI18n(item) {
|
|
|
197
197
|
|
|
198
198
|
// 获取多语言描述
|
|
199
199
|
function getDescI18n(item) {
|
|
200
|
-
if (Setting.layout.
|
|
200
|
+
if (Setting.layout.showI18n) {
|
|
201
201
|
let key = 'Permission_' + item.url.split('?')[0] + '_SubName';
|
|
202
202
|
let text = window.$app.$t(key);
|
|
203
203
|
if (text == key) {
|
package/src/router/index.js
CHANGED
|
@@ -5,15 +5,18 @@ import Setting from '../setting';
|
|
|
5
5
|
import store from '../store/index';
|
|
6
6
|
import dynamic from './dynamic';
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
const base = import.meta.env.VITE_APP_BASE_PATH;
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
routes: []
|
|
15
|
-
});
|
|
10
|
+
const router = createRouter({
|
|
11
|
+
history: Setting.routerMode === 'history' ? createWebHistory(base) : Setting.routerMode === 'hash' ? createWebHashHistory(base) : createMemoryHistory(base),
|
|
12
|
+
routes: []
|
|
13
|
+
});
|
|
16
14
|
|
|
15
|
+
// 是否初始化
|
|
16
|
+
let inited = false;
|
|
17
|
+
|
|
18
|
+
// 创建路由
|
|
19
|
+
const initRouter = (pages, layout, routes) => {
|
|
17
20
|
// 添加静态路由
|
|
18
21
|
routes.forEach(route => {
|
|
19
22
|
router.addRoute(route);
|
|
@@ -22,14 +25,10 @@ const create = (base, pages, layout, routes) => {
|
|
|
22
25
|
// 设置资源根目录
|
|
23
26
|
Setting.rootPath = base == '' || base == null ? '/static/' : '/' + base + '/static/';
|
|
24
27
|
|
|
25
|
-
// 是否初始化
|
|
26
|
-
let inited = false;
|
|
27
|
-
|
|
28
28
|
/**
|
|
29
29
|
* 路由拦截
|
|
30
30
|
* 权限验证
|
|
31
31
|
*/
|
|
32
|
-
|
|
33
32
|
router.beforeEach(async (to, from, next) => {
|
|
34
33
|
if (Setting.showProgressBar) {
|
|
35
34
|
ViewUIPlus.LoadingBar.start();
|
|
@@ -85,13 +84,8 @@ const create = (base, pages, layout, routes) => {
|
|
|
85
84
|
// 返回页面顶端
|
|
86
85
|
window.scrollTo(0, 0);
|
|
87
86
|
});
|
|
88
|
-
|
|
89
|
-
return router;
|
|
90
87
|
};
|
|
91
88
|
|
|
92
|
-
|
|
93
|
-
const getRouter = () => {
|
|
94
|
-
return router;
|
|
95
|
-
};
|
|
89
|
+
export { initRouter };
|
|
96
90
|
|
|
97
|
-
export
|
|
91
|
+
export default router;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* 注册、登录、注销
|
|
3
3
|
* */
|
|
4
4
|
import util from '../../../../libs/util';
|
|
5
|
-
import
|
|
5
|
+
import router from '../../../../router';
|
|
6
6
|
import userApi from '../../../../api/user';
|
|
7
7
|
import swal from 'sweetalert2';
|
|
8
8
|
|
|
@@ -46,9 +46,9 @@ export default {
|
|
|
46
46
|
// 清空 vuex 用户信息
|
|
47
47
|
await dispatch('admin/user/set', {}, { root: true });
|
|
48
48
|
// 跳转路由
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
}
|
|
49
|
+
if (router.currentRoute.value.path != '/login') {
|
|
50
|
+
router.push('/login?redirect=' + router.options.history.location);
|
|
51
|
+
}
|
|
52
52
|
}
|
|
53
53
|
|
|
54
54
|
if (confirm) {
|
|
@@ -69,6 +69,12 @@ export default {
|
|
|
69
69
|
logout();
|
|
70
70
|
}
|
|
71
71
|
},
|
|
72
|
+
/**
|
|
73
|
+
* @description 身份认证失败
|
|
74
|
+
* */
|
|
75
|
+
authFailed({ dispatch }) {
|
|
76
|
+
dispatch('logout');
|
|
77
|
+
},
|
|
72
78
|
/**
|
|
73
79
|
* @description 用户登录后从持久化数据加载一系列的设置
|
|
74
80
|
* @param {Object} state vuex state
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* 一般情况下,您无需修改此文件
|
|
4
4
|
* */
|
|
5
5
|
import util from '../../../../libs/util';
|
|
6
|
-
import
|
|
6
|
+
import router from '../../../../router';
|
|
7
7
|
import { cloneDeep } from 'lodash';
|
|
8
8
|
|
|
9
9
|
/**
|
|
@@ -130,7 +130,7 @@ export default {
|
|
|
130
130
|
util.db.get(
|
|
131
131
|
pathInit({
|
|
132
132
|
dbName: 'database',
|
|
133
|
-
path: `$page.${
|
|
133
|
+
path: `$page.${router.app.$route[basis]}`,
|
|
134
134
|
user,
|
|
135
135
|
defaultValue: {}
|
|
136
136
|
})
|
|
@@ -150,7 +150,7 @@ export default {
|
|
|
150
150
|
util.db.get(
|
|
151
151
|
pathInit({
|
|
152
152
|
dbName: 'database',
|
|
153
|
-
path: `$page.${
|
|
153
|
+
path: `$page.${router.app.$route[basis]}`,
|
|
154
154
|
user,
|
|
155
155
|
validator: () => false,
|
|
156
156
|
defaultValue: {}
|
|
@@ -172,7 +172,7 @@ export default {
|
|
|
172
172
|
util.db.get(
|
|
173
173
|
pathInit({
|
|
174
174
|
dbName: 'database',
|
|
175
|
-
path: `$page.${
|
|
175
|
+
path: `$page.${router.app.$route[basis]}.$data`,
|
|
176
176
|
user,
|
|
177
177
|
validator: () => false,
|
|
178
178
|
defaultValue: cloneDeep(instance.$data)
|
|
@@ -196,7 +196,7 @@ export default {
|
|
|
196
196
|
.get(
|
|
197
197
|
pathInit({
|
|
198
198
|
dbName: 'database',
|
|
199
|
-
path: `$page.${
|
|
199
|
+
path: `$page.${router.app.$route[basis]}.$data`,
|
|
200
200
|
user,
|
|
201
201
|
defaultValue: cloneDeep(instance.$data)
|
|
202
202
|
})
|
|
@@ -218,7 +218,7 @@ export default {
|
|
|
218
218
|
util.db.get(
|
|
219
219
|
pathInit({
|
|
220
220
|
dbName: 'database',
|
|
221
|
-
path: `$page.${
|
|
221
|
+
path: `$page.${router.app.$route[basis]}.$data`,
|
|
222
222
|
user,
|
|
223
223
|
validator: () => false,
|
|
224
224
|
defaultValue: {}
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
getNativeMenuHeader,
|
|
15
15
|
getNativePermission
|
|
16
16
|
} from '../../../../libs/system';
|
|
17
|
-
import
|
|
17
|
+
import router from '../../../../router';
|
|
18
18
|
import permissionApi from '../../../../api/permission';
|
|
19
19
|
|
|
20
20
|
// 根据 menu 配置的权限,过滤菜单
|
|
@@ -305,8 +305,8 @@ export default {
|
|
|
305
305
|
.then(res => {
|
|
306
306
|
// 默认包含首页
|
|
307
307
|
res.menus.unshift({
|
|
308
|
-
name: '
|
|
309
|
-
subName: '
|
|
308
|
+
name: window.$app.$t('Permission_home'),
|
|
309
|
+
subName: window.$app.$t('Permission_home_SubName'),
|
|
310
310
|
parentID: null,
|
|
311
311
|
url: 'home',
|
|
312
312
|
templateUrl: '@/home',
|
|
@@ -318,7 +318,7 @@ export default {
|
|
|
318
318
|
//setNativeMenuHeader(res.header);
|
|
319
319
|
setNativeMenuSider(menu);
|
|
320
320
|
if (loadMenu) {
|
|
321
|
-
const to = loadMenu === true ?
|
|
321
|
+
const to = loadMenu === true ? router.currentRoute.value : loadMenu;
|
|
322
322
|
dispatch('setMenuList', to);
|
|
323
323
|
}
|
|
324
324
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* 多标签页
|
|
3
3
|
* */
|
|
4
4
|
import { cloneDeep, get } from 'lodash';
|
|
5
|
-
import
|
|
5
|
+
import router from '../../../../router';
|
|
6
6
|
import Setting from '../../../../setting';
|
|
7
7
|
import menuSider from '../../../../menu/sider';
|
|
8
8
|
import { getAllSiderMenu, includeArray } from '../../../../libs/system';
|
|
@@ -267,7 +267,7 @@ export default {
|
|
|
267
267
|
params,
|
|
268
268
|
query
|
|
269
269
|
};
|
|
270
|
-
|
|
270
|
+
router.push(routerObj, () => {});
|
|
271
271
|
}
|
|
272
272
|
// end
|
|
273
273
|
resolve();
|
|
@@ -291,8 +291,8 @@ export default {
|
|
|
291
291
|
state.opened.splice(1, currentIndex - 1).forEach(({ name }) => commit('keepAliveRemove', name));
|
|
292
292
|
}
|
|
293
293
|
state.current = pageAim;
|
|
294
|
-
if (
|
|
295
|
-
|
|
294
|
+
if (router.currentRoute.value.fullPath !== pageAim) {
|
|
295
|
+
router.push(pageAim);
|
|
296
296
|
}
|
|
297
297
|
// 持久化
|
|
298
298
|
await dispatch('opened2db');
|
|
@@ -317,8 +317,8 @@ export default {
|
|
|
317
317
|
state.opened.splice(currentIndex + 1).forEach(({ name }) => commit('keepAliveRemove', name));
|
|
318
318
|
// 设置当前的页面
|
|
319
319
|
state.current = pageAim;
|
|
320
|
-
if (
|
|
321
|
-
|
|
320
|
+
if (router.currentRoute.value.fullPath !== pageAim) {
|
|
321
|
+
router.push(pageAim);
|
|
322
322
|
}
|
|
323
323
|
// 持久化
|
|
324
324
|
await dispatch('opened2db');
|
|
@@ -348,8 +348,8 @@ export default {
|
|
|
348
348
|
}
|
|
349
349
|
// 设置新的页面
|
|
350
350
|
state.current = pageAim;
|
|
351
|
-
if (
|
|
352
|
-
|
|
351
|
+
if (router.currentRoute.value.fullPath !== pageAim) {
|
|
352
|
+
router.push(pageAim);
|
|
353
353
|
}
|
|
354
354
|
// 持久化
|
|
355
355
|
await dispatch('opened2db');
|
|
@@ -368,8 +368,8 @@ export default {
|
|
|
368
368
|
// 持久化
|
|
369
369
|
await dispatch('opened2db');
|
|
370
370
|
// 关闭所有的标签页后需要判断一次现在是不是在首页
|
|
371
|
-
if (
|
|
372
|
-
|
|
371
|
+
if (router.currentRoute.value.name !== 'index') {
|
|
372
|
+
router.push(
|
|
373
373
|
{
|
|
374
374
|
name: 'index'
|
|
375
375
|
},
|
package/test/main.js
CHANGED
|
@@ -5,7 +5,7 @@ if (!!window.ActiveXObject || 'ActiveXObject' in window) {
|
|
|
5
5
|
import { createApp, h } from 'vue';
|
|
6
6
|
|
|
7
7
|
// 基础框架
|
|
8
|
-
import moohoBaseAdminPlus, { pages, App, store,
|
|
8
|
+
import moohoBaseAdminPlus, { pages, App, store, router, created, routeChanged } from '../src';
|
|
9
9
|
|
|
10
10
|
// 固定路由
|
|
11
11
|
import routes from './router/routes';
|
|
@@ -27,14 +27,11 @@ Object.keys(files).forEach(key => {
|
|
|
27
27
|
pages[key.replace(/(\.\/pages\/)/g, '')] = files[key].default;
|
|
28
28
|
});
|
|
29
29
|
|
|
30
|
-
// 创建路由
|
|
31
|
-
const router = createRouter(import.meta.env.VITE_APP_BASE_PATH, pages, basicLayout, routes);
|
|
32
|
-
|
|
33
30
|
const app = createApp({
|
|
34
31
|
// mixins: [mixinApp],
|
|
35
32
|
render: () => h(App),
|
|
36
33
|
created() {
|
|
37
|
-
created(app);
|
|
34
|
+
created(app, pages, routes);
|
|
38
35
|
},
|
|
39
36
|
watch: {
|
|
40
37
|
// 监听路由 控制侧边栏显示 标记当前顶栏菜单(如需要)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
3
|
<div class="i-layout-page-header">
|
|
4
|
-
<PageHeader title="
|
|
4
|
+
<PageHeader title="ccc" :content="$route.meta.description" hidden-breadcrumb />
|
|
5
5
|
</div>
|
|
6
6
|
<Card :bordered="false" dis-hover class="ivu-mt">
|
|
7
7
|
{{ test }}
|
package/vite.config.js
CHANGED
|
@@ -14,7 +14,8 @@ const build = defineConfig({
|
|
|
14
14
|
},
|
|
15
15
|
resolve: {
|
|
16
16
|
alias: {
|
|
17
|
-
'@': resolve(__dirname, '.', 'src')
|
|
17
|
+
'@': resolve(__dirname, '.', 'src'),
|
|
18
|
+
'vue-i18n': 'vue-i18n/dist/vue-i18n.cjs.js'
|
|
18
19
|
}
|
|
19
20
|
// extensions: ['.js', '.json', '.vue']
|
|
20
21
|
}
|
|
@@ -67,7 +68,8 @@ const lib = defineConfig({
|
|
|
67
68
|
},
|
|
68
69
|
resolve: {
|
|
69
70
|
alias: {
|
|
70
|
-
'@': resolve(__dirname, '.', 'src')
|
|
71
|
+
'@': resolve(__dirname, '.', 'src'),
|
|
72
|
+
'vue-i18n': 'vue-i18n/dist/vue-i18n.cjs.js'
|
|
71
73
|
}
|
|
72
74
|
// extensions: ['.js', '.json', '.vue']
|
|
73
75
|
}
|
package/src/api/customTable.js
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import request from '../libs/request';
|
|
2
|
-
|
|
3
|
-
const res = 'CustomTable';
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
createFormView(id) {
|
|
7
|
-
return request({
|
|
8
|
-
url: `api/${res}/createFormView`,
|
|
9
|
-
method: 'post',
|
|
10
|
-
data: {
|
|
11
|
-
id
|
|
12
|
-
}
|
|
13
|
-
});
|
|
14
|
-
},
|
|
15
|
-
createTableView(id) {
|
|
16
|
-
return request({
|
|
17
|
-
url: `api/${res}/createTableView`,
|
|
18
|
-
method: 'post',
|
|
19
|
-
data: {
|
|
20
|
-
id
|
|
21
|
-
}
|
|
22
|
-
});
|
|
23
|
-
}
|
|
24
|
-
};
|
package/src/api/movePlan.js
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import request from '../libs/request';
|
|
2
|
-
|
|
3
|
-
const res = 'MovePlan';
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
save(data) {
|
|
7
|
-
return request({
|
|
8
|
-
url: `api/${res}/save`,
|
|
9
|
-
method: 'save',
|
|
10
|
-
data
|
|
11
|
-
});
|
|
12
|
-
},
|
|
13
|
-
submit(data) {
|
|
14
|
-
return request({
|
|
15
|
-
url: `api/${res}/submit`,
|
|
16
|
-
method: 'post',
|
|
17
|
-
data
|
|
18
|
-
});
|
|
19
|
-
},
|
|
20
|
-
cancel(id) {
|
|
21
|
-
return request({
|
|
22
|
-
url: `api/${res}/cancel`,
|
|
23
|
-
method: 'post',
|
|
24
|
-
data: {
|
|
25
|
-
id
|
|
26
|
-
}
|
|
27
|
-
});
|
|
28
|
-
}
|
|
29
|
-
};
|
package/src/api/roleProperty.js
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import request from '../libs/request';
|
|
2
|
-
|
|
3
|
-
const res = 'RoleProperty';
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
add(data) {
|
|
7
|
-
return request({
|
|
8
|
-
url: `api/${res}/add`,
|
|
9
|
-
method: 'post',
|
|
10
|
-
data
|
|
11
|
-
});
|
|
12
|
-
},
|
|
13
|
-
update(data) {
|
|
14
|
-
return request({
|
|
15
|
-
url: `api/${res}/update`,
|
|
16
|
-
method: 'put',
|
|
17
|
-
data
|
|
18
|
-
});
|
|
19
|
-
},
|
|
20
|
-
remove(id) {
|
|
21
|
-
return request({
|
|
22
|
-
url: `api/${res}/remove`,
|
|
23
|
-
method: 'delete',
|
|
24
|
-
params: {
|
|
25
|
-
id
|
|
26
|
-
}
|
|
27
|
-
});
|
|
28
|
-
},
|
|
29
|
-
query(data) {
|
|
30
|
-
return request({
|
|
31
|
-
url: `api/${res}/query`,
|
|
32
|
-
method: 'post',
|
|
33
|
-
data
|
|
34
|
-
});
|
|
35
|
-
}
|
|
36
|
-
};
|