{"action":"created","issue":{"url":"https://api.github.com/repos/ElemeFE/element/issues/616","repository_url":"https://api.github.com/repos/ElemeFE/element","labels_url":"https://api.github.com/repos/ElemeFE/element/issues/616/labels{/name}","comments_url":"https://api.github.com/repos/ElemeFE/element/issues/616/comments","events_url":"https://api.github.com/repos/ElemeFE/element/issues/616/events","html_url":"https://github.com/ElemeFE/element/issues/616","id":184775353,"number":616,"title":"menu-item的route 跳转逻辑错误","user":{"login":"leonwa","id":8072417,"avatar_url":"https://avatars.githubusercontent.com/u/8072417?v=3","gravatar_id":"","url":"https://api.github.com/users/leonwa","html_url":"https://github.com/leonwa","followers_url":"https://api.github.com/users/leonwa/followers","following_url":"https://api.github.com/users/leonwa/following{/other_user}","gists_url":"https://api.github.com/users/leonwa/gists{/gist_id}","starred_url":"https://api.github.com/users/leonwa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leonwa/subscriptions","organizations_url":"https://api.github.com/users/leonwa/orgs","repos_url":"https://api.github.com/users/leonwa/repos","events_url":"https://api.github.com/users/leonwa/events{/privacy}","received_events_url":"https://api.github.com/users/leonwa/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-10-24T08:13:41Z","updated_at":"2016-10-25T08:35:46Z","closed_at":"2016-10-24T09:35:25Z","body":"<!--\r\n提交 issue 前请务必查看 FAQ：https://github.com/ElemeFE/element/blob/master/FAQ.md。如果你的问题可以在 FAQ 中找到解决方案，我们会直接关闭 issue。\r\n -->\r\n\r\n<!--\r\nissue 仅用于提交 bug 或 feature 以及设计相关的内容，其它疑问请到 gitter 聊天室找社区里面的小伙伴聊一聊：https://gitter.im/ElemeFE/element\r\n -->\r\n \r\n<!--\r\nIssues are exclusively for bug reports and feature requests. For other questions, please visit gitter: https://gitter.im/ElemeFE/element\r\n-->\r\n\r\n<!--\r\nThank you for contributing! Please carefully read the following before opening your issue.\r\n -->\r\n\r\n### ElementUI version\r\n 1.0.0-rc.2 \r\n\r\n\r\n### Vue version\r\n2.0.0-rc.4\r\n\r\n### Steps to reproduce\r\n定义el-menu-item， 定义了route对象\r\n`<el-menu-item v-else :index=\"menu.id\" :route=\"menu\" >`\r\n点击菜单\r\n### What is Expected?\r\n点击是应该跳转\r\n### What is actually happening?\r\n并没跳转\r\n看了一下代码，\r\nmenu.vue -> handleSelect(index, indexPath, route)  跳转前检查了 this.router 对象， 实际应为 this.$router"},"comment":{"url":"https://api.github.com/repos/ElemeFE/element/issues/comments/255972532","html_url":"https://github.com/ElemeFE/element/issues/616#issuecomment-255972532","issue_url":"https://api.github.com/repos/ElemeFE/element/issues/616","id":255972532,"user":{"login":"leonwa","id":8072417,"avatar_url":"https://avatars.githubusercontent.com/u/8072417?v=3","gravatar_id":"","url":"https://api.github.com/users/leonwa","html_url":"https://github.com/leonwa","followers_url":"https://api.github.com/users/leonwa/followers","following_url":"https://api.github.com/users/leonwa/following{/other_user}","gists_url":"https://api.github.com/users/leonwa/gists{/gist_id}","starred_url":"https://api.github.com/users/leonwa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leonwa/subscriptions","organizations_url":"https://api.github.com/users/leonwa/orgs","repos_url":"https://api.github.com/users/leonwa/repos","events_url":"https://api.github.com/users/leonwa/events{/privacy}","received_events_url":"https://api.github.com/users/leonwa/received_events","type":"User","site_admin":false},"created_at":"2016-10-25T08:35:46Z","updated_at":"2016-10-25T08:35:46Z","body":"```\r\n      handleSelect(index, indexPath, route, instance) {\r\n        this.activeIndex = index;\r\n        this.$emit('select', index, indexPath, instance);\r\n        if (this.mode === 'horizontal') {\r\n          this.broadcast('submenu', 'item-select', [index, indexPath]);\r\n          this.openedMenus = [];\r\n        } else {\r\n          this.openActiveItemMenus();\r\n        }\r\n        if (this.router && route) {\r\n          this.$router.push(route);\r\n        }\r\n      },\r\n```\r\n\r\n注意 这段， this.router应该是this.$router\r\n        if (this.router && route) {\r\n          this.$router.push(route);\r\n        }"}}
{"actor":{"display_login":"leonwa"}}