{"action":"created","comment":{"url":"https://api.github.com/repos/TEAMMATES/teammates/pulls/comments/107341553","pull_request_review_id":28304866,"id":107341553,"diff_hunk":"@@ -205,37 +205,79 @@ function updateStatsCheckBox() {\n     $('input[id=statsShownCheckBox]').val($('#show-stats-checkbox').is(':checked'));\n }\n \n-function toggleCollapse(e, pans) {\n-    var expand = 'Expand';\n-    var collapse = 'Collapse';\n-    var panels = pans || $('div.panel-collapse');\n-\n-    if ($(e).html().trim().startsWith(expand)) {\n-        var i = 0;\n-        for (var idx = 0; idx < panels.length; idx++) {\n-            if ($(panels[idx]).attr('class').indexOf('in') === -1) {\n-                setTimeout(showSingleCollapse, 50 * i, panels[idx]);\n-                i++;\n+/**\n+ * Expand each panel. If the panel data is not loaded, load it by Ajax first before expansion.\n+ */\n+function expand(panels, needToCheckForAjaxLoading) {\n+    var i = 0;\n+    for (var idx = 0; idx < panels.length; idx++) {\n+        if (needToCheckForAjaxLoading) {","path":"src/main/webapp/js/instructorFeedbackResults.js","position":21,"original_position":21,"commit_id":"b77a8513f2b2bc5f05fa1467c0cc48b4721daa1b","original_commit_id":"b77a8513f2b2bc5f05fa1467c0cc48b4721daa1b","user":{"login":"damithc","id":1673303,"avatar_url":"https://avatars0.githubusercontent.com/u/1673303?v=3","gravatar_id":"","url":"https://api.github.com/users/damithc","html_url":"https://github.com/damithc","followers_url":"https://api.github.com/users/damithc/followers","following_url":"https://api.github.com/users/damithc/following{/other_user}","gists_url":"https://api.github.com/users/damithc/gists{/gist_id}","starred_url":"https://api.github.com/users/damithc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/damithc/subscriptions","organizations_url":"https://api.github.com/users/damithc/orgs","repos_url":"https://api.github.com/users/damithc/repos","events_url":"https://api.github.com/users/damithc/events{/privacy}","received_events_url":"https://api.github.com/users/damithc/received_events","type":"User","site_admin":false},"body":"Instead of this\r\n```\r\nfunction foo(){\r\n  if(x){\r\n    //very\r\n    //long\r\n    //block\r\n  }\r\n}\r\n```\r\ncan do this (i.e. try to avoid nesting the 'happy path' of the code) ?\r\n```\r\nfunction foo(){\r\n  if(!x){\r\n    return;\r\n  }\r\n  //very\r\n  //long\r\n  //block\r\n}","created_at":"2017-03-22T06:43:06Z","updated_at":"2017-03-22T06:43:57Z","html_url":"https://github.com/TEAMMATES/teammates/pull/6608#discussion_r107341553","pull_request_url":"https://api.github.com/repos/TEAMMATES/teammates/pulls/6608","_links":{"self":{"href":"https://api.github.com/repos/TEAMMATES/teammates/pulls/comments/107341553"},"html":{"href":"https://github.com/TEAMMATES/teammates/pull/6608#discussion_r107341553"},"pull_request":{"href":"https://api.github.com/repos/TEAMMATES/teammates/pulls/6608"}}},"pull_request":{"url":"https://api.github.com/repos/TEAMMATES/teammates/pulls/6608","id":106152157,"html_url":"https://github.com/TEAMMATES/teammates/pull/6608","diff_url":"https://github.com/TEAMMATES/teammates/pull/6608.diff","patch_url":"https://github.com/TEAMMATES/teammates/pull/6608.patch","issue_url":"https://api.github.com/repos/TEAMMATES/teammates/issues/6608","number":6608,"state":"open","locked":false,"title":"Instructor view results: do not auto-load 3 questions #6568","user":{"login":"boxin-yang","id":16921967,"avatar_url":"https://avatars3.githubusercontent.com/u/16921967?v=3","gravatar_id":"","url":"https://api.github.com/users/boxin-yang","html_url":"https://github.com/boxin-yang","followers_url":"https://api.github.com/users/boxin-yang/followers","following_url":"https://api.github.com/users/boxin-yang/following{/other_user}","gists_url":"https://api.github.com/users/boxin-yang/gists{/gist_id}","starred_url":"https://api.github.com/users/boxin-yang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/boxin-yang/subscriptions","organizations_url":"https://api.github.com/users/boxin-yang/orgs","repos_url":"https://api.github.com/users/boxin-yang/repos","events_url":"https://api.github.com/users/boxin-yang/events{/privacy}","received_events_url":"https://api.github.com/users/boxin-yang/received_events","type":"User","site_admin":false},"body":"<!--\r\nPlease follow the naming conventions in the \"guidelines for contributing\" link above or the pull request may be rejected.\r\n\r\nAlso, do consider outlining the solution taken as doing so will likely help in the reviewing process\r\n(e.g., when the pull request involves non-trivial changes)\r\n-->\r\n\r\nFixes #6568 \r\n\r\n**Outline of Solution**\r\n\r\nThe auto loading is triggered by $('.ajax_auto').click() . Removing the line will not auto load the results.","created_at":"2017-02-14T17:22:32Z","updated_at":"2017-03-22T06:43:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"cec672045353a342befcfbece3cbf5a684b200c8","assignee":{"login":"junhaoyap","id":6291947,"avatar_url":"https://avatars2.githubusercontent.com/u/6291947?v=3","gravatar_id":"","url":"https://api.github.com/users/junhaoyap","html_url":"https://github.com/junhaoyap","followers_url":"https://api.github.com/users/junhaoyap/followers","following_url":"https://api.github.com/users/junhaoyap/following{/other_user}","gists_url":"https://api.github.com/users/junhaoyap/gists{/gist_id}","starred_url":"https://api.github.com/users/junhaoyap/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/junhaoyap/subscriptions","organizations_url":"https://api.github.com/users/junhaoyap/orgs","repos_url":"https://api.github.com/users/junhaoyap/repos","events_url":"https://api.github.com/users/junhaoyap/events{/privacy}","received_events_url":"https://api.github.com/users/junhaoyap/received_events","type":"User","site_admin":false},"assignees":[{"login":"junhaoyap","id":6291947,"avatar_url":"https://avatars2.githubusercontent.com/u/6291947?v=3","gravatar_id":"","url":"https://api.github.com/users/junhaoyap","html_url":"https://github.com/junhaoyap","followers_url":"https://api.github.com/users/junhaoyap/followers","following_url":"https://api.github.com/users/junhaoyap/following{/other_user}","gists_url":"https://api.github.com/users/junhaoyap/gists{/gist_id}","starred_url":"https://api.github.com/users/junhaoyap/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/junhaoyap/subscriptions","organizations_url":"https://api.github.com/users/junhaoyap/orgs","repos_url":"https://api.github.com/users/junhaoyap/repos","events_url":"https://api.github.com/users/junhaoyap/events{/privacy}","received_events_url":"https://api.github.com/users/junhaoyap/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/TEAMMATES/teammates/pulls/6608/commits","review_comments_url":"https://api.github.com/repos/TEAMMATES/teammates/pulls/6608/comments","review_comment_url":"https://api.github.com/repos/TEAMMATES/teammates/pulls/comments{/number}","comments_url":"https://api.github.com/repos/TEAMMATES/teammates/issues/6608/comments","statuses_url":"https://api.github.com/repos/TEAMMATES/teammates/statuses/b77a8513f2b2bc5f05fa1467c0cc48b4721daa1b","head":{"label":"boxin-yang:6568-do-not-auto-load-3-questions-in-instructor-view-result","ref":"6568-do-not-auto-load-3-questions-in-instructor-view-result","sha":"b77a8513f2b2bc5f05fa1467c0cc48b4721daa1b","user":{"login":"boxin-yang","id":16921967,"avatar_url":"https://avatars3.githubusercontent.com/u/16921967?v=3","gravatar_id":"","url":"https://api.github.com/users/boxin-yang","html_url":"https://github.com/boxin-yang","followers_url":"https://api.github.com/users/boxin-yang/followers","following_url":"https://api.github.com/users/boxin-yang/following{/other_user}","gists_url":"https://api.github.com/users/boxin-yang/gists{/gist_id}","starred_url":"https://api.github.com/users/boxin-yang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/boxin-yang/subscriptions","organizations_url":"https://api.github.com/users/boxin-yang/orgs","repos_url":"https://api.github.com/users/boxin-yang/repos","events_url":"https://api.github.com/users/boxin-yang/events{/privacy}","received_events_url":"https://api.github.com/users/boxin-yang/received_events","type":"User","site_admin":false},"repo":{"id":78867781,"name":"teammates","full_name":"boxin-yang/teammates","owner":{"login":"boxin-yang","id":16921967,"avatar_url":"https://avatars3.githubusercontent.com/u/16921967?v=3","gravatar_id":"","url":"https://api.github.com/users/boxin-yang","html_url":"https://github.com/boxin-yang","followers_url":"https://api.github.com/users/boxin-yang/followers","following_url":"https://api.github.com/users/boxin-yang/following{/other_user}","gists_url":"https://api.github.com/users/boxin-yang/gists{/gist_id}","starred_url":"https://api.github.com/users/boxin-yang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/boxin-yang/subscriptions","organizations_url":"https://api.github.com/users/boxin-yang/orgs","repos_url":"https://api.github.com/users/boxin-yang/repos","events_url":"https://api.github.com/users/boxin-yang/events{/privacy}","received_events_url":"https://api.github.com/users/boxin-yang/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/boxin-yang/teammates","description":"This is the project website for the TEAMMATES feedback management tool for education","fork":true,"url":"https://api.github.com/repos/boxin-yang/teammates","forks_url":"https://api.github.com/repos/boxin-yang/teammates/forks","keys_url":"https://api.github.com/repos/boxin-yang/teammates/keys{/key_id}","collaborators_url":"https://api.github.com/repos/boxin-yang/teammates/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/boxin-yang/teammates/teams","hooks_url":"https://api.github.com/repos/boxin-yang/teammates/hooks","issue_events_url":"https://api.github.com/repos/boxin-yang/teammates/issues/events{/number}","events_url":"https://api.github.com/repos/boxin-yang/teammates/events","assignees_url":"https://api.github.com/repos/boxin-yang/teammates/assignees{/user}","branches_url":"https://api.github.com/repos/boxin-yang/teammates/branches{/branch}","tags_url":"https://api.github.com/repos/boxin-yang/teammates/tags","blobs_url":"https://api.github.com/repos/boxin-yang/teammates/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/boxin-yang/teammates/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/boxin-yang/teammates/git/refs{/sha}","trees_url":"https://api.github.com/repos/boxin-yang/teammates/git/trees{/sha}","statuses_url":"https://api.github.com/repos/boxin-yang/teammates/statuses/{sha}","languages_url":"https://api.github.com/repos/boxin-yang/teammates/languages","stargazers_url":"https://api.github.com/repos/boxin-yang/teammates/stargazers","contributors_url":"https://api.github.com/repos/boxin-yang/teammates/contributors","subscribers_url":"https://api.github.com/repos/boxin-yang/teammates/subscribers","subscription_url":"https://api.github.com/repos/boxin-yang/teammates/subscription","commits_url":"https://api.github.com/repos/boxin-yang/teammates/commits{/sha}","git_commits_url":"https://api.github.com/repos/boxin-yang/teammates/git/commits{/sha}","comments_url":"https://api.github.com/repos/boxin-yang/teammates/comments{/number}","issue_comment_url":"https://api.github.com/repos/boxin-yang/teammates/issues/comments{/number}","contents_url":"https://api.github.com/repos/boxin-yang/teammates/contents/{+path}","compare_url":"https://api.github.com/repos/boxin-yang/teammates/compare/{base}...{head}","merges_url":"https://api.github.com/repos/boxin-yang/teammates/merges","archive_url":"https://api.github.com/repos/boxin-yang/teammates/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/boxin-yang/teammates/downloads","issues_url":"https://api.github.com/repos/boxin-yang/teammates/issues{/number}","pulls_url":"https://api.github.com/repos/boxin-yang/teammates/pulls{/number}","milestones_url":"https://api.github.com/repos/boxin-yang/teammates/milestones{/number}","notifications_url":"https://api.github.com/repos/boxin-yang/teammates/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/boxin-yang/teammates/labels{/name}","releases_url":"https://api.github.com/repos/boxin-yang/teammates/releases{/id}","deployments_url":"https://api.github.com/repos/boxin-yang/teammates/deployments","created_at":"2017-01-13T16:56:54Z","updated_at":"2017-01-13T16:57:02Z","pushed_at":"2017-03-22T06:05:39Z","git_url":"git://github.com/boxin-yang/teammates.git","ssh_url":"git@github.com:boxin-yang/teammates.git","clone_url":"https://github.com/boxin-yang/teammates.git","svn_url":"https://github.com/boxin-yang/teammates","homepage":"http://teammatesv4.appspot.com/","size":180924,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"TEAMMATES:master","ref":"master","sha":"9dd911875875a1130549d86a7067b86b0479a74f","user":{"login":"TEAMMATES","id":7374810,"avatar_url":"https://avatars1.githubusercontent.com/u/7374810?v=3","gravatar_id":"","url":"https://api.github.com/users/TEAMMATES","html_url":"https://github.com/TEAMMATES","followers_url":"https://api.github.com/users/TEAMMATES/followers","following_url":"https://api.github.com/users/TEAMMATES/following{/other_user}","gists_url":"https://api.github.com/users/TEAMMATES/gists{/gist_id}","starred_url":"https://api.github.com/users/TEAMMATES/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TEAMMATES/subscriptions","organizations_url":"https://api.github.com/users/TEAMMATES/orgs","repos_url":"https://api.github.com/users/TEAMMATES/repos","events_url":"https://api.github.com/users/TEAMMATES/events{/privacy}","received_events_url":"https://api.github.com/users/TEAMMATES/received_events","type":"Organization","site_admin":false},"repo":{"id":19369035,"name":"teammates","full_name":"TEAMMATES/teammates","owner":{"login":"TEAMMATES","id":7374810,"avatar_url":"https://avatars1.githubusercontent.com/u/7374810?v=3","gravatar_id":"","url":"https://api.github.com/users/TEAMMATES","html_url":"https://github.com/TEAMMATES","followers_url":"https://api.github.com/users/TEAMMATES/followers","following_url":"https://api.github.com/users/TEAMMATES/following{/other_user}","gists_url":"https://api.github.com/users/TEAMMATES/gists{/gist_id}","starred_url":"https://api.github.com/users/TEAMMATES/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TEAMMATES/subscriptions","organizations_url":"https://api.github.com/users/TEAMMATES/orgs","repos_url":"https://api.github.com/users/TEAMMATES/repos","events_url":"https://api.github.com/users/TEAMMATES/events{/privacy}","received_events_url":"https://api.github.com/users/TEAMMATES/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/TEAMMATES/teammates","description":"This is the project website for the TEAMMATES feedback management tool for education","fork":false,"url":"https://api.github.com/repos/TEAMMATES/teammates","forks_url":"https://api.github.com/repos/TEAMMATES/teammates/forks","keys_url":"https://api.github.com/repos/TEAMMATES/teammates/keys{/key_id}","collaborators_url":"https://api.github.com/repos/TEAMMATES/teammates/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/TEAMMATES/teammates/teams","hooks_url":"https://api.github.com/repos/TEAMMATES/teammates/hooks","issue_events_url":"https://api.github.com/repos/TEAMMATES/teammates/issues/events{/number}","events_url":"https://api.github.com/repos/TEAMMATES/teammates/events","assignees_url":"https://api.github.com/repos/TEAMMATES/teammates/assignees{/user}","branches_url":"https://api.github.com/repos/TEAMMATES/teammates/branches{/branch}","tags_url":"https://api.github.com/repos/TEAMMATES/teammates/tags","blobs_url":"https://api.github.com/repos/TEAMMATES/teammates/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/TEAMMATES/teammates/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/TEAMMATES/teammates/git/refs{/sha}","trees_url":"https://api.github.com/repos/TEAMMATES/teammates/git/trees{/sha}","statuses_url":"https://api.github.com/repos/TEAMMATES/teammates/statuses/{sha}","languages_url":"https://api.github.com/repos/TEAMMATES/teammates/languages","stargazers_url":"https://api.github.com/repos/TEAMMATES/teammates/stargazers","contributors_url":"https://api.github.com/repos/TEAMMATES/teammates/contributors","subscribers_url":"https://api.github.com/repos/TEAMMATES/teammates/subscribers","subscription_url":"https://api.github.com/repos/TEAMMATES/teammates/subscription","commits_url":"https://api.github.com/repos/TEAMMATES/teammates/commits{/sha}","git_commits_url":"https://api.github.com/repos/TEAMMATES/teammates/git/commits{/sha}","comments_url":"https://api.github.com/repos/TEAMMATES/teammates/comments{/number}","issue_comment_url":"https://api.github.com/repos/TEAMMATES/teammates/issues/comments{/number}","contents_url":"https://api.github.com/repos/TEAMMATES/teammates/contents/{+path}","compare_url":"https://api.github.com/repos/TEAMMATES/teammates/compare/{base}...{head}","merges_url":"https://api.github.com/repos/TEAMMATES/teammates/merges","archive_url":"https://api.github.com/repos/TEAMMATES/teammates/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/TEAMMATES/teammates/downloads","issues_url":"https://api.github.com/repos/TEAMMATES/teammates/issues{/number}","pulls_url":"https://api.github.com/repos/TEAMMATES/teammates/pulls{/number}","milestones_url":"https://api.github.com/repos/TEAMMATES/teammates/milestones{/number}","notifications_url":"https://api.github.com/repos/TEAMMATES/teammates/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/TEAMMATES/teammates/labels{/name}","releases_url":"https://api.github.com/repos/TEAMMATES/teammates/releases{/id}","deployments_url":"https://api.github.com/repos/TEAMMATES/teammates/deployments","created_at":"2014-05-02T07:43:00Z","updated_at":"2017-03-20T15:36:34Z","pushed_at":"2017-03-22T06:25:21Z","git_url":"git://github.com/TEAMMATES/teammates.git","ssh_url":"git@github.com:TEAMMATES/teammates.git","clone_url":"https://github.com/TEAMMATES/teammates.git","svn_url":"https://github.com/TEAMMATES/teammates","homepage":"http://teammatesv4.appspot.com/","size":182123,"stargazers_count":272,"watchers_count":272,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":622,"mirror_url":null,"open_issues_count":524,"forks":622,"open_issues":524,"watchers":272,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/TEAMMATES/teammates/pulls/6608"},"html":{"href":"https://github.com/TEAMMATES/teammates/pull/6608"},"issue":{"href":"https://api.github.com/repos/TEAMMATES/teammates/issues/6608"},"comments":{"href":"https://api.github.com/repos/TEAMMATES/teammates/issues/6608/comments"},"review_comments":{"href":"https://api.github.com/repos/TEAMMATES/teammates/pulls/6608/comments"},"review_comment":{"href":"https://api.github.com/repos/TEAMMATES/teammates/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/TEAMMATES/teammates/pulls/6608/commits"},"statuses":{"href":"https://api.github.com/repos/TEAMMATES/teammates/statuses/b77a8513f2b2bc5f05fa1467c0cc48b4721daa1b"}}}}
{"actor":{"display_login":"damithc"}}