Commit ad2fe0f7 by 无尘

fix: 修改Vue加载

parent 2ecd589b
......@@ -4,7 +4,7 @@
* @Author: 无尘
* @Date: 2020-07-16 16:37:05
* @LastEditors: 无尘
* @LastEditTime: 2020-09-21 15:12:19
* @LastEditTime: 2020-09-21 15:37:51
*/
import 'babel-polyfill';
import promise from 'es6-promise';
......
......@@ -4,7 +4,7 @@
* @Author: 无尘
* @Date: 2020-07-31 11:41:34
* @LastEditors: 无尘
* @LastEditTime: 2020-09-21 11:45:37
* @LastEditTime: 2020-09-21 15:42:03
*/
import { request } from './request.js';
import axios from 'axios';
......@@ -93,7 +93,7 @@ function itemPerm(itemPermCode) {
let permission = function(config) {
const { projectPath, whiteRoute, router, routes, createApp } = config;
window.onload = async function() {
window.addEventListener('load', async function() {
// 获取菜单数据
// 获取权限数据
const path = window.location.href;
......@@ -115,7 +115,7 @@ let permission = function(config) {
router.beforeEach(intercept);
// 创建vue实例,渲染页面
if (typeof createApp == 'function') createApp();
};
});
};
export { permission, itemPerm };
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment