123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
- return new (P || (P = Promise))(function (resolve, reject) {
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
- step((generator = generator.apply(thisArg, _arguments || [])).next());
- });
- };
- import Vue from 'vue';
- import App from './App.vue';
- import router from './router';
- import store from './store';
- Vue.config.productionTip = false;
- import design from 'ant-design-vue';
- import 'ant-design-vue/dist/antd.css';
- Vue.use(design);
- import ElementUI from 'element-ui';
- import 'element-ui/lib/theme-chalk/index.css';
- Vue.use(ElementUI);
- import VueQuillEditor from 'vue-quill-editor';
- import 'quill/dist/quill.core.css';
- import 'quill/dist/quill.snow.css';
- import 'quill/dist/quill.bubble.css';
- Vue.use(VueQuillEditor);
- import WdEditor from '@/components/Editor';
- Vue.use(WdEditor);
- import Rotation from '@/components/Rotation';
- Vue.use(Rotation);
- import PicLarge from '@/components/PicLarge';
- Vue.use(PicLarge);
- import Legend from '@/components/Legend';
- Vue.use(Legend);
- import cookies from 'vue-cookie';
- Vue.use(cookies);
- import Pui from 'meri-design';
- import 'meri-design/dist/index.css';
- Vue.use(Pui);
- //////////模拟传入参数
- const username = 'lengqiang';
- /////////////////
- // 在跳入路由之前要请求获取权限信息
- router.beforeEach((to, from, next) => __awaiter(void 0, void 0, void 0, function* () {
- if (!store.state.isrequestAuth) {
- yield store.dispatch('getUserInfo', username);
- yield store.dispatch('getFloors');
- }
- next();
- }));
- new Vue({
- router,
- store,
- render: (h) => h(App),
- }).$mount('#app');
|