Skip to content

多个select component时提示Cannot read property 'childNodes' of undefined #1120

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

Closed
dalphyx opened this issue Aug 5, 2015 · 1 comment
Labels

Comments

@dalphyx
Copy link

dalphyx commented Aug 5, 2015

在写一个简单的省级级联component时发现,提供个demo:http://jsfiddle.net/4oa8anz4/

demo提供的是市在省之前时的正确表现,但只要把level2的市级元素移到level1的省级元素之后,就会报Cannot read property 'childNodes' of undefined

@yolio2003
Copy link

看到根本没有 level = 1 的属性配置,是不是这里的问题呢。

if (this.level !== '2') { 

改成

if (this.level === 1) { 

咋样 ?而且没报错了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants