{"action":"created","comment":{"url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/comments/103904618","pull_request_review_id":24709460,"id":103904618,"diff_hunk":"@@ -30,19 +31,35 @@ class TabsComponent extends Component {\n         );\n     }\n \n-    drawComponent(tab,index){\n-        return(\n-            <div id={tab.divId} key={index} className={'tab-pane ' + (tab.active ? 'active' : '')}>\n-                <tab.component/>\n-            </div>\n-        );\n+    fetchData(url) {\n+        const apiHelper = new ApiHelper(null);\n+        const getData = new Promise(function(resolve, reject) {\n+            apiHelper.get(url).then(response => {\n+                console.log(response);\n+                response.json().then(data => {\n+                    resolve(data);\n+                });\n+            });\n+        });\n+        return getData;\n+        // ApiHelper.get(url);","path":"app/js/components/tabs/tabsComponent.jsx","position":29,"original_position":29,"commit_id":"b3bac016c8dee822584b9824f0db9976577fdf5d","original_commit_id":"b3bac016c8dee822584b9824f0db9976577fdf5d","user":{"login":"andela-cnwankwo","id":20873892,"avatar_url":"https://avatars1.githubusercontent.com/u/20873892?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-cnwankwo","html_url":"https://github.com/andela-cnwankwo","followers_url":"https://api.github.com/users/andela-cnwankwo/followers","following_url":"https://api.github.com/users/andela-cnwankwo/following{/other_user}","gists_url":"https://api.github.com/users/andela-cnwankwo/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-cnwankwo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-cnwankwo/subscriptions","organizations_url":"https://api.github.com/users/andela-cnwankwo/orgs","repos_url":"https://api.github.com/users/andela-cnwankwo/repos","events_url":"https://api.github.com/users/andela-cnwankwo/events{/privacy}","received_events_url":"https://api.github.com/users/andela-cnwankwo/received_events","type":"User","site_admin":false},"body":"You can remove the commented code.","created_at":"2017-03-02T11:36:49Z","updated_at":"2017-03-02T11:36:49Z","html_url":"https://github.com/openmrs/openmrs-owa-cohortbuilder/pull/20#discussion_r103904618","pull_request_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/20","_links":{"self":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/comments/103904618"},"html":{"href":"https://github.com/openmrs/openmrs-owa-cohortbuilder/pull/20#discussion_r103904618"},"pull_request":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/20"}}},"pull_request":{"url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/20","id":108739338,"html_url":"https://github.com/openmrs/openmrs-owa-cohortbuilder/pull/20","diff_url":"https://github.com/openmrs/openmrs-owa-cohortbuilder/pull/20.diff","patch_url":"https://github.com/openmrs/openmrs-owa-cohortbuilder/pull/20.patch","issue_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/issues/20","number":20,"state":"open","locked":false,"title":"Add fetch to retrieve data from backend","user":{"login":"andela-foladeji","id":17332992,"avatar_url":"https://avatars3.githubusercontent.com/u/17332992?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-foladeji","html_url":"https://github.com/andela-foladeji","followers_url":"https://api.github.com/users/andela-foladeji/followers","following_url":"https://api.github.com/users/andela-foladeji/following{/other_user}","gists_url":"https://api.github.com/users/andela-foladeji/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-foladeji/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-foladeji/subscriptions","organizations_url":"https://api.github.com/users/andela-foladeji/orgs","repos_url":"https://api.github.com/users/andela-foladeji/repos","events_url":"https://api.github.com/users/andela-foladeji/events{/privacy}","received_events_url":"https://api.github.com/users/andela-foladeji/received_events","type":"User","site_admin":false},"body":"# JIRA TICKET NAME:\r\n\r\n## SUMMARY:\r\n\r\n\r\nBefore you submit this PR:\r\n- Ensure the pull request you are about to create, is for an existing JIRA ticket\r\n- Make sure the branch name is the same as the ticket name\r\n- Make sure the title of the PR contains the ticket's JIRA ID and link\r\n- Pull against master to get the latest changes\r\n- Make sure your tests pass\r\n- Include screenshots if necessary but do so on the JIRA page not here.\r\n- Include a meaningful summary\r\n- Add the pull request link to the issue after creation\r\n- Remember to delete these directions. they should not be in your PR.\r\n- Avoid multiple PRs for the same issue\r\n","created_at":"2017-03-02T11:28:15Z","updated_at":"2017-03-02T11:36:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2a492835cf82b62b5cba2125e85ee22b176005a4","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/20/commits","review_comments_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/20/comments","review_comment_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/comments{/number}","comments_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/issues/20/comments","statuses_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/statuses/b3bac016c8dee822584b9824f0db9976577fdf5d","head":{"label":"andela-odaniel:cb-25","ref":"cb-25","sha":"b3bac016c8dee822584b9824f0db9976577fdf5d","user":{"login":"andela-odaniel","id":1595272,"avatar_url":"https://avatars2.githubusercontent.com/u/1595272?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-odaniel","html_url":"https://github.com/andela-odaniel","followers_url":"https://api.github.com/users/andela-odaniel/followers","following_url":"https://api.github.com/users/andela-odaniel/following{/other_user}","gists_url":"https://api.github.com/users/andela-odaniel/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-odaniel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-odaniel/subscriptions","organizations_url":"https://api.github.com/users/andela-odaniel/orgs","repos_url":"https://api.github.com/users/andela-odaniel/repos","events_url":"https://api.github.com/users/andela-odaniel/events{/privacy}","received_events_url":"https://api.github.com/users/andela-odaniel/received_events","type":"User","site_admin":false},"repo":{"id":80021468,"name":"openmrs-owa-cohortbuilder","full_name":"andela-odaniel/openmrs-owa-cohortbuilder","owner":{"login":"andela-odaniel","id":1595272,"avatar_url":"https://avatars2.githubusercontent.com/u/1595272?v=3","gravatar_id":"","url":"https://api.github.com/users/andela-odaniel","html_url":"https://github.com/andela-odaniel","followers_url":"https://api.github.com/users/andela-odaniel/followers","following_url":"https://api.github.com/users/andela-odaniel/following{/other_user}","gists_url":"https://api.github.com/users/andela-odaniel/gists{/gist_id}","starred_url":"https://api.github.com/users/andela-odaniel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andela-odaniel/subscriptions","organizations_url":"https://api.github.com/users/andela-odaniel/orgs","repos_url":"https://api.github.com/users/andela-odaniel/repos","events_url":"https://api.github.com/users/andela-odaniel/events{/privacy}","received_events_url":"https://api.github.com/users/andela-odaniel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/andela-odaniel/openmrs-owa-cohortbuilder","description":null,"fork":true,"url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder","forks_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/forks","keys_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/teams","hooks_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/hooks","issue_events_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/issues/events{/number}","events_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/events","assignees_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/assignees{/user}","branches_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/branches{/branch}","tags_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/tags","blobs_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/git/refs{/sha}","trees_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/statuses/{sha}","languages_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/languages","stargazers_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/stargazers","contributors_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/contributors","subscribers_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/subscribers","subscription_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/subscription","commits_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/commits{/sha}","git_commits_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/git/commits{/sha}","comments_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/comments{/number}","issue_comment_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/issues/comments{/number}","contents_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/contents/{+path}","compare_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/merges","archive_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/downloads","issues_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/issues{/number}","pulls_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/pulls{/number}","milestones_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/milestones{/number}","notifications_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/labels{/name}","releases_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/releases{/id}","deployments_url":"https://api.github.com/repos/andela-odaniel/openmrs-owa-cohortbuilder/deployments","created_at":"2017-01-25T14:22:48Z","updated_at":"2017-01-25T14:22:50Z","pushed_at":"2017-03-02T11:27:31Z","git_url":"git://github.com/andela-odaniel/openmrs-owa-cohortbuilder.git","ssh_url":"git@github.com:andela-odaniel/openmrs-owa-cohortbuilder.git","clone_url":"https://github.com/andela-odaniel/openmrs-owa-cohortbuilder.git","svn_url":"https://github.com/andela-odaniel/openmrs-owa-cohortbuilder","homepage":null,"size":148,"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":"openmrs:master","ref":"master","sha":"668441e2eb9f542962596051917512d62d5f5e2a","user":{"login":"openmrs","id":860776,"avatar_url":"https://avatars0.githubusercontent.com/u/860776?v=3","gravatar_id":"","url":"https://api.github.com/users/openmrs","html_url":"https://github.com/openmrs","followers_url":"https://api.github.com/users/openmrs/followers","following_url":"https://api.github.com/users/openmrs/following{/other_user}","gists_url":"https://api.github.com/users/openmrs/gists{/gist_id}","starred_url":"https://api.github.com/users/openmrs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openmrs/subscriptions","organizations_url":"https://api.github.com/users/openmrs/orgs","repos_url":"https://api.github.com/users/openmrs/repos","events_url":"https://api.github.com/users/openmrs/events{/privacy}","received_events_url":"https://api.github.com/users/openmrs/received_events","type":"Organization","site_admin":false},"repo":{"id":80020366,"name":"openmrs-owa-cohortbuilder","full_name":"openmrs/openmrs-owa-cohortbuilder","owner":{"login":"openmrs","id":860776,"avatar_url":"https://avatars0.githubusercontent.com/u/860776?v=3","gravatar_id":"","url":"https://api.github.com/users/openmrs","html_url":"https://github.com/openmrs","followers_url":"https://api.github.com/users/openmrs/followers","following_url":"https://api.github.com/users/openmrs/following{/other_user}","gists_url":"https://api.github.com/users/openmrs/gists{/gist_id}","starred_url":"https://api.github.com/users/openmrs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openmrs/subscriptions","organizations_url":"https://api.github.com/users/openmrs/orgs","repos_url":"https://api.github.com/users/openmrs/repos","events_url":"https://api.github.com/users/openmrs/events{/privacy}","received_events_url":"https://api.github.com/users/openmrs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/openmrs/openmrs-owa-cohortbuilder","description":null,"fork":false,"url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder","forks_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/forks","keys_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/teams","hooks_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/hooks","issue_events_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/issues/events{/number}","events_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/events","assignees_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/assignees{/user}","branches_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/branches{/branch}","tags_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/tags","blobs_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/git/refs{/sha}","trees_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/statuses/{sha}","languages_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/languages","stargazers_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/stargazers","contributors_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/contributors","subscribers_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/subscribers","subscription_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/subscription","commits_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/commits{/sha}","git_commits_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/git/commits{/sha}","comments_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/comments{/number}","issue_comment_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/issues/comments{/number}","contents_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/contents/{+path}","compare_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/merges","archive_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/downloads","issues_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/issues{/number}","pulls_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls{/number}","milestones_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/milestones{/number}","notifications_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/labels{/name}","releases_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/releases{/id}","deployments_url":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/deployments","created_at":"2017-01-25T14:11:11Z","updated_at":"2017-02-22T14:52:43Z","pushed_at":"2017-03-02T11:28:16Z","git_url":"git://github.com/openmrs/openmrs-owa-cohortbuilder.git","ssh_url":"git@github.com:openmrs/openmrs-owa-cohortbuilder.git","clone_url":"https://github.com/openmrs/openmrs-owa-cohortbuilder.git","svn_url":"https://github.com/openmrs/openmrs-owa-cohortbuilder","homepage":null,"size":127,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":1,"forks":2,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/20"},"html":{"href":"https://github.com/openmrs/openmrs-owa-cohortbuilder/pull/20"},"issue":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/issues/20"},"comments":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/issues/20/comments"},"review_comments":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/20/comments"},"review_comment":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/pulls/20/commits"},"statuses":{"href":"https://api.github.com/repos/openmrs/openmrs-owa-cohortbuilder/statuses/b3bac016c8dee822584b9824f0db9976577fdf5d"}}}}
{"actor":{"display_login":"andela-cnwankwo"}}