<template>
	<view class="">
		<Home v-if="index ===0"></Home>
		<myCase v-else-if="index === 1"></myCase>
		<navigationDynamic v-else-if="index === 2"></navigationDynamic>
		<personCenter v-else></personCenter>
		<Tab @toIndex="toIndex" :index="index"></Tab>
	</view>
</template>
<script>
	import Home from "../home/home.vue"
	import myCase from "../my-case/my-case.vue"
	import navigationDynamic from "../navigation-dynamic/navigation-dynamic.vue"
	import personCenter from "../person-center/person-center.vue"
	import Tab from "../../components/Tab/Tab.vue"
	import {
		newsBanner
	} from "../../api/news";
	export default {
		components: {
			Home,
			myCase,
			navigationDynamic,
			personCenter,
		},
		data() {
			return {
				index: 0,

			}
		},
		mounted() {

		},
		methods: {
			toIndex(index) {
				this.index = index
				// console.log("AAAAAAA", this.index)
			},

		},
	}
</script>
<style lang="scss" scoped></style>
