12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879 |
- import Vue from 'vue'
- import 'animate.css'
- import {
- Cell,
- CellGroup,
- Icon,
- Notify,
- Form,
- Tabbar,
- TabbarItem,
- Button,
- Field,
- Toast,
- Card,
- NavBar,
- Image, SwipeItem, Tag, Swipe, Divider, Picker, Popup, Dialog, List, ImagePreview
- } from 'vant';
- import App from './App.vue'
- import { Login, redirect, getQueryPath } from './util/initial'
-
- // import Questionnaire from './views/components/Questionnaire'
- // import Loading from './views/components/Questionnaire/Loading.vue';
- import router from './router/index'//路由
- import store from './store';//状态管理
-
- import './global_style.less'
-
- // 如果有 query 分享路径
- const queryPath = getQueryPath()
- if (queryPath) {
- window.location.href = queryPath
- }
-
-
- Vue.config.productionTip = false
-
- Vue.use(Popup);
- // Vue.use(parseTime);
- Vue.use(Picker);
- Vue.use(List);
- Vue.use(Dialog);
- Vue.use(Divider);
- Vue.use(Swipe);
- Vue.use(Tag);
- Vue.use(ImagePreview);
- Vue.use(NavBar);
- Vue.use(SwipeItem);
- Vue.use(Image);
- Vue.use(Toast);
- Vue.use(Card);
- Vue.use(Form);
- Vue.use(Field);
- Vue.use(Cell);
- Vue.use(CellGroup);
- Vue.use(Notify);
- Vue.use(Tabbar).use(TabbarItem);
- Vue.use(Button);
- Vue.use(Icon);
- // Vue.component('v-loading', Loading);
- // Vue.use(Questionnaire)
- // Vue.use(animated)
-
- // Vue.use(Tabbar);
- // Vue.use(TabbarItem);
- redirect()
-
- Login().then(e => {
- new Vue({
- router,
- store,
- render: h => h(App),
- }).$mount('#app')
- }).catch(e => {
- console.error(e)
- // alert('系统错误, 请刷新重试')
-
- // 重试一次
- redirect(true)
- })
|