用计算属性 computed 给个三元
比如
computed:{
carNo () { return (this.list.length? this.list.carNo : ‘_’)}
}
页面初始化的时候值为空位undefind 比如carNO
最新推荐文章于 2022-08-15 11:18:55 发布
用计算属性 computed 给个三元
比如
computed:{
carNo () { return (this.list.length? this.list.carNo : ‘_’)}
}