diff --git a/ruoyi-ui/src/router/index.js b/ruoyi-ui/src/router/index.js index 0364eac..397b8a5 100644 --- a/ruoyi-ui/src/router/index.js +++ b/ruoyi-ui/src/router/index.js @@ -43,71 +43,85 @@ export const constantRoutes = [ }, { path: '/gw', + name:'gw', component: () => import('@/views/home'), hidden: true }, { path: '/sb',//测试 + name:'sb', component: () => import('@/views/sb'), hidden: true }, { path: '/about',// 中心概括 + name:'about', component: () => import('@/views/officialWebsite/about'), hidden: true }, { path: '/platform', // 教学平台 + name:'platform', component: () => import('@/views/officialWebsite/platform'), hidden: true }, { path: '/teaching', // 教学资源 + name:'teaching', component: () => import('@/views/officialWebsite/teaching'), hidden: true }, { path: '/team', // 教学团队 + name:'team', component: () => import('@/views/officialWebsite/team'), hidden: true }, { path: '/committee', // 专业委员会 + name:'committee', component: () => import('@/views/officialWebsite/committee'), hidden: true }, { path: '/news', // 教学研讨活动 + name:'news', component: () => import('@/views/officialWebsite/news'), hidden: true }, { path: '/xufang', // 虚仿专业频道 + name:'xufang', component: () => import('@/views/officialWebsite/xufang'), hidden: true }, { path: '/competition', // 大赛风采 + name:'competition', component: () => import('@/views/officialWebsite/competition'), hidden: true }, { path: '/cases', // 合作企业 + name:'cases', component: () => import('@/views/officialWebsite/cases'), hidden: true }, { path: '/contact', // 联系我们 + name:'contact', component: () => import('@/views/officialWebsite/contact'), hidden: true }, { path: '/practice', // 实践平台 + name:'practice', component: () => import('@/views/officialWebsite/practice'), hidden: true }, { path: '/login', + component: () => import('@/views/login'), hidden: true }, diff --git a/ruoyi-ui/src/views/home.vue b/ruoyi-ui/src/views/home.vue index 4b35df2..b4b06f1 100644 --- a/ruoyi-ui/src/views/home.vue +++ b/ruoyi-ui/src/views/home.vue @@ -339,6 +339,7 @@ export default { } }, mounted() { + console.log(this.$route.params.id) // 页面加载完毕调用 this.tabLsit(); this.getWebBaseInfo() diff --git a/ruoyi-ui/src/views/officialWebsite/Components/header.vue b/ruoyi-ui/src/views/officialWebsite/Components/header.vue index 6f4a69a..637ec75 100644 --- a/ruoyi-ui/src/views/officialWebsite/Components/header.vue +++ b/ruoyi-ui/src/views/officialWebsite/Components/header.vue @@ -11,7 +11,7 @@
-
+
{{ item.label }}
@@ -59,10 +59,14 @@ export default { this.getWebBaseInfo() }, methods:{ - tabClick(item){ - if(item){ - this.$router.push(item.jumpUrl); - } + tabClick(url,id){ + console.log(url,id) + + this.$router.push({ + name: url, + params:{ id: id } + }); + }, tabLsit() { getTab().then(response => { diff --git a/ruoyi-ui/src/views/officialWebsite/about.vue b/ruoyi-ui/src/views/officialWebsite/about.vue index 4d86731..b62d1c7 100644 --- a/ruoyi-ui/src/views/officialWebsite/about.vue +++ b/ruoyi-ui/src/views/officialWebsite/about.vue @@ -1,26 +1,7 @@ @@ -213,10 +87,14 @@ import { Swiper, SwiperSlide } from "vue-awesome-swiper"; import "swiper/css/swiper.min.css"; import { getPageData } from "@/api/officialWebsite/getPageData"; +import headers from '@/views/officialWebsite/Components/header.vue' +import footers from '@/views/officialWebsite/Components/footer.vue' export default { components: { Swiper, SwiperSlide, + headers, + footers }, name: 'HelloWorld', props: { @@ -305,7 +183,7 @@ export default { }); }); - + let current_leader_param = { "categoryId": "1813827861774209024", "pageNum": 1, diff --git a/ruoyi-ui/src/views/officialWebsite/cases.vue b/ruoyi-ui/src/views/officialWebsite/cases.vue index 7d2e6dc..2e9fe72 100644 --- a/ruoyi-ui/src/views/officialWebsite/cases.vue +++ b/ruoyi-ui/src/views/officialWebsite/cases.vue @@ -1,26 +1,7 @@