| | |
| | | import { cancelRequest } from '@/utils/axios' |
| | | |
| | | const routes: Array<RouteRecordRaw> = [ |
| | | { path: '/', name: 'Home', component: () => import('views/home/index.vue')}, |
| | | { path: '/my', name: 'myMine', component: () => import('views/myMine/index.vue')}, |
| | | { path: '/paiban', name: 'paiban', component: () => import('views/paiban/index.vue')}, |
| | | { path: '/', name: 'Home', component: () => import('views/home/index.vue'),meta:{title:'首页'}}, |
| | | { path: '/my', name: 'myMine', component: () => import('views/myMine/index.vue'),meta:{title:'我的'}}, |
| | | { path: '/paiban', name: 'paiban', component: () => import('views/paiban/index.vue'),meta:{title:'透析排班'}}, |
| | | { path: '/test', name: 'Test', component: () => import('views/test.vue')} |
| | | ] |
| | | |
| | |
| | | |
| | | router.beforeEach((to, from, next) => { |
| | | cancelRequest() |
| | | if (to.meta.title){ |
| | | document.title = to.meta.title |
| | | } |
| | | next() |
| | | }) |
| | | |
| | |
| | | ajaxPatch |
| | | } |
| | | |
| | | // export default instance |
| | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <van-tabbar v-model="active" route @change="tabChang"> |
| | | <van-tabbar-item name="home" @click="active = 'home'" icon="home-o">首页</van-tabbar-item> |
| | | <van-tabbar-item name="mydo" @click="active = 'mydo'" icon="manager">我的</van-tabbar-item> |
| | | <van-tabbar v-model="active" @change="tabChang"> |
| | | <van-tabbar-item name="home" icon="like">首页</van-tabbar-item> |
| | | <van-tabbar-item name="my" icon="manager">我的</van-tabbar-item> |
| | | </van-tabbar> |
| | | </div> |
| | | </template> |
| | |
| | | </div> |
| | | </div> |
| | | <van-tabbar v-model="active" @change="tabChang"> |
| | | <van-tabbar-item name="home" @click="active = 'home'" icon="home-o">首页</van-tabbar-item> |
| | | <van-tabbar-item name="my" @click="active = 'my'" icon="manager">我的</van-tabbar-item> |
| | | <van-tabbar-item name="home" icon="like">首页</van-tabbar-item> |
| | | <van-tabbar-item name="my" icon="manager">我的</van-tabbar-item> |
| | | </van-tabbar> |
| | | </div> |
| | | </template> |