{"action":"closed","number":452,"pull_request":{"url":"https://api.github.com/repos/testmycode/tmc-server/pulls/452","id":92586356,"html_url":"https://github.com/testmycode/tmc-server/pull/452","diff_url":"https://github.com/testmycode/tmc-server/pull/452.diff","patch_url":"https://github.com/testmycode/tmc-server/pull/452.patch","issue_url":"https://api.github.com/repos/testmycode/tmc-server/issues/452","number":452,"state":"closed","locked":false,"title":"Api find submissions by course name or id","user":{"login":"Redande","id":10534869,"avatar_url":"https://avatars.githubusercontent.com/u/10534869?v=3","gravatar_id":"","url":"https://api.github.com/users/Redande","html_url":"https://github.com/Redande","followers_url":"https://api.github.com/users/Redande/followers","following_url":"https://api.github.com/users/Redande/following{/other_user}","gists_url":"https://api.github.com/users/Redande/gists{/gist_id}","starred_url":"https://api.github.com/users/Redande/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Redande/subscriptions","organizations_url":"https://api.github.com/users/Redande/orgs","repos_url":"https://api.github.com/users/Redande/repos","events_url":"https://api.github.com/users/Redande/events{/privacy}","received_events_url":"https://api.github.com/users/Redande/received_events","type":"User","site_admin":false},"body":"Find all submissions by course id: /api/v8/courses/{course_id}/exercises/submissions\r\nFind all submissions by course name: /api/v8/org/{organization_id}/courses/{course_name}/submissions\r\nFind single user's submissions by course id: /api/v8/courses/{course_id}/exercises/submissions/{user_id}\r\nFind single user's submissions by course name: /api/v8/org/{organization_id}/courses/{course_name}/submissions/{user_id}\r\nFind current user's submissions by course id: /api/v8/courses/{course_id}/exercises/submissions/mine\r\nFind current user's submissions by course name: /api/v8/org/{organization_id}/courses/{course_name}/submissions/mine\r\n\r\ncloses #434 \r\ncloses #433 \r\ncloses #436 \r\ncloses #435 \r\ncloses #438 \r\ncloses #437 \r\n\r\nJenkins builds: \r\nhttp://ohtu-jenkins.testmycode.io/job/tmc-server-api-submission-search/1/\r\nhttp://ohtu-jenkins.testmycode.io/job/tmc-server-api-submission-search/2/\r\n\r\nBuild 2 broke on jenkins somehow (1 test failed for some reason). I ran the tests locally and they passed so I re-scheduled the jenkins job. New build here (after jenkins queue clears...): \r\nhttp://ohtu-jenkins.testmycode.io/job/tmc-server-api-submission-search/3/\r\n -- makevertti\r\n\r\nNew build after fixes and refactors:\r\nhttp://ohtu-jenkins.testmycode.io/job/tmc-server-api-submission-search/7/","created_at":"2016-11-07T13:50:54Z","updated_at":"2016-11-14T13:05:16Z","closed_at":"2016-11-14T13:05:16Z","merged_at":"2016-11-14T13:05:16Z","merge_commit_sha":"0355eb7814eedba4aa554c29323a55abdba2aaa8","assignee":{"login":"jamo","id":1354151,"avatar_url":"https://avatars.githubusercontent.com/u/1354151?v=3","gravatar_id":"","url":"https://api.github.com/users/jamo","html_url":"https://github.com/jamo","followers_url":"https://api.github.com/users/jamo/followers","following_url":"https://api.github.com/users/jamo/following{/other_user}","gists_url":"https://api.github.com/users/jamo/gists{/gist_id}","starred_url":"https://api.github.com/users/jamo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jamo/subscriptions","organizations_url":"https://api.github.com/users/jamo/orgs","repos_url":"https://api.github.com/users/jamo/repos","events_url":"https://api.github.com/users/jamo/events{/privacy}","received_events_url":"https://api.github.com/users/jamo/received_events","type":"User","site_admin":false},"assignees":[{"login":"jamo","id":1354151,"avatar_url":"https://avatars.githubusercontent.com/u/1354151?v=3","gravatar_id":"","url":"https://api.github.com/users/jamo","html_url":"https://github.com/jamo","followers_url":"https://api.github.com/users/jamo/followers","following_url":"https://api.github.com/users/jamo/following{/other_user}","gists_url":"https://api.github.com/users/jamo/gists{/gist_id}","starred_url":"https://api.github.com/users/jamo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jamo/subscriptions","organizations_url":"https://api.github.com/users/jamo/orgs","repos_url":"https://api.github.com/users/jamo/repos","events_url":"https://api.github.com/users/jamo/events{/privacy}","received_events_url":"https://api.github.com/users/jamo/received_events","type":"User","site_admin":false},{"login":"nygrenh","id":1922896,"avatar_url":"https://avatars.githubusercontent.com/u/1922896?v=3","gravatar_id":"","url":"https://api.github.com/users/nygrenh","html_url":"https://github.com/nygrenh","followers_url":"https://api.github.com/users/nygrenh/followers","following_url":"https://api.github.com/users/nygrenh/following{/other_user}","gists_url":"https://api.github.com/users/nygrenh/gists{/gist_id}","starred_url":"https://api.github.com/users/nygrenh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nygrenh/subscriptions","organizations_url":"https://api.github.com/users/nygrenh/orgs","repos_url":"https://api.github.com/users/nygrenh/repos","events_url":"https://api.github.com/users/nygrenh/events{/privacy}","received_events_url":"https://api.github.com/users/nygrenh/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/testmycode/tmc-server/milestones/4","html_url":"https://github.com/testmycode/tmc-server/milestones/API%20MVP","labels_url":"https://api.github.com/repos/testmycode/tmc-server/milestones/4/labels","id":1983879,"number":4,"title":"API MVP","description":"Stuff for the new api","creator":{"login":"jamo","id":1354151,"avatar_url":"https://avatars.githubusercontent.com/u/1354151?v=3","gravatar_id":"","url":"https://api.github.com/users/jamo","html_url":"https://github.com/jamo","followers_url":"https://api.github.com/users/jamo/followers","following_url":"https://api.github.com/users/jamo/following{/other_user}","gists_url":"https://api.github.com/users/jamo/gists{/gist_id}","starred_url":"https://api.github.com/users/jamo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jamo/subscriptions","organizations_url":"https://api.github.com/users/jamo/orgs","repos_url":"https://api.github.com/users/jamo/repos","events_url":"https://api.github.com/users/jamo/events{/privacy}","received_events_url":"https://api.github.com/users/jamo/received_events","type":"User","site_admin":false},"open_issues":26,"closed_issues":15,"state":"open","created_at":"2016-09-05T10:17:36Z","updated_at":"2016-11-14T13:05:16Z","due_on":"2016-12-18T00:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/testmycode/tmc-server/pulls/452/commits","review_comments_url":"https://api.github.com/repos/testmycode/tmc-server/pulls/452/comments","review_comment_url":"https://api.github.com/repos/testmycode/tmc-server/pulls/comments{/number}","comments_url":"https://api.github.com/repos/testmycode/tmc-server/issues/452/comments","statuses_url":"https://api.github.com/repos/testmycode/tmc-server/statuses/a25e81bc2b598c27fad9584359772f3f4650a688","head":{"label":"testmycode:api-submission-search","ref":"api-submission-search","sha":"a25e81bc2b598c27fad9584359772f3f4650a688","user":{"login":"testmycode","id":893468,"avatar_url":"https://avatars.githubusercontent.com/u/893468?v=3","gravatar_id":"","url":"https://api.github.com/users/testmycode","html_url":"https://github.com/testmycode","followers_url":"https://api.github.com/users/testmycode/followers","following_url":"https://api.github.com/users/testmycode/following{/other_user}","gists_url":"https://api.github.com/users/testmycode/gists{/gist_id}","starred_url":"https://api.github.com/users/testmycode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/testmycode/subscriptions","organizations_url":"https://api.github.com/users/testmycode/orgs","repos_url":"https://api.github.com/users/testmycode/repos","events_url":"https://api.github.com/users/testmycode/events{/privacy}","received_events_url":"https://api.github.com/users/testmycode/received_events","type":"Organization","site_admin":false},"repo":{"id":1995270,"name":"tmc-server","full_name":"testmycode/tmc-server","owner":{"login":"testmycode","id":893468,"avatar_url":"https://avatars.githubusercontent.com/u/893468?v=3","gravatar_id":"","url":"https://api.github.com/users/testmycode","html_url":"https://github.com/testmycode","followers_url":"https://api.github.com/users/testmycode/followers","following_url":"https://api.github.com/users/testmycode/following{/other_user}","gists_url":"https://api.github.com/users/testmycode/gists{/gist_id}","starred_url":"https://api.github.com/users/testmycode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/testmycode/subscriptions","organizations_url":"https://api.github.com/users/testmycode/orgs","repos_url":"https://api.github.com/users/testmycode/repos","events_url":"https://api.github.com/users/testmycode/events{/privacy}","received_events_url":"https://api.github.com/users/testmycode/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/testmycode/tmc-server","description":"Test My Code exercise server used by e.g. http://mooc.fi/","fork":false,"url":"https://api.github.com/repos/testmycode/tmc-server","forks_url":"https://api.github.com/repos/testmycode/tmc-server/forks","keys_url":"https://api.github.com/repos/testmycode/tmc-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/testmycode/tmc-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/testmycode/tmc-server/teams","hooks_url":"https://api.github.com/repos/testmycode/tmc-server/hooks","issue_events_url":"https://api.github.com/repos/testmycode/tmc-server/issues/events{/number}","events_url":"https://api.github.com/repos/testmycode/tmc-server/events","assignees_url":"https://api.github.com/repos/testmycode/tmc-server/assignees{/user}","branches_url":"https://api.github.com/repos/testmycode/tmc-server/branches{/branch}","tags_url":"https://api.github.com/repos/testmycode/tmc-server/tags","blobs_url":"https://api.github.com/repos/testmycode/tmc-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/testmycode/tmc-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/testmycode/tmc-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/testmycode/tmc-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/testmycode/tmc-server/statuses/{sha}","languages_url":"https://api.github.com/repos/testmycode/tmc-server/languages","stargazers_url":"https://api.github.com/repos/testmycode/tmc-server/stargazers","contributors_url":"https://api.github.com/repos/testmycode/tmc-server/contributors","subscribers_url":"https://api.github.com/repos/testmycode/tmc-server/subscribers","subscription_url":"https://api.github.com/repos/testmycode/tmc-server/subscription","commits_url":"https://api.github.com/repos/testmycode/tmc-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/testmycode/tmc-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/testmycode/tmc-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/testmycode/tmc-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/testmycode/tmc-server/contents/{+path}","compare_url":"https://api.github.com/repos/testmycode/tmc-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/testmycode/tmc-server/merges","archive_url":"https://api.github.com/repos/testmycode/tmc-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/testmycode/tmc-server/downloads","issues_url":"https://api.github.com/repos/testmycode/tmc-server/issues{/number}","pulls_url":"https://api.github.com/repos/testmycode/tmc-server/pulls{/number}","milestones_url":"https://api.github.com/repos/testmycode/tmc-server/milestones{/number}","notifications_url":"https://api.github.com/repos/testmycode/tmc-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/testmycode/tmc-server/labels{/name}","releases_url":"https://api.github.com/repos/testmycode/tmc-server/releases{/id}","deployments_url":"https://api.github.com/repos/testmycode/tmc-server/deployments","created_at":"2011-07-04T12:29:36Z","updated_at":"2016-10-26T09:09:35Z","pushed_at":"2016-11-14T13:05:16Z","git_url":"git://github.com/testmycode/tmc-server.git","ssh_url":"git@github.com:testmycode/tmc-server.git","clone_url":"https://github.com/testmycode/tmc-server.git","svn_url":"https://github.com/testmycode/tmc-server","homepage":"","size":8866,"stargazers_count":17,"watchers_count":17,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":21,"mirror_url":null,"open_issues_count":140,"forks":21,"open_issues":140,"watchers":17,"default_branch":"master"}},"base":{"label":"testmycode:master","ref":"master","sha":"cd6885db87db582ad66f1b44b6420588cce5bdad","user":{"login":"testmycode","id":893468,"avatar_url":"https://avatars.githubusercontent.com/u/893468?v=3","gravatar_id":"","url":"https://api.github.com/users/testmycode","html_url":"https://github.com/testmycode","followers_url":"https://api.github.com/users/testmycode/followers","following_url":"https://api.github.com/users/testmycode/following{/other_user}","gists_url":"https://api.github.com/users/testmycode/gists{/gist_id}","starred_url":"https://api.github.com/users/testmycode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/testmycode/subscriptions","organizations_url":"https://api.github.com/users/testmycode/orgs","repos_url":"https://api.github.com/users/testmycode/repos","events_url":"https://api.github.com/users/testmycode/events{/privacy}","received_events_url":"https://api.github.com/users/testmycode/received_events","type":"Organization","site_admin":false},"repo":{"id":1995270,"name":"tmc-server","full_name":"testmycode/tmc-server","owner":{"login":"testmycode","id":893468,"avatar_url":"https://avatars.githubusercontent.com/u/893468?v=3","gravatar_id":"","url":"https://api.github.com/users/testmycode","html_url":"https://github.com/testmycode","followers_url":"https://api.github.com/users/testmycode/followers","following_url":"https://api.github.com/users/testmycode/following{/other_user}","gists_url":"https://api.github.com/users/testmycode/gists{/gist_id}","starred_url":"https://api.github.com/users/testmycode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/testmycode/subscriptions","organizations_url":"https://api.github.com/users/testmycode/orgs","repos_url":"https://api.github.com/users/testmycode/repos","events_url":"https://api.github.com/users/testmycode/events{/privacy}","received_events_url":"https://api.github.com/users/testmycode/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/testmycode/tmc-server","description":"Test My Code exercise server used by e.g. http://mooc.fi/","fork":false,"url":"https://api.github.com/repos/testmycode/tmc-server","forks_url":"https://api.github.com/repos/testmycode/tmc-server/forks","keys_url":"https://api.github.com/repos/testmycode/tmc-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/testmycode/tmc-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/testmycode/tmc-server/teams","hooks_url":"https://api.github.com/repos/testmycode/tmc-server/hooks","issue_events_url":"https://api.github.com/repos/testmycode/tmc-server/issues/events{/number}","events_url":"https://api.github.com/repos/testmycode/tmc-server/events","assignees_url":"https://api.github.com/repos/testmycode/tmc-server/assignees{/user}","branches_url":"https://api.github.com/repos/testmycode/tmc-server/branches{/branch}","tags_url":"https://api.github.com/repos/testmycode/tmc-server/tags","blobs_url":"https://api.github.com/repos/testmycode/tmc-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/testmycode/tmc-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/testmycode/tmc-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/testmycode/tmc-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/testmycode/tmc-server/statuses/{sha}","languages_url":"https://api.github.com/repos/testmycode/tmc-server/languages","stargazers_url":"https://api.github.com/repos/testmycode/tmc-server/stargazers","contributors_url":"https://api.github.com/repos/testmycode/tmc-server/contributors","subscribers_url":"https://api.github.com/repos/testmycode/tmc-server/subscribers","subscription_url":"https://api.github.com/repos/testmycode/tmc-server/subscription","commits_url":"https://api.github.com/repos/testmycode/tmc-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/testmycode/tmc-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/testmycode/tmc-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/testmycode/tmc-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/testmycode/tmc-server/contents/{+path}","compare_url":"https://api.github.com/repos/testmycode/tmc-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/testmycode/tmc-server/merges","archive_url":"https://api.github.com/repos/testmycode/tmc-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/testmycode/tmc-server/downloads","issues_url":"https://api.github.com/repos/testmycode/tmc-server/issues{/number}","pulls_url":"https://api.github.com/repos/testmycode/tmc-server/pulls{/number}","milestones_url":"https://api.github.com/repos/testmycode/tmc-server/milestones{/number}","notifications_url":"https://api.github.com/repos/testmycode/tmc-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/testmycode/tmc-server/labels{/name}","releases_url":"https://api.github.com/repos/testmycode/tmc-server/releases{/id}","deployments_url":"https://api.github.com/repos/testmycode/tmc-server/deployments","created_at":"2011-07-04T12:29:36Z","updated_at":"2016-10-26T09:09:35Z","pushed_at":"2016-11-14T13:05:16Z","git_url":"git://github.com/testmycode/tmc-server.git","ssh_url":"git@github.com:testmycode/tmc-server.git","clone_url":"https://github.com/testmycode/tmc-server.git","svn_url":"https://github.com/testmycode/tmc-server","homepage":"","size":8866,"stargazers_count":17,"watchers_count":17,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":21,"mirror_url":null,"open_issues_count":140,"forks":21,"open_issues":140,"watchers":17,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/testmycode/tmc-server/pulls/452"},"html":{"href":"https://github.com/testmycode/tmc-server/pull/452"},"issue":{"href":"https://api.github.com/repos/testmycode/tmc-server/issues/452"},"comments":{"href":"https://api.github.com/repos/testmycode/tmc-server/issues/452/comments"},"review_comments":{"href":"https://api.github.com/repos/testmycode/tmc-server/pulls/452/comments"},"review_comment":{"href":"https://api.github.com/repos/testmycode/tmc-server/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/testmycode/tmc-server/pulls/452/commits"},"statuses":{"href":"https://api.github.com/repos/testmycode/tmc-server/statuses/a25e81bc2b598c27fad9584359772f3f4650a688"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"nygrenh","id":1922896,"avatar_url":"https://avatars.githubusercontent.com/u/1922896?v=3","gravatar_id":"","url":"https://api.github.com/users/nygrenh","html_url":"https://github.com/nygrenh","followers_url":"https://api.github.com/users/nygrenh/followers","following_url":"https://api.github.com/users/nygrenh/following{/other_user}","gists_url":"https://api.github.com/users/nygrenh/gists{/gist_id}","starred_url":"https://api.github.com/users/nygrenh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nygrenh/subscriptions","organizations_url":"https://api.github.com/users/nygrenh/orgs","repos_url":"https://api.github.com/users/nygrenh/repos","events_url":"https://api.github.com/users/nygrenh/events{/privacy}","received_events_url":"https://api.github.com/users/nygrenh/received_events","type":"User","site_admin":false},"comments":0,"review_comments":11,"commits":19,"additions":1215,"deletions":75,"changed_files":12}}
{"actor":{"display_login":"nygrenh"}}