提交 64aae8ff 编写于 作者: llz's avatar llz

main.ts从window中引入Avue,并将axios放入window对象中。

上级 d599d452
...@@ -5,6 +5,7 @@ import App from '@/App.vue'; ...@@ -5,6 +5,7 @@ import App from '@/App.vue';
import ElementUi from 'element-ui'; import ElementUi from 'element-ui';
import ViewUI from 'view-design'; import ViewUI from 'view-design';
import ibizLab from 'ibiz-vue-lib'; import ibizLab from 'ibiz-vue-lib';
import axios from "axios";
import { Interceptors } from '@/utils'; import { Interceptors } from '@/utils';
import {Print} from '@/utils/print'; import {Print} from '@/utils/print';
import i18n from '@/locale' import i18n from '@/locale'
...@@ -27,13 +28,18 @@ import { PortletComponent } from '@/portlet-register'; ...@@ -27,13 +28,18 @@ import { PortletComponent } from '@/portlet-register';
import store from '@/store'; import store from '@/store';
import router from './router'; import router from './router';
const win: any = window;
win.axios = axios;
Vue.config.errorHandler = function (err: any, vm: any, info: any) { Vue.config.errorHandler = function (err: any, vm: any, info: any) {
console.log(err); console.log(err);
} }
Vue.config.productionTip = false; Vue.config.productionTip = false;
Vue.use(Print); Vue.use(Print);
Vue.use(ibizLab); Vue.use(ibizLab);
Vue.use(Vuex); Vue.use(Vuex);
Vue.use(win.AVUE);
Vue.use(VueRouter);; Vue.use(VueRouter);;
Vue.use(ElementUi, { Vue.use(ElementUi, {
i18n: (key: any, value: any) => i18n.t(key, value) i18n: (key: any, value: any) => i18n.t(key, value)
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册