chenyc
2022-09-23 3ce633c51d54fa3a89c473d8f501a9d4970cf0cf
up12
4个文件已修改
20 ■■■■■ 已修改文件
src/router/index.ts 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/axios.ts 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/home/index.vue 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/myMine/index.vue 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/router/index.ts
@@ -4,9 +4,9 @@
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')}
]
@@ -17,6 +17,9 @@
router.beforeEach((to, from, next) => {
    cancelRequest()
    if (to.meta.title){
        document.title = to.meta.title
    }
    next()
})
src/utils/axios.ts
@@ -108,4 +108,3 @@
    ajaxPatch
}
// export default instance
src/views/home/index.vue
@@ -115,9 +115,9 @@
                </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>
src/views/myMine/index.vue
@@ -97,8 +97,8 @@
            </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>