{"action":"created","comment":{"url":"https://api.github.com/repos/oncokb/oncokb/pulls/comments/238371803","pull_request_review_id":180897159,"id":238371803,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzODM3MTgwMw==","diff_hunk":"@@ -3009,6 +2987,119 @@ angular.module('oncokbApp')\n             getOncoTreeMainTypes();\n         }]\n     )\n+\n+    .controller('ModifyTherapyCtrl', function ($scope, $modalInstance, data, _, OncoKB, $rootScope, mainUtils, FirebaseModel, $timeout, DatabaseConnector){\n+        $scope.therapy = [[]];\n+        $scope.addTherapyError = false;\n+        $scope.loadDrugs = function($query){\n+            return DatabaseConnector.getAllDrugs()\n+                .then(function(result){\n+                    $scope.addTherapyError = false;\n+                    var drugs = result;\n+                    return drugs.filter(function (drug) {\n+                        return (drug.drugName.toLowerCase().indexOf($query.toLowerCase()) != -1) || (drug.synonyms.join(',').toLowerCase().indexOf($query.toLowerCase()) != -1);\n+                    })\n+                })\n+                .catch(\n+                    function (error) {\n+                        $scope.therapyErrorMessage = \"Sorry, the list of drugs is not available now.\";\n+                        $scope.addTherapyError = true;\n+                    }\n+                )\n+        }\n+        $scope.addDruginTherapy = function(tag,index){\n+            $scope.therapy[index].push(tag.drugName);\n+            addTherapy(index);\n+        }\n+\n+        $scope.removeDruginTherapy = function(tag,index){\n+            var id = $scope.therapy[index].indexOf(tag.drugName);\n+            if (id > -1) {\n+                $scope.therapy[index].splice(id, 1);\n+            }\n+            addTherapy(index);\n+        }\n+        function addTherapy(index) {\n+            if ($scope.therapy.length === index + 1 ){\n+                $scope.therapy.push([]);\n+            }\n+            valiElement(index);\n+        }\n+        function valiElement(index) {\n+            $scope.addTherapyError = false;\n+            var therapyVali = [];\n+            _.each($scope.therapy, function(element) {\n+                element = element.sort();\n+                element = element.join(' ').trim();\n+                if (element!=='')\n+                    therapyVali.push(element);\n+            });\n+            for(var i=0;i<therapyVali.length;i++){","path":"web/yo/app/scripts/controllers/gene.js","position":102,"original_position":102,"commit_id":"92711fb12d865fc25574da33e8ff6194590afd7b","original_commit_id":"92711fb12d865fc25574da33e8ff6194590afd7b","user":{"login":"Yizhuzhu","id":25191590,"node_id":"MDQ6VXNlcjI1MTkxNTkw","avatar_url":"https://avatars1.githubusercontent.com/u/25191590?v=4","gravatar_id":"","url":"https://api.github.com/users/Yizhuzhu","html_url":"https://github.com/Yizhuzhu","followers_url":"https://api.github.com/users/Yizhuzhu/followers","following_url":"https://api.github.com/users/Yizhuzhu/following{/other_user}","gists_url":"https://api.github.com/users/Yizhuzhu/gists{/gist_id}","starred_url":"https://api.github.com/users/Yizhuzhu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yizhuzhu/subscriptions","organizations_url":"https://api.github.com/users/Yizhuzhu/orgs","repos_url":"https://api.github.com/users/Yizhuzhu/repos","events_url":"https://api.github.com/users/Yizhuzhu/events{/privacy}","received_events_url":"https://api.github.com/users/Yizhuzhu/received_events","type":"User","site_admin":false},"body":"It's not for checking if 2 arrays are exactly same. It's for checking if they contain same elements. ","created_at":"2018-12-03T17:51:50Z","updated_at":"2018-12-03T17:51:50Z","html_url":"https://github.com/oncokb/oncokb/pull/1420#discussion_r238371803","pull_request_url":"https://api.github.com/repos/oncokb/oncokb/pulls/1420","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/oncokb/oncokb/pulls/comments/238371803"},"html":{"href":"https://github.com/oncokb/oncokb/pull/1420#discussion_r238371803"},"pull_request":{"href":"https://api.github.com/repos/oncokb/oncokb/pulls/1420"}},"in_reply_to_id":238351486},"pull_request":{"url":"https://api.github.com/repos/oncokb/oncokb/pulls/1420","id":232725479,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMyNzI1NDc5","html_url":"https://github.com/oncokb/oncokb/pull/1420","diff_url":"https://github.com/oncokb/oncokb/pull/1420.diff","patch_url":"https://github.com/oncokb/oncokb/pull/1420.patch","issue_url":"https://api.github.com/repos/oncokb/oncokb/issues/1420","number":1420,"state":"open","locked":false,"title":"Add Therapy","user":{"login":"Yizhuzhu","id":25191590,"node_id":"MDQ6VXNlcjI1MTkxNTkw","avatar_url":"https://avatars1.githubusercontent.com/u/25191590?v=4","gravatar_id":"","url":"https://api.github.com/users/Yizhuzhu","html_url":"https://github.com/Yizhuzhu","followers_url":"https://api.github.com/users/Yizhuzhu/followers","following_url":"https://api.github.com/users/Yizhuzhu/following{/other_user}","gists_url":"https://api.github.com/users/Yizhuzhu/gists{/gist_id}","starred_url":"https://api.github.com/users/Yizhuzhu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yizhuzhu/subscriptions","organizations_url":"https://api.github.com/users/Yizhuzhu/orgs","repos_url":"https://api.github.com/users/Yizhuzhu/repos","events_url":"https://api.github.com/users/Yizhuzhu/events{/privacy}","received_events_url":"https://api.github.com/users/Yizhuzhu/received_events","type":"User","site_admin":false},"body":"ModifyTumorTypes.html uses inline CSS. To keep consistent, I didn't change main.scss and use inline css too. Thank you for reviewing.","created_at":"2018-11-21T16:26:02Z","updated_at":"2018-12-03T17:51:50Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1cddb03526c48ed27b9e3178a826b2db023a6552","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/oncokb/oncokb/pulls/1420/commits","review_comments_url":"https://api.github.com/repos/oncokb/oncokb/pulls/1420/comments","review_comment_url":"https://api.github.com/repos/oncokb/oncokb/pulls/comments{/number}","comments_url":"https://api.github.com/repos/oncokb/oncokb/issues/1420/comments","statuses_url":"https://api.github.com/repos/oncokb/oncokb/statuses/92711fb12d865fc25574da33e8ff6194590afd7b","head":{"label":"Yizhuzhu:branch1","ref":"branch1","sha":"92711fb12d865fc25574da33e8ff6194590afd7b","user":{"login":"Yizhuzhu","id":25191590,"node_id":"MDQ6VXNlcjI1MTkxNTkw","avatar_url":"https://avatars1.githubusercontent.com/u/25191590?v=4","gravatar_id":"","url":"https://api.github.com/users/Yizhuzhu","html_url":"https://github.com/Yizhuzhu","followers_url":"https://api.github.com/users/Yizhuzhu/followers","following_url":"https://api.github.com/users/Yizhuzhu/following{/other_user}","gists_url":"https://api.github.com/users/Yizhuzhu/gists{/gist_id}","starred_url":"https://api.github.com/users/Yizhuzhu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yizhuzhu/subscriptions","organizations_url":"https://api.github.com/users/Yizhuzhu/orgs","repos_url":"https://api.github.com/users/Yizhuzhu/repos","events_url":"https://api.github.com/users/Yizhuzhu/events{/privacy}","received_events_url":"https://api.github.com/users/Yizhuzhu/received_events","type":"User","site_admin":false},"repo":{"id":153792964,"node_id":"MDEwOlJlcG9zaXRvcnkxNTM3OTI5NjQ=","name":"oncokb","full_name":"Yizhuzhu/oncokb","private":false,"owner":{"login":"Yizhuzhu","id":25191590,"node_id":"MDQ6VXNlcjI1MTkxNTkw","avatar_url":"https://avatars1.githubusercontent.com/u/25191590?v=4","gravatar_id":"","url":"https://api.github.com/users/Yizhuzhu","html_url":"https://github.com/Yizhuzhu","followers_url":"https://api.github.com/users/Yizhuzhu/followers","following_url":"https://api.github.com/users/Yizhuzhu/following{/other_user}","gists_url":"https://api.github.com/users/Yizhuzhu/gists{/gist_id}","starred_url":"https://api.github.com/users/Yizhuzhu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yizhuzhu/subscriptions","organizations_url":"https://api.github.com/users/Yizhuzhu/orgs","repos_url":"https://api.github.com/users/Yizhuzhu/repos","events_url":"https://api.github.com/users/Yizhuzhu/events{/privacy}","received_events_url":"https://api.github.com/users/Yizhuzhu/received_events","type":"User","site_admin":false},"html_url":"https://github.com/Yizhuzhu/oncokb","description":null,"fork":true,"url":"https://api.github.com/repos/Yizhuzhu/oncokb","forks_url":"https://api.github.com/repos/Yizhuzhu/oncokb/forks","keys_url":"https://api.github.com/repos/Yizhuzhu/oncokb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Yizhuzhu/oncokb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Yizhuzhu/oncokb/teams","hooks_url":"https://api.github.com/repos/Yizhuzhu/oncokb/hooks","issue_events_url":"https://api.github.com/repos/Yizhuzhu/oncokb/issues/events{/number}","events_url":"https://api.github.com/repos/Yizhuzhu/oncokb/events","assignees_url":"https://api.github.com/repos/Yizhuzhu/oncokb/assignees{/user}","branches_url":"https://api.github.com/repos/Yizhuzhu/oncokb/branches{/branch}","tags_url":"https://api.github.com/repos/Yizhuzhu/oncokb/tags","blobs_url":"https://api.github.com/repos/Yizhuzhu/oncokb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Yizhuzhu/oncokb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Yizhuzhu/oncokb/git/refs{/sha}","trees_url":"https://api.github.com/repos/Yizhuzhu/oncokb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Yizhuzhu/oncokb/statuses/{sha}","languages_url":"https://api.github.com/repos/Yizhuzhu/oncokb/languages","stargazers_url":"https://api.github.com/repos/Yizhuzhu/oncokb/stargazers","contributors_url":"https://api.github.com/repos/Yizhuzhu/oncokb/contributors","subscribers_url":"https://api.github.com/repos/Yizhuzhu/oncokb/subscribers","subscription_url":"https://api.github.com/repos/Yizhuzhu/oncokb/subscription","commits_url":"https://api.github.com/repos/Yizhuzhu/oncokb/commits{/sha}","git_commits_url":"https://api.github.com/repos/Yizhuzhu/oncokb/git/commits{/sha}","comments_url":"https://api.github.com/repos/Yizhuzhu/oncokb/comments{/number}","issue_comment_url":"https://api.github.com/repos/Yizhuzhu/oncokb/issues/comments{/number}","contents_url":"https://api.github.com/repos/Yizhuzhu/oncokb/contents/{+path}","compare_url":"https://api.github.com/repos/Yizhuzhu/oncokb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Yizhuzhu/oncokb/merges","archive_url":"https://api.github.com/repos/Yizhuzhu/oncokb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Yizhuzhu/oncokb/downloads","issues_url":"https://api.github.com/repos/Yizhuzhu/oncokb/issues{/number}","pulls_url":"https://api.github.com/repos/Yizhuzhu/oncokb/pulls{/number}","milestones_url":"https://api.github.com/repos/Yizhuzhu/oncokb/milestones{/number}","notifications_url":"https://api.github.com/repos/Yizhuzhu/oncokb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Yizhuzhu/oncokb/labels{/name}","releases_url":"https://api.github.com/repos/Yizhuzhu/oncokb/releases{/id}","deployments_url":"https://api.github.com/repos/Yizhuzhu/oncokb/deployments","created_at":"2018-10-19T14:08:41Z","updated_at":"2018-10-26T15:15:53Z","pushed_at":"2018-11-27T15:47:08Z","git_url":"git://github.com/Yizhuzhu/oncokb.git","ssh_url":"git@github.com:Yizhuzhu/oncokb.git","clone_url":"https://github.com/Yizhuzhu/oncokb.git","svn_url":"https://github.com/Yizhuzhu/oncokb","homepage":null,"size":35251,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0","node_id":"MDc6TGljZW5zZTE="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"oncokb:release-0.4.0","ref":"release-0.4.0","sha":"c7bf6a36b4097b4767a04f32d00f824d31a62997","user":{"login":"oncokb","id":22530657,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyNTMwNjU3","avatar_url":"https://avatars2.githubusercontent.com/u/22530657?v=4","gravatar_id":"","url":"https://api.github.com/users/oncokb","html_url":"https://github.com/oncokb","followers_url":"https://api.github.com/users/oncokb/followers","following_url":"https://api.github.com/users/oncokb/following{/other_user}","gists_url":"https://api.github.com/users/oncokb/gists{/gist_id}","starred_url":"https://api.github.com/users/oncokb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oncokb/subscriptions","organizations_url":"https://api.github.com/users/oncokb/orgs","repos_url":"https://api.github.com/users/oncokb/repos","events_url":"https://api.github.com/users/oncokb/events{/privacy}","received_events_url":"https://api.github.com/users/oncokb/received_events","type":"Organization","site_admin":false},"repo":{"id":36954340,"node_id":"MDEwOlJlcG9zaXRvcnkzNjk1NDM0MA==","name":"oncokb","full_name":"oncokb/oncokb","private":false,"owner":{"login":"oncokb","id":22530657,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyNTMwNjU3","avatar_url":"https://avatars2.githubusercontent.com/u/22530657?v=4","gravatar_id":"","url":"https://api.github.com/users/oncokb","html_url":"https://github.com/oncokb","followers_url":"https://api.github.com/users/oncokb/followers","following_url":"https://api.github.com/users/oncokb/following{/other_user}","gists_url":"https://api.github.com/users/oncokb/gists{/gist_id}","starred_url":"https://api.github.com/users/oncokb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oncokb/subscriptions","organizations_url":"https://api.github.com/users/oncokb/orgs","repos_url":"https://api.github.com/users/oncokb/repos","events_url":"https://api.github.com/users/oncokb/events{/privacy}","received_events_url":"https://api.github.com/users/oncokb/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/oncokb/oncokb","description":null,"fork":false,"url":"https://api.github.com/repos/oncokb/oncokb","forks_url":"https://api.github.com/repos/oncokb/oncokb/forks","keys_url":"https://api.github.com/repos/oncokb/oncokb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/oncokb/oncokb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/oncokb/oncokb/teams","hooks_url":"https://api.github.com/repos/oncokb/oncokb/hooks","issue_events_url":"https://api.github.com/repos/oncokb/oncokb/issues/events{/number}","events_url":"https://api.github.com/repos/oncokb/oncokb/events","assignees_url":"https://api.github.com/repos/oncokb/oncokb/assignees{/user}","branches_url":"https://api.github.com/repos/oncokb/oncokb/branches{/branch}","tags_url":"https://api.github.com/repos/oncokb/oncokb/tags","blobs_url":"https://api.github.com/repos/oncokb/oncokb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/oncokb/oncokb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/oncokb/oncokb/git/refs{/sha}","trees_url":"https://api.github.com/repos/oncokb/oncokb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/oncokb/oncokb/statuses/{sha}","languages_url":"https://api.github.com/repos/oncokb/oncokb/languages","stargazers_url":"https://api.github.com/repos/oncokb/oncokb/stargazers","contributors_url":"https://api.github.com/repos/oncokb/oncokb/contributors","subscribers_url":"https://api.github.com/repos/oncokb/oncokb/subscribers","subscription_url":"https://api.github.com/repos/oncokb/oncokb/subscription","commits_url":"https://api.github.com/repos/oncokb/oncokb/commits{/sha}","git_commits_url":"https://api.github.com/repos/oncokb/oncokb/git/commits{/sha}","comments_url":"https://api.github.com/repos/oncokb/oncokb/comments{/number}","issue_comment_url":"https://api.github.com/repos/oncokb/oncokb/issues/comments{/number}","contents_url":"https://api.github.com/repos/oncokb/oncokb/contents/{+path}","compare_url":"https://api.github.com/repos/oncokb/oncokb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/oncokb/oncokb/merges","archive_url":"https://api.github.com/repos/oncokb/oncokb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/oncokb/oncokb/downloads","issues_url":"https://api.github.com/repos/oncokb/oncokb/issues{/number}","pulls_url":"https://api.github.com/repos/oncokb/oncokb/pulls{/number}","milestones_url":"https://api.github.com/repos/oncokb/oncokb/milestones{/number}","notifications_url":"https://api.github.com/repos/oncokb/oncokb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/oncokb/oncokb/labels{/name}","releases_url":"https://api.github.com/repos/oncokb/oncokb/releases{/id}","deployments_url":"https://api.github.com/repos/oncokb/oncokb/deployments","created_at":"2015-06-05T20:39:31Z","updated_at":"2018-11-14T21:23:10Z","pushed_at":"2018-11-27T15:47:10Z","git_url":"git://github.com/oncokb/oncokb.git","ssh_url":"git@github.com:oncokb/oncokb.git","clone_url":"https://github.com/oncokb/oncokb.git","svn_url":"https://github.com/oncokb/oncokb","homepage":null,"size":35285,"stargazers_count":13,"watchers_count":13,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":15,"mirror_url":null,"archived":false,"open_issues_count":78,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0","node_id":"MDc6TGljZW5zZTE="},"forks":15,"open_issues":78,"watchers":13,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/oncokb/oncokb/pulls/1420"},"html":{"href":"https://github.com/oncokb/oncokb/pull/1420"},"issue":{"href":"https://api.github.com/repos/oncokb/oncokb/issues/1420"},"comments":{"href":"https://api.github.com/repos/oncokb/oncokb/issues/1420/comments"},"review_comments":{"href":"https://api.github.com/repos/oncokb/oncokb/pulls/1420/comments"},"review_comment":{"href":"https://api.github.com/repos/oncokb/oncokb/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/oncokb/oncokb/pulls/1420/commits"},"statuses":{"href":"https://api.github.com/repos/oncokb/oncokb/statuses/92711fb12d865fc25574da33e8ff6194590afd7b"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"Yizhuzhu"}}