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

navmenu 控件默认全部展开后,无法单击收回 #2279

Closed
kvsl9 opened this issue Jan 7, 2017 · 4 comments
Closed

navmenu 控件默认全部展开后,无法单击收回 #2279

kvsl9 opened this issue Jan 7, 2017 · 4 comments

Comments

@kvsl9
Copy link

kvsl9 commented Jan 7, 2017

menu 控件默认全部展开后,无法单击收回
使用属性:default-openeds="[1,2,3]"

ElementUI version

1.1.2

OS/Browers version

win10/chrome 55.0.2859.0

Vue version

2.1.8

Reproduction Link

Steps to reproduce

What is Expected?

What is actually happening?

Uncaught TypeError: this.openedMenus.splice is not a function
at VueComponent.closeMenu (index.js:3)
at VueComponent.boundFn [as closeMenu] (vue.js:129)
at VueComponent.handleSubmenuClick (index.js:3)
at VueComponent.boundFn [as handleSubmenuClick] (vue.js:129)
at VueComponent.handleClick (index.js:3)
at HTMLDivElement.boundFn (vue.js:130)

@baiyaaaaa
Copy link
Contributor

请提供demo

@kvsl9
Copy link
Author

kvsl9 commented Jan 9, 2017

@QingWei-Li
问题解决了,:default-openeds需要在冒号,之前的代码没加冒号。

@ChangeZhang
Copy link

@kvsl9 求:default-openeds的用法

@SageSanyue
Copy link

@kvsl9 求:default-openeds的用法

:default-openeds="['2','3']" it works!!

<el-menu :default-openeds="['2','3']"> <el-menu-item index="1">工作台</el-menu-item> <el-submenu index="2">导航2</el-submenu> <el-submenu index="3">导航3</el-submenu> </el-menu>

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

No branches or pull requests

5 participants