cube-ui icon indicating copy to clipboard operation
cube-ui copied to clipboard

picker组件在data数组为[[]]时点击确定无法关闭弹窗

Open steavengong opened this issue 5 years ago • 2 comments

Version

1.12.24

Reproduction link

https://rusrn.codesandbox.io/

Steps to reproduce

picker组件在data数组为[[]]时点击确定无法关闭弹窗 初始化后第一次可以正常关闭 之后就无法通过确定关闭

What is expected?

当picker组件在data数组为[[]]时点击确定也能正常关闭

What is actually happening?

picker组件在data数组为[[]]时点击确定无法关闭picker

Dependencies Version

vue: 2.6.9 better-scroll: 1.15.0

steavengong avatar Jun 28 '19 01:06 steavengong

data没有的时候是不是不应该弹出?

dolymood avatar Jun 28 '19 02:06 dolymood

我刚才想到一个方案

this.picker = this.$createPicker({ data:this.column1.length?[this.column1]:[], selectedIndex:this.selelctedIndex, onSelect:(val,index,text)=>{ console.log(val) console.log(index) console.log(text) } })

steavengong avatar Jun 28 '19 02:06 steavengong