Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] dateSelector 模式第一次加载出错 #34

Closed
zhuzhengjing opened this issue Jun 10, 2019 · 5 comments
Closed

[BUG] dateSelector 模式第一次加载出错 #34

zhuzhengjing opened this issue Jun 10, 2019 · 5 comments
Labels
bug Something isn't working

Comments

@zhuzhengjing
Copy link

this.currentColumnTitle = '生日'
this.pickerValueDefault = new Date('2000-01-01')
this.pickerValueArray = []
this.pickerMode = 'dateSelector'
this.$refs.mpvuePicker.show()

第一次加载提示:

Cannot read property 'label' of undefined; [Component] Event Handler Error @ node-modules/mpvue-picker/src/mpvue-picker/mpvuePicker#handleEvent

image

出错详情

image

@KuangPF
Copy link
Member

KuangPF commented Jun 10, 2019

mpvue-picker 版本号是多少,dateSelector 模式是在 2.1.0 以后支持的。

@zhuzhengjing
Copy link
Author

使用的最新的2.1.1版本

使用提供的demo测试,在iPhone 7可以测试出来
image

@zhuzhengjing
Copy link
Author

补充错误截图

image

@KuangPF KuangPF added the bug Something isn't working label Jun 10, 2019
KuangPF added a commit that referenced this issue Jun 10, 2019
@KuangPF
Copy link
Member

KuangPF commented Jun 10, 2019

2.1.2 版本修复了,是 new Date 的一个 bug,如果设置的默认值为日期类型应该不会有问题吧。

@zhuzhengjing
Copy link
Author

可以了,谢谢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants