Compare commits

...

2 Commits

Author SHA1 Message Date
odjbin d90e69902c Merge pull request '邓洁 : footer跳转' (#19) from dj into master
Reviewed-on: #19
2023-05-22 13:15:29 +00:00
邓洁 a2ff2c74e7 邓洁 : footer跳转 2023-05-22 21:14:50 +08:00
1 changed files with 18 additions and 7 deletions

View File

@ -12,7 +12,7 @@
<li v-for="(footerItem,footerIndex) in footerList" :key="footerIndex">
<a :href="footerItem.href">{{ footerItem.title }}</a>
<div class="item" v-for="(footerItems,footerItemsIndex) in footerItem.items" :key="footerItemsIndex">
<a :href="footerItems.href">{{ footerItems.title }}</a>
<a @click.stop="changeMenu(footerItems,footerItem)" >{{ footerItems.title }}</a>
</div>
</li>
</ul>
@ -57,13 +57,13 @@ export default {
title: "新闻资讯",
items: [
{
href:'/news',
id: 5,
title: "公司新闻"
},
{
}, {
id: 6,
title: "行业动态"
},
{
}, {
id: 7,
title: "瓷砖百科"
}
]
@ -73,10 +73,11 @@ export default {
title: "形象展示",
items: [
{
href:'/image_display',
id: 2,
title: "资质荣誉"
},
{
id: 8,
title: "工程案例"
}
]
@ -103,6 +104,16 @@ export default {
this.footerList[3].items=res.data.join
this.footerList[4].items=res.data.contact_us
});
},
methods:{
changeMenu(footerItems,footerItem){
this.$router.push({
path: footerItem.href, //
query: { //
menu: footerItems.id //type
}
});
}
}
};
</script>