{"action":"created","comment":{"url":"https://api.github.com/repos/framgia/drs_2/pulls/comments/71279435","id":71279435,"diff_hunk":"@@ -3,6 +3,14 @@ class Division < ActiveRecord::Base\n \n   validates :name, length: {maximum: 50}, presence: true\n \n+  def all_managers\n+    profiles.select {|profile| profile.position_id == 1}\n+  end\n+\n+  def all_users\n+    profiles.select {|profile| profile.position_id !=1}","path":"app/models/division.rb","position":9,"original_position":9,"commit_id":"7eda1a4b56b88b0ef6d20caf6c3f8663886f687a","original_commit_id":"7eda1a4b56b88b0ef6d20caf6c3f8663886f687a","user":{"login":"hellovietnam93","id":8023606,"avatar_url":"https://avatars.githubusercontent.com/u/8023606?v=3","gravatar_id":"","url":"https://api.github.com/users/hellovietnam93","html_url":"https://github.com/hellovietnam93","followers_url":"https://api.github.com/users/hellovietnam93/followers","following_url":"https://api.github.com/users/hellovietnam93/following{/other_user}","gists_url":"https://api.github.com/users/hellovietnam93/gists{/gist_id}","starred_url":"https://api.github.com/users/hellovietnam93/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hellovietnam93/subscriptions","organizations_url":"https://api.github.com/users/hellovietnam93/orgs","repos_url":"https://api.github.com/users/hellovietnam93/repos","events_url":"https://api.github.com/users/hellovietnam93/events{/privacy}","received_events_url":"https://api.github.com/users/hellovietnam93/received_events","type":"User","site_admin":false},"body":"cách ra","created_at":"2016-07-19T06:38:42Z","updated_at":"2016-07-19T06:38:42Z","html_url":"https://github.com/framgia/drs_2/pull/37#discussion_r71279435","pull_request_url":"https://api.github.com/repos/framgia/drs_2/pulls/37","_links":{"self":{"href":"https://api.github.com/repos/framgia/drs_2/pulls/comments/71279435"},"html":{"href":"https://github.com/framgia/drs_2/pull/37#discussion_r71279435"},"pull_request":{"href":"https://api.github.com/repos/framgia/drs_2/pulls/37"}}},"pull_request":{"url":"https://api.github.com/repos/framgia/drs_2/pulls/37","id":77921705,"html_url":"https://github.com/framgia/drs_2/pull/37","diff_url":"https://github.com/framgia/drs_2/pull/37.diff","patch_url":"https://github.com/framgia/drs_2/pull/37.patch","issue_url":"https://api.github.com/repos/framgia/drs_2/issues/37","number":37,"state":"open","locked":false,"title":"Task/67772 notification","user":{"login":"ngtrduc","id":9583026,"avatar_url":"https://avatars.githubusercontent.com/u/9583026?v=3","gravatar_id":"","url":"https://api.github.com/users/ngtrduc","html_url":"https://github.com/ngtrduc","followers_url":"https://api.github.com/users/ngtrduc/followers","following_url":"https://api.github.com/users/ngtrduc/following{/other_user}","gists_url":"https://api.github.com/users/ngtrduc/gists{/gist_id}","starred_url":"https://api.github.com/users/ngtrduc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ngtrduc/subscriptions","organizations_url":"https://api.github.com/users/ngtrduc/orgs","repos_url":"https://api.github.com/users/ngtrduc/repos","events_url":"https://api.github.com/users/ngtrduc/events{/privacy}","received_events_url":"https://api.github.com/users/ngtrduc/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-07-19T05:59:50Z","updated_at":"2016-07-19T06:38:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a713877542323ef5d66f0711f2939fef10616f00","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/framgia/drs_2/pulls/37/commits","review_comments_url":"https://api.github.com/repos/framgia/drs_2/pulls/37/comments","review_comment_url":"https://api.github.com/repos/framgia/drs_2/pulls/comments{/number}","comments_url":"https://api.github.com/repos/framgia/drs_2/issues/37/comments","statuses_url":"https://api.github.com/repos/framgia/drs_2/statuses/7eda1a4b56b88b0ef6d20caf6c3f8663886f687a","head":{"label":"ngtrduc:task/67762","ref":"task/67762","sha":"7eda1a4b56b88b0ef6d20caf6c3f8663886f687a","user":{"login":"ngtrduc","id":9583026,"avatar_url":"https://avatars.githubusercontent.com/u/9583026?v=3","gravatar_id":"","url":"https://api.github.com/users/ngtrduc","html_url":"https://github.com/ngtrduc","followers_url":"https://api.github.com/users/ngtrduc/followers","following_url":"https://api.github.com/users/ngtrduc/following{/other_user}","gists_url":"https://api.github.com/users/ngtrduc/gists{/gist_id}","starred_url":"https://api.github.com/users/ngtrduc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ngtrduc/subscriptions","organizations_url":"https://api.github.com/users/ngtrduc/orgs","repos_url":"https://api.github.com/users/ngtrduc/repos","events_url":"https://api.github.com/users/ngtrduc/events{/privacy}","received_events_url":"https://api.github.com/users/ngtrduc/received_events","type":"User","site_admin":false},"repo":{"id":62534959,"name":"drs_2","full_name":"ngtrduc/drs_2","owner":{"login":"ngtrduc","id":9583026,"avatar_url":"https://avatars.githubusercontent.com/u/9583026?v=3","gravatar_id":"","url":"https://api.github.com/users/ngtrduc","html_url":"https://github.com/ngtrduc","followers_url":"https://api.github.com/users/ngtrduc/followers","following_url":"https://api.github.com/users/ngtrduc/following{/other_user}","gists_url":"https://api.github.com/users/ngtrduc/gists{/gist_id}","starred_url":"https://api.github.com/users/ngtrduc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ngtrduc/subscriptions","organizations_url":"https://api.github.com/users/ngtrduc/orgs","repos_url":"https://api.github.com/users/ngtrduc/repos","events_url":"https://api.github.com/users/ngtrduc/events{/privacy}","received_events_url":"https://api.github.com/users/ngtrduc/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ngtrduc/drs_2","description":"Daily Report System","fork":true,"url":"https://api.github.com/repos/ngtrduc/drs_2","forks_url":"https://api.github.com/repos/ngtrduc/drs_2/forks","keys_url":"https://api.github.com/repos/ngtrduc/drs_2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ngtrduc/drs_2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ngtrduc/drs_2/teams","hooks_url":"https://api.github.com/repos/ngtrduc/drs_2/hooks","issue_events_url":"https://api.github.com/repos/ngtrduc/drs_2/issues/events{/number}","events_url":"https://api.github.com/repos/ngtrduc/drs_2/events","assignees_url":"https://api.github.com/repos/ngtrduc/drs_2/assignees{/user}","branches_url":"https://api.github.com/repos/ngtrduc/drs_2/branches{/branch}","tags_url":"https://api.github.com/repos/ngtrduc/drs_2/tags","blobs_url":"https://api.github.com/repos/ngtrduc/drs_2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ngtrduc/drs_2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ngtrduc/drs_2/git/refs{/sha}","trees_url":"https://api.github.com/repos/ngtrduc/drs_2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ngtrduc/drs_2/statuses/{sha}","languages_url":"https://api.github.com/repos/ngtrduc/drs_2/languages","stargazers_url":"https://api.github.com/repos/ngtrduc/drs_2/stargazers","contributors_url":"https://api.github.com/repos/ngtrduc/drs_2/contributors","subscribers_url":"https://api.github.com/repos/ngtrduc/drs_2/subscribers","subscription_url":"https://api.github.com/repos/ngtrduc/drs_2/subscription","commits_url":"https://api.github.com/repos/ngtrduc/drs_2/commits{/sha}","git_commits_url":"https://api.github.com/repos/ngtrduc/drs_2/git/commits{/sha}","comments_url":"https://api.github.com/repos/ngtrduc/drs_2/comments{/number}","issue_comment_url":"https://api.github.com/repos/ngtrduc/drs_2/issues/comments{/number}","contents_url":"https://api.github.com/repos/ngtrduc/drs_2/contents/{+path}","compare_url":"https://api.github.com/repos/ngtrduc/drs_2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ngtrduc/drs_2/merges","archive_url":"https://api.github.com/repos/ngtrduc/drs_2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ngtrduc/drs_2/downloads","issues_url":"https://api.github.com/repos/ngtrduc/drs_2/issues{/number}","pulls_url":"https://api.github.com/repos/ngtrduc/drs_2/pulls{/number}","milestones_url":"https://api.github.com/repos/ngtrduc/drs_2/milestones{/number}","notifications_url":"https://api.github.com/repos/ngtrduc/drs_2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ngtrduc/drs_2/labels{/name}","releases_url":"https://api.github.com/repos/ngtrduc/drs_2/releases{/id}","deployments_url":"https://api.github.com/repos/ngtrduc/drs_2/deployments","created_at":"2016-07-04T05:51:46Z","updated_at":"2016-07-01T10:11:12Z","pushed_at":"2016-07-19T06:36:08Z","git_url":"git://github.com/ngtrduc/drs_2.git","ssh_url":"git@github.com:ngtrduc/drs_2.git","clone_url":"https://github.com/ngtrduc/drs_2.git","svn_url":"https://github.com/ngtrduc/drs_2","homepage":null,"size":180,"stargazers_count":0,"watchers_count":0,"language":null,"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":"framgia:develop","ref":"develop","sha":"52b0a99ddb53b65cab6a78cc3d3bdbefd8bb313c","user":{"login":"framgia","id":2322183,"avatar_url":"https://avatars.githubusercontent.com/u/2322183?v=3","gravatar_id":"","url":"https://api.github.com/users/framgia","html_url":"https://github.com/framgia","followers_url":"https://api.github.com/users/framgia/followers","following_url":"https://api.github.com/users/framgia/following{/other_user}","gists_url":"https://api.github.com/users/framgia/gists{/gist_id}","starred_url":"https://api.github.com/users/framgia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/framgia/subscriptions","organizations_url":"https://api.github.com/users/framgia/orgs","repos_url":"https://api.github.com/users/framgia/repos","events_url":"https://api.github.com/users/framgia/events{/privacy}","received_events_url":"https://api.github.com/users/framgia/received_events","type":"Organization","site_admin":false},"repo":{"id":62384398,"name":"drs_2","full_name":"framgia/drs_2","owner":{"login":"framgia","id":2322183,"avatar_url":"https://avatars.githubusercontent.com/u/2322183?v=3","gravatar_id":"","url":"https://api.github.com/users/framgia","html_url":"https://github.com/framgia","followers_url":"https://api.github.com/users/framgia/followers","following_url":"https://api.github.com/users/framgia/following{/other_user}","gists_url":"https://api.github.com/users/framgia/gists{/gist_id}","starred_url":"https://api.github.com/users/framgia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/framgia/subscriptions","organizations_url":"https://api.github.com/users/framgia/orgs","repos_url":"https://api.github.com/users/framgia/repos","events_url":"https://api.github.com/users/framgia/events{/privacy}","received_events_url":"https://api.github.com/users/framgia/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/framgia/drs_2","description":"Daily Report System","fork":false,"url":"https://api.github.com/repos/framgia/drs_2","forks_url":"https://api.github.com/repos/framgia/drs_2/forks","keys_url":"https://api.github.com/repos/framgia/drs_2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/framgia/drs_2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/framgia/drs_2/teams","hooks_url":"https://api.github.com/repos/framgia/drs_2/hooks","issue_events_url":"https://api.github.com/repos/framgia/drs_2/issues/events{/number}","events_url":"https://api.github.com/repos/framgia/drs_2/events","assignees_url":"https://api.github.com/repos/framgia/drs_2/assignees{/user}","branches_url":"https://api.github.com/repos/framgia/drs_2/branches{/branch}","tags_url":"https://api.github.com/repos/framgia/drs_2/tags","blobs_url":"https://api.github.com/repos/framgia/drs_2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/framgia/drs_2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/framgia/drs_2/git/refs{/sha}","trees_url":"https://api.github.com/repos/framgia/drs_2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/framgia/drs_2/statuses/{sha}","languages_url":"https://api.github.com/repos/framgia/drs_2/languages","stargazers_url":"https://api.github.com/repos/framgia/drs_2/stargazers","contributors_url":"https://api.github.com/repos/framgia/drs_2/contributors","subscribers_url":"https://api.github.com/repos/framgia/drs_2/subscribers","subscription_url":"https://api.github.com/repos/framgia/drs_2/subscription","commits_url":"https://api.github.com/repos/framgia/drs_2/commits{/sha}","git_commits_url":"https://api.github.com/repos/framgia/drs_2/git/commits{/sha}","comments_url":"https://api.github.com/repos/framgia/drs_2/comments{/number}","issue_comment_url":"https://api.github.com/repos/framgia/drs_2/issues/comments{/number}","contents_url":"https://api.github.com/repos/framgia/drs_2/contents/{+path}","compare_url":"https://api.github.com/repos/framgia/drs_2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/framgia/drs_2/merges","archive_url":"https://api.github.com/repos/framgia/drs_2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/framgia/drs_2/downloads","issues_url":"https://api.github.com/repos/framgia/drs_2/issues{/number}","pulls_url":"https://api.github.com/repos/framgia/drs_2/pulls{/number}","milestones_url":"https://api.github.com/repos/framgia/drs_2/milestones{/number}","notifications_url":"https://api.github.com/repos/framgia/drs_2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/framgia/drs_2/labels{/name}","releases_url":"https://api.github.com/repos/framgia/drs_2/releases{/id}","deployments_url":"https://api.github.com/repos/framgia/drs_2/deployments","created_at":"2016-07-01T10:11:12Z","updated_at":"2016-07-01T10:11:12Z","pushed_at":"2016-07-19T06:36:08Z","git_url":"git://github.com/framgia/drs_2.git","ssh_url":"git@github.com:framgia/drs_2.git","clone_url":"https://github.com/framgia/drs_2.git","svn_url":"https://github.com/framgia/drs_2","homepage":null,"size":201,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":2,"forks":2,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/framgia/drs_2/pulls/37"},"html":{"href":"https://github.com/framgia/drs_2/pull/37"},"issue":{"href":"https://api.github.com/repos/framgia/drs_2/issues/37"},"comments":{"href":"https://api.github.com/repos/framgia/drs_2/issues/37/comments"},"review_comments":{"href":"https://api.github.com/repos/framgia/drs_2/pulls/37/comments"},"review_comment":{"href":"https://api.github.com/repos/framgia/drs_2/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/framgia/drs_2/pulls/37/commits"},"statuses":{"href":"https://api.github.com/repos/framgia/drs_2/statuses/7eda1a4b56b88b0ef6d20caf6c3f8663886f687a"}}}}
{"actor":{"display_login":"hellovietnam93"}}