{"action":"created","comment":{"url":"https://api.github.com/repos/ecomfe/ub-ria/pulls/comments/55791579","id":55791579,"diff_hunk":"@@ -263,27 +306,62 @@ define(\n          * @protected\n          * @method mvc.ListView#commandHandler\n          * @param {mini-event.Event} e command事件\n+         * @deprecated\n          */\n         exports.commandHandler = function (e) {\n-            if (e.triggerType === 'click') {\n-                var transition = u.findWhere(this.model.getStatusTransitions(), {statusName: e.name});\n-                // 处理状态修改\n+            this.handleTableCommand(e.triggerType, e.name, e.args);\n+        };\n+\n+        /**\n+         * 处理command\n+         *\n+         * @method mvc.ListView#handleTableCommand\n+         * @param {string} triggerType command事件的触发方式\n+         * @param {string} name command名称\n+         * @param {string} args command参数\n+         * @return {boolean} command是否被处理过\n+         * @protected\n+         */\n+        exports.handleTableCommand = function (triggerType, name, args) {\n+            var handled = this.handleStatusCommand(triggerType, name, args);","path":"src/mvc/ListView.js","position":77,"original_position":77,"commit_id":"952ff5e9126a14fabf6dd87884c3addfe74f205f","original_commit_id":"952ff5e9126a14fabf6dd87884c3addfe74f205f","user":{"login":"yanghuabei","id":6822885,"avatar_url":"https://avatars.githubusercontent.com/u/6822885?v=3","gravatar_id":"","url":"https://api.github.com/users/yanghuabei","html_url":"https://github.com/yanghuabei","followers_url":"https://api.github.com/users/yanghuabei/followers","following_url":"https://api.github.com/users/yanghuabei/following{/other_user}","gists_url":"https://api.github.com/users/yanghuabei/gists{/gist_id}","starred_url":"https://api.github.com/users/yanghuabei/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yanghuabei/subscriptions","organizations_url":"https://api.github.com/users/yanghuabei/orgs","repos_url":"https://api.github.com/users/yanghuabei/repos","events_url":"https://api.github.com/users/yanghuabei/events{/privacy}","received_events_url":"https://api.github.com/users/yanghuabei/received_events","type":"User","site_admin":false},"body":"讨论了一下，结论是handleStatusCommand这个方法有问题，这段逻辑其实就是简单的command分发，没必要单独封装。我改一下发个pr~","created_at":"2016-03-11T05:43:45Z","updated_at":"2016-03-11T05:43:45Z","html_url":"https://github.com/ecomfe/ub-ria/pull/263#discussion_r55791579","pull_request_url":"https://api.github.com/repos/ecomfe/ub-ria/pulls/263","_links":{"self":{"href":"https://api.github.com/repos/ecomfe/ub-ria/pulls/comments/55791579"},"html":{"href":"https://github.com/ecomfe/ub-ria/pull/263#discussion_r55791579"},"pull_request":{"href":"https://api.github.com/repos/ecomfe/ub-ria/pulls/263"}}},"pull_request":{"url":"https://api.github.com/repos/ecomfe/ub-ria/pulls/263","id":62038393,"html_url":"https://github.com/ecomfe/ub-ria/pull/263","diff_url":"https://github.com/ecomfe/ub-ria/pull/263.diff","patch_url":"https://github.com/ecomfe/ub-ria/pull/263.patch","issue_url":"https://api.github.com/repos/ecomfe/ub-ria/issues/263","number":263,"state":"closed","locked":false,"title":"列表mvc增加查看报告command，修改command事件处理的逻辑","user":{"login":"yanghuabei","id":6822885,"avatar_url":"https://avatars.githubusercontent.com/u/6822885?v=3","gravatar_id":"","url":"https://api.github.com/users/yanghuabei","html_url":"https://github.com/yanghuabei","followers_url":"https://api.github.com/users/yanghuabei/followers","following_url":"https://api.github.com/users/yanghuabei/following{/other_user}","gists_url":"https://api.github.com/users/yanghuabei/gists{/gist_id}","starred_url":"https://api.github.com/users/yanghuabei/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yanghuabei/subscriptions","organizations_url":"https://api.github.com/users/yanghuabei/orgs","repos_url":"https://api.github.com/users/yanghuabei/repos","events_url":"https://api.github.com/users/yanghuabei/events{/privacy}","received_events_url":"https://api.github.com/users/yanghuabei/received_events","type":"User","site_admin":false},"body":"https://github.com/ecomfe/ub-ria/issues/262","created_at":"2016-03-08T08:20:41Z","updated_at":"2016-03-11T05:43:45Z","closed_at":"2016-03-11T03:47:35Z","merged_at":"2016-03-11T03:47:35Z","merge_commit_sha":"d165e1310151f9e46386920089de63fdb6f68614","assignee":{"login":"otakustay","id":639549,"avatar_url":"https://avatars.githubusercontent.com/u/639549?v=3","gravatar_id":"","url":"https://api.github.com/users/otakustay","html_url":"https://github.com/otakustay","followers_url":"https://api.github.com/users/otakustay/followers","following_url":"https://api.github.com/users/otakustay/following{/other_user}","gists_url":"https://api.github.com/users/otakustay/gists{/gist_id}","starred_url":"https://api.github.com/users/otakustay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/otakustay/subscriptions","organizations_url":"https://api.github.com/users/otakustay/orgs","repos_url":"https://api.github.com/users/otakustay/repos","events_url":"https://api.github.com/users/otakustay/events{/privacy}","received_events_url":"https://api.github.com/users/otakustay/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/ecomfe/ub-ria/pulls/263/commits","review_comments_url":"https://api.github.com/repos/ecomfe/ub-ria/pulls/263/comments","review_comment_url":"https://api.github.com/repos/ecomfe/ub-ria/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ecomfe/ub-ria/issues/263/comments","statuses_url":"https://api.github.com/repos/ecomfe/ub-ria/statuses/952ff5e9126a14fabf6dd87884c3addfe74f205f","head":{"label":"yanghuabei:add-report-command-to-list","ref":"add-report-command-to-list","sha":"952ff5e9126a14fabf6dd87884c3addfe74f205f","user":{"login":"yanghuabei","id":6822885,"avatar_url":"https://avatars.githubusercontent.com/u/6822885?v=3","gravatar_id":"","url":"https://api.github.com/users/yanghuabei","html_url":"https://github.com/yanghuabei","followers_url":"https://api.github.com/users/yanghuabei/followers","following_url":"https://api.github.com/users/yanghuabei/following{/other_user}","gists_url":"https://api.github.com/users/yanghuabei/gists{/gist_id}","starred_url":"https://api.github.com/users/yanghuabei/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yanghuabei/subscriptions","organizations_url":"https://api.github.com/users/yanghuabei/orgs","repos_url":"https://api.github.com/users/yanghuabei/repos","events_url":"https://api.github.com/users/yanghuabei/events{/privacy}","received_events_url":"https://api.github.com/users/yanghuabei/received_events","type":"User","site_admin":false},"repo":{"id":17354427,"name":"ub-ria","full_name":"yanghuabei/ub-ria","owner":{"login":"yanghuabei","id":6822885,"avatar_url":"https://avatars.githubusercontent.com/u/6822885?v=3","gravatar_id":"","url":"https://api.github.com/users/yanghuabei","html_url":"https://github.com/yanghuabei","followers_url":"https://api.github.com/users/yanghuabei/followers","following_url":"https://api.github.com/users/yanghuabei/following{/other_user}","gists_url":"https://api.github.com/users/yanghuabei/gists{/gist_id}","starred_url":"https://api.github.com/users/yanghuabei/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yanghuabei/subscriptions","organizations_url":"https://api.github.com/users/yanghuabei/orgs","repos_url":"https://api.github.com/users/yanghuabei/repos","events_url":"https://api.github.com/users/yanghuabei/events{/privacy}","received_events_url":"https://api.github.com/users/yanghuabei/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/yanghuabei/ub-ria","description":"RIA base for union business","fork":true,"url":"https://api.github.com/repos/yanghuabei/ub-ria","forks_url":"https://api.github.com/repos/yanghuabei/ub-ria/forks","keys_url":"https://api.github.com/repos/yanghuabei/ub-ria/keys{/key_id}","collaborators_url":"https://api.github.com/repos/yanghuabei/ub-ria/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/yanghuabei/ub-ria/teams","hooks_url":"https://api.github.com/repos/yanghuabei/ub-ria/hooks","issue_events_url":"https://api.github.com/repos/yanghuabei/ub-ria/issues/events{/number}","events_url":"https://api.github.com/repos/yanghuabei/ub-ria/events","assignees_url":"https://api.github.com/repos/yanghuabei/ub-ria/assignees{/user}","branches_url":"https://api.github.com/repos/yanghuabei/ub-ria/branches{/branch}","tags_url":"https://api.github.com/repos/yanghuabei/ub-ria/tags","blobs_url":"https://api.github.com/repos/yanghuabei/ub-ria/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/yanghuabei/ub-ria/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/yanghuabei/ub-ria/git/refs{/sha}","trees_url":"https://api.github.com/repos/yanghuabei/ub-ria/git/trees{/sha}","statuses_url":"https://api.github.com/repos/yanghuabei/ub-ria/statuses/{sha}","languages_url":"https://api.github.com/repos/yanghuabei/ub-ria/languages","stargazers_url":"https://api.github.com/repos/yanghuabei/ub-ria/stargazers","contributors_url":"https://api.github.com/repos/yanghuabei/ub-ria/contributors","subscribers_url":"https://api.github.com/repos/yanghuabei/ub-ria/subscribers","subscription_url":"https://api.github.com/repos/yanghuabei/ub-ria/subscription","commits_url":"https://api.github.com/repos/yanghuabei/ub-ria/commits{/sha}","git_commits_url":"https://api.github.com/repos/yanghuabei/ub-ria/git/commits{/sha}","comments_url":"https://api.github.com/repos/yanghuabei/ub-ria/comments{/number}","issue_comment_url":"https://api.github.com/repos/yanghuabei/ub-ria/issues/comments{/number}","contents_url":"https://api.github.com/repos/yanghuabei/ub-ria/contents/{+path}","compare_url":"https://api.github.com/repos/yanghuabei/ub-ria/compare/{base}...{head}","merges_url":"https://api.github.com/repos/yanghuabei/ub-ria/merges","archive_url":"https://api.github.com/repos/yanghuabei/ub-ria/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/yanghuabei/ub-ria/downloads","issues_url":"https://api.github.com/repos/yanghuabei/ub-ria/issues{/number}","pulls_url":"https://api.github.com/repos/yanghuabei/ub-ria/pulls{/number}","milestones_url":"https://api.github.com/repos/yanghuabei/ub-ria/milestones{/number}","notifications_url":"https://api.github.com/repos/yanghuabei/ub-ria/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/yanghuabei/ub-ria/labels{/name}","releases_url":"https://api.github.com/repos/yanghuabei/ub-ria/releases{/id}","deployments_url":"https://api.github.com/repos/yanghuabei/ub-ria/deployments","created_at":"2014-03-03T03:47:40Z","updated_at":"2016-03-08T04:09:22Z","pushed_at":"2016-03-08T06:41:49Z","git_url":"git://github.com/yanghuabei/ub-ria.git","ssh_url":"git@github.com:yanghuabei/ub-ria.git","clone_url":"https://github.com/yanghuabei/ub-ria.git","svn_url":"https://github.com/yanghuabei/ub-ria","homepage":null,"size":1208,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ecomfe:master","ref":"master","sha":"8aa3a6653e0aaeef96afaa11b8a98d8a70fb1991","user":{"login":"ecomfe","id":2268460,"avatar_url":"https://avatars.githubusercontent.com/u/2268460?v=3","gravatar_id":"","url":"https://api.github.com/users/ecomfe","html_url":"https://github.com/ecomfe","followers_url":"https://api.github.com/users/ecomfe/followers","following_url":"https://api.github.com/users/ecomfe/following{/other_user}","gists_url":"https://api.github.com/users/ecomfe/gists{/gist_id}","starred_url":"https://api.github.com/users/ecomfe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ecomfe/subscriptions","organizations_url":"https://api.github.com/users/ecomfe/orgs","repos_url":"https://api.github.com/users/ecomfe/repos","events_url":"https://api.github.com/users/ecomfe/events{/privacy}","received_events_url":"https://api.github.com/users/ecomfe/received_events","type":"Organization","site_admin":false},"repo":{"id":15821257,"name":"ub-ria","full_name":"ecomfe/ub-ria","owner":{"login":"ecomfe","id":2268460,"avatar_url":"https://avatars.githubusercontent.com/u/2268460?v=3","gravatar_id":"","url":"https://api.github.com/users/ecomfe","html_url":"https://github.com/ecomfe","followers_url":"https://api.github.com/users/ecomfe/followers","following_url":"https://api.github.com/users/ecomfe/following{/other_user}","gists_url":"https://api.github.com/users/ecomfe/gists{/gist_id}","starred_url":"https://api.github.com/users/ecomfe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ecomfe/subscriptions","organizations_url":"https://api.github.com/users/ecomfe/orgs","repos_url":"https://api.github.com/users/ecomfe/repos","events_url":"https://api.github.com/users/ecomfe/events{/privacy}","received_events_url":"https://api.github.com/users/ecomfe/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ecomfe/ub-ria","description":"RIA base for union business","fork":false,"url":"https://api.github.com/repos/ecomfe/ub-ria","forks_url":"https://api.github.com/repos/ecomfe/ub-ria/forks","keys_url":"https://api.github.com/repos/ecomfe/ub-ria/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ecomfe/ub-ria/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ecomfe/ub-ria/teams","hooks_url":"https://api.github.com/repos/ecomfe/ub-ria/hooks","issue_events_url":"https://api.github.com/repos/ecomfe/ub-ria/issues/events{/number}","events_url":"https://api.github.com/repos/ecomfe/ub-ria/events","assignees_url":"https://api.github.com/repos/ecomfe/ub-ria/assignees{/user}","branches_url":"https://api.github.com/repos/ecomfe/ub-ria/branches{/branch}","tags_url":"https://api.github.com/repos/ecomfe/ub-ria/tags","blobs_url":"https://api.github.com/repos/ecomfe/ub-ria/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ecomfe/ub-ria/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ecomfe/ub-ria/git/refs{/sha}","trees_url":"https://api.github.com/repos/ecomfe/ub-ria/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ecomfe/ub-ria/statuses/{sha}","languages_url":"https://api.github.com/repos/ecomfe/ub-ria/languages","stargazers_url":"https://api.github.com/repos/ecomfe/ub-ria/stargazers","contributors_url":"https://api.github.com/repos/ecomfe/ub-ria/contributors","subscribers_url":"https://api.github.com/repos/ecomfe/ub-ria/subscribers","subscription_url":"https://api.github.com/repos/ecomfe/ub-ria/subscription","commits_url":"https://api.github.com/repos/ecomfe/ub-ria/commits{/sha}","git_commits_url":"https://api.github.com/repos/ecomfe/ub-ria/git/commits{/sha}","comments_url":"https://api.github.com/repos/ecomfe/ub-ria/comments{/number}","issue_comment_url":"https://api.github.com/repos/ecomfe/ub-ria/issues/comments{/number}","contents_url":"https://api.github.com/repos/ecomfe/ub-ria/contents/{+path}","compare_url":"https://api.github.com/repos/ecomfe/ub-ria/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ecomfe/ub-ria/merges","archive_url":"https://api.github.com/repos/ecomfe/ub-ria/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ecomfe/ub-ria/downloads","issues_url":"https://api.github.com/repos/ecomfe/ub-ria/issues{/number}","pulls_url":"https://api.github.com/repos/ecomfe/ub-ria/pulls{/number}","milestones_url":"https://api.github.com/repos/ecomfe/ub-ria/milestones{/number}","notifications_url":"https://api.github.com/repos/ecomfe/ub-ria/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ecomfe/ub-ria/labels{/name}","releases_url":"https://api.github.com/repos/ecomfe/ub-ria/releases{/id}","deployments_url":"https://api.github.com/repos/ecomfe/ub-ria/deployments","created_at":"2014-01-11T11:15:10Z","updated_at":"2016-03-07T06:13:49Z","pushed_at":"2016-03-11T03:47:36Z","git_url":"git://github.com/ecomfe/ub-ria.git","ssh_url":"git@github.com:ecomfe/ub-ria.git","clone_url":"https://github.com/ecomfe/ub-ria.git","svn_url":"https://github.com/ecomfe/ub-ria","homepage":null,"size":1519,"stargazers_count":30,"watchers_count":30,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":18,"mirror_url":null,"open_issues_count":21,"forks":18,"open_issues":21,"watchers":30,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ecomfe/ub-ria/pulls/263"},"html":{"href":"https://github.com/ecomfe/ub-ria/pull/263"},"issue":{"href":"https://api.github.com/repos/ecomfe/ub-ria/issues/263"},"comments":{"href":"https://api.github.com/repos/ecomfe/ub-ria/issues/263/comments"},"review_comments":{"href":"https://api.github.com/repos/ecomfe/ub-ria/pulls/263/comments"},"review_comment":{"href":"https://api.github.com/repos/ecomfe/ub-ria/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ecomfe/ub-ria/pulls/263/commits"},"statuses":{"href":"https://api.github.com/repos/ecomfe/ub-ria/statuses/952ff5e9126a14fabf6dd87884c3addfe74f205f"}}}}