2.第二种
/*获取企业Vo信息*/
export function getInfoById(id) {
return request({
url: `/unit/company/getInfo/${id}`,
method: 'get',
})
}
image.png
getCompanyInfo(this.$route.query.companyId).then((res) => {
// 分页总数
// this.total = res.data.total;
}
image.png
- 第一种
export function getPersonInfoVo(params) {
return request({
url: '/person/queryPersonInfoVo',
method: 'get',
params
})
}
image.png
- {personId: this.$route.query.personId}
key:value
methods: {
// unitID 路由过来
getInfo() {
this.loading = true;
// 参数:this.$route.query.unitID
getPersonInfoVo({personId: this.$route.query.personId}).then((res)=>{
console.log(res.data, "ceshi ");
});
},
}
image.png
网友评论