2021-12-14 18:36:19 +08:00
|
|
|
import Vue from 'vue';
|
|
|
|
|
import App from './App.vue';
|
|
|
|
|
import ui from 'element-ui';
|
2024-10-10 16:04:11 +08:00
|
|
|
import router from './router';
|
2021-12-14 18:36:19 +08:00
|
|
|
import axios from './router/axios';
|
|
|
|
|
import utils from './utils';
|
2024-10-10 17:35:04 +08:00
|
|
|
import dui from 'dui/packages';
|
2021-12-14 18:36:19 +08:00
|
|
|
import store from './store';
|
|
|
|
|
import dataV from '@jiaminghi/data-view';
|
2024-10-10 17:35:04 +08:00
|
|
|
import dvui from 'dui/dv'
|
2021-12-14 18:36:19 +08:00
|
|
|
|
2023-10-09 16:46:02 +08:00
|
|
|
Vue.use(dataV)
|
2021-12-14 18:36:19 +08:00
|
|
|
Vue.use(ui);
|
2022-12-01 09:35:20 +08:00
|
|
|
Vue.use(dui);
|
2024-04-12 10:22:47 +08:00
|
|
|
Vue.use(dvui);
|
2021-12-14 18:36:19 +08:00
|
|
|
//富文本编辑器配置
|
|
|
|
|
Vue.config.productionTip = false;
|
|
|
|
|
Object.keys(utils).map((e) => (Vue.prototype[e] = utils[e]));
|
2022-07-27 10:31:56 +08:00
|
|
|
Vue.prototype.$request = axios
|
2022-08-19 11:03:44 +08:00
|
|
|
const app = new Vue({
|
2022-03-09 11:58:28 +08:00
|
|
|
router,
|
|
|
|
|
store,
|
2022-08-19 11:03:44 +08:00
|
|
|
render: h => h(App)
|
|
|
|
|
});
|
2024-10-10 16:04:11 +08:00
|
|
|
|
2022-08-19 11:03:44 +08:00
|
|
|
let theme = null
|
2023-01-19 10:47:51 +08:00
|
|
|
store.dispatch('getSystem').then(res => {
|
|
|
|
|
theme = JSON.parse(res?.colorScheme || null)
|
2022-08-19 11:03:44 +08:00
|
|
|
Vue.prototype.$theme = theme?.web || "blue"
|
2022-11-29 18:27:14 +08:00
|
|
|
return import(`dui/lib/styles/theme.${theme?.web}.scss`).catch(() => 0)
|
2022-08-19 11:03:44 +08:00
|
|
|
}).finally(() => {
|
2022-11-07 16:03:02 +08:00
|
|
|
Vue.prototype.$vm = app
|
2022-12-05 10:57:02 +08:00
|
|
|
import(`dui/lib/styles/common.scss`).finally(() => app.$mount('#app'))
|
2022-08-19 11:03:44 +08:00
|
|
|
})
|
|
|
|
|
|