$router

1  params 传参

注意⚠️:patams传参 ,路径不能使用path 只能使用name,不然获取不到传的数据

this.$router.push({name: 'dispatch', params: {paicheNo: obj.paicheNo}})

取数据:this.$route.params.paicheNo

this.$route.params.paicheNo


2 query传参

this.$router.push({path: '/transport/dispatch', query: {paicheNo: obj.paicheNo}})

取数据:this.$route.query.paicheNo

this.$route.query.paicheNo

发布了124 篇原创文章 · 获赞 10 · 访问量 4万+

猜你喜欢

转载自blog.csdn.net/qq_40774743/article/details/86686832