1 handleChange(val) { 2 let obj = {} 3 // 遍历数组 4 obj = this.options.find(item => { 5 // 筛选出匹配的数据 6 return item.id === val 7 }) 8 this.hzid = obj.hzid 9 this.projectId = obj.id 10 console.log(obj, this.projectId, this.hzid) 11 },