{"action":"created","comment":{"url":"https://api.github.com/repos/yutoJ/kanban/pulls/comments/185170783","pull_request_review_id":116506260,"id":185170783,"diff_hunk":"@@ -1,11 +1,37 @@\n class ProjectsController < ApplicationController\n-  before_action :authenticate_user!, only: [:index]\n+  before_action :authenticate_user!, only: %i[index myproject create new]\n   def index\n-    paginates_per = request.xhr? ? 9 : 8\n-    @projects = Project.page(params[:page]).per(paginates_per)\n-    respond_to do |format|\n-      format.html\n-      format.js\n+    @projects = paginate_index(Project.all)\n+  end\n+\n+  def myproject\n+    @projects = paginate_index(current_user.projects)\n+  end\n+\n+  def new\n+    @project = current_user.projects.build\n+  end\n+\n+  def create\n+    @project = current_user.projects.build(project_params)\n+    if @project.save\n+      redirect_to :myproject, notice: t('notice.create_new_project')\n+    else\n+\n+      render :new\n     end\n   end\n+\n+  private\n+\n+  def paginate_index(projects)\n+    project_count_on_first_page = 8","path":"app/controllers/projects_controller.rb","position":null,"original_position":34,"commit_id":"07515c1cf77dd0a1681573dcdcb3841714ba8f17","original_commit_id":"b8cba81c78172cc91f16c906c97ca4f03273c8a2","user":{"login":"yutoJ","id":19489801,"avatar_url":"https://avatars0.githubusercontent.com/u/19489801?v=4","gravatar_id":"","url":"https://api.github.com/users/yutoJ","html_url":"https://github.com/yutoJ","followers_url":"https://api.github.com/users/yutoJ/followers","following_url":"https://api.github.com/users/yutoJ/following{/other_user}","gists_url":"https://api.github.com/users/yutoJ/gists{/gist_id}","starred_url":"https://api.github.com/users/yutoJ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yutoJ/subscriptions","organizations_url":"https://api.github.com/users/yutoJ/orgs","repos_url":"https://api.github.com/users/yutoJ/repos","events_url":"https://api.github.com/users/yutoJ/events{/privacy}","received_events_url":"https://api.github.com/users/yutoJ/received_events","type":"User","site_admin":false},"body":"07515c1 で対応してみました！","created_at":"2018-05-01T05:55:19Z","updated_at":"2018-05-01T05:55:19Z","html_url":"https://github.com/yutoJ/kanban/pull/32#discussion_r185170783","pull_request_url":"https://api.github.com/repos/yutoJ/kanban/pulls/32","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/yutoJ/kanban/pulls/comments/185170783"},"html":{"href":"https://github.com/yutoJ/kanban/pull/32#discussion_r185170783"},"pull_request":{"href":"https://api.github.com/repos/yutoJ/kanban/pulls/32"}},"in_reply_to_id":184665545},"pull_request":{"url":"https://api.github.com/repos/yutoJ/kanban/pulls/32","id":183093562,"html_url":"https://github.com/yutoJ/kanban/pull/32","diff_url":"https://github.com/yutoJ/kanban/pull/32.diff","patch_url":"https://github.com/yutoJ/kanban/pull/32.patch","issue_url":"https://api.github.com/repos/yutoJ/kanban/issues/32","number":32,"state":"open","locked":false,"title":"Review D02 1","user":{"login":"yutoJ","id":19489801,"avatar_url":"https://avatars0.githubusercontent.com/u/19489801?v=4","gravatar_id":"","url":"https://api.github.com/users/yutoJ","html_url":"https://github.com/yutoJ","followers_url":"https://api.github.com/users/yutoJ/followers","following_url":"https://api.github.com/users/yutoJ/following{/other_user}","gists_url":"https://api.github.com/users/yutoJ/gists{/gist_id}","starred_url":"https://api.github.com/users/yutoJ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yutoJ/subscriptions","organizations_url":"https://api.github.com/users/yutoJ/orgs","repos_url":"https://api.github.com/users/yutoJ/repos","events_url":"https://api.github.com/users/yutoJ/events{/privacy}","received_events_url":"https://api.github.com/users/yutoJ/received_events","type":"User","site_admin":false},"body":"こちらが今回の開発対象です。\r\n45f43a9\r\n\r\nこちらは今回の要件ではないですが、好みで変えました。\r\n5637bce\r\n0755170\r\n\r\nそれ以外は前回分をdevelopにmergeしてないので出ています。（前回分のreview後、mergeできたら消えるはず）\r\n","created_at":"2018-04-20T15:17:50Z","updated_at":"2018-05-01T05:55:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"601660bd03c5200c1a59d2745593afafb5e68312","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/yutoJ/kanban/pulls/32/commits","review_comments_url":"https://api.github.com/repos/yutoJ/kanban/pulls/32/comments","review_comment_url":"https://api.github.com/repos/yutoJ/kanban/pulls/comments{/number}","comments_url":"https://api.github.com/repos/yutoJ/kanban/issues/32/comments","statuses_url":"https://api.github.com/repos/yutoJ/kanban/statuses/07515c1cf77dd0a1681573dcdcb3841714ba8f17","head":{"label":"yutoJ:D02-1","ref":"D02-1","sha":"07515c1cf77dd0a1681573dcdcb3841714ba8f17","user":{"login":"yutoJ","id":19489801,"avatar_url":"https://avatars0.githubusercontent.com/u/19489801?v=4","gravatar_id":"","url":"https://api.github.com/users/yutoJ","html_url":"https://github.com/yutoJ","followers_url":"https://api.github.com/users/yutoJ/followers","following_url":"https://api.github.com/users/yutoJ/following{/other_user}","gists_url":"https://api.github.com/users/yutoJ/gists{/gist_id}","starred_url":"https://api.github.com/users/yutoJ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yutoJ/subscriptions","organizations_url":"https://api.github.com/users/yutoJ/orgs","repos_url":"https://api.github.com/users/yutoJ/repos","events_url":"https://api.github.com/users/yutoJ/events{/privacy}","received_events_url":"https://api.github.com/users/yutoJ/received_events","type":"User","site_admin":false},"repo":{"id":127636055,"name":"kanban","full_name":"yutoJ/kanban","owner":{"login":"yutoJ","id":19489801,"avatar_url":"https://avatars0.githubusercontent.com/u/19489801?v=4","gravatar_id":"","url":"https://api.github.com/users/yutoJ","html_url":"https://github.com/yutoJ","followers_url":"https://api.github.com/users/yutoJ/followers","following_url":"https://api.github.com/users/yutoJ/following{/other_user}","gists_url":"https://api.github.com/users/yutoJ/gists{/gist_id}","starred_url":"https://api.github.com/users/yutoJ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yutoJ/subscriptions","organizations_url":"https://api.github.com/users/yutoJ/orgs","repos_url":"https://api.github.com/users/yutoJ/repos","events_url":"https://api.github.com/users/yutoJ/events{/privacy}","received_events_url":"https://api.github.com/users/yutoJ/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/yutoJ/kanban","description":null,"fork":false,"url":"https://api.github.com/repos/yutoJ/kanban","forks_url":"https://api.github.com/repos/yutoJ/kanban/forks","keys_url":"https://api.github.com/repos/yutoJ/kanban/keys{/key_id}","collaborators_url":"https://api.github.com/repos/yutoJ/kanban/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/yutoJ/kanban/teams","hooks_url":"https://api.github.com/repos/yutoJ/kanban/hooks","issue_events_url":"https://api.github.com/repos/yutoJ/kanban/issues/events{/number}","events_url":"https://api.github.com/repos/yutoJ/kanban/events","assignees_url":"https://api.github.com/repos/yutoJ/kanban/assignees{/user}","branches_url":"https://api.github.com/repos/yutoJ/kanban/branches{/branch}","tags_url":"https://api.github.com/repos/yutoJ/kanban/tags","blobs_url":"https://api.github.com/repos/yutoJ/kanban/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/yutoJ/kanban/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/yutoJ/kanban/git/refs{/sha}","trees_url":"https://api.github.com/repos/yutoJ/kanban/git/trees{/sha}","statuses_url":"https://api.github.com/repos/yutoJ/kanban/statuses/{sha}","languages_url":"https://api.github.com/repos/yutoJ/kanban/languages","stargazers_url":"https://api.github.com/repos/yutoJ/kanban/stargazers","contributors_url":"https://api.github.com/repos/yutoJ/kanban/contributors","subscribers_url":"https://api.github.com/repos/yutoJ/kanban/subscribers","subscription_url":"https://api.github.com/repos/yutoJ/kanban/subscription","commits_url":"https://api.github.com/repos/yutoJ/kanban/commits{/sha}","git_commits_url":"https://api.github.com/repos/yutoJ/kanban/git/commits{/sha}","comments_url":"https://api.github.com/repos/yutoJ/kanban/comments{/number}","issue_comment_url":"https://api.github.com/repos/yutoJ/kanban/issues/comments{/number}","contents_url":"https://api.github.com/repos/yutoJ/kanban/contents/{+path}","compare_url":"https://api.github.com/repos/yutoJ/kanban/compare/{base}...{head}","merges_url":"https://api.github.com/repos/yutoJ/kanban/merges","archive_url":"https://api.github.com/repos/yutoJ/kanban/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/yutoJ/kanban/downloads","issues_url":"https://api.github.com/repos/yutoJ/kanban/issues{/number}","pulls_url":"https://api.github.com/repos/yutoJ/kanban/pulls{/number}","milestones_url":"https://api.github.com/repos/yutoJ/kanban/milestones{/number}","notifications_url":"https://api.github.com/repos/yutoJ/kanban/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/yutoJ/kanban/labels{/name}","releases_url":"https://api.github.com/repos/yutoJ/kanban/releases{/id}","deployments_url":"https://api.github.com/repos/yutoJ/kanban/deployments","created_at":"2018-04-01T14:21:41Z","updated_at":"2018-04-27T17:36:56Z","pushed_at":"2018-05-01T05:53:07Z","git_url":"git://github.com/yutoJ/kanban.git","ssh_url":"git@github.com:yutoJ/kanban.git","clone_url":"https://github.com/yutoJ/kanban.git","svn_url":"https://github.com/yutoJ/kanban","homepage":null,"size":306,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":9,"license":null,"forks":0,"open_issues":9,"watchers":0,"default_branch":"develop"}},"base":{"label":"yutoJ:develop","ref":"develop","sha":"76f3f4fce1c47e71baaa384b300a666fe09bb1a2","user":{"login":"yutoJ","id":19489801,"avatar_url":"https://avatars0.githubusercontent.com/u/19489801?v=4","gravatar_id":"","url":"https://api.github.com/users/yutoJ","html_url":"https://github.com/yutoJ","followers_url":"https://api.github.com/users/yutoJ/followers","following_url":"https://api.github.com/users/yutoJ/following{/other_user}","gists_url":"https://api.github.com/users/yutoJ/gists{/gist_id}","starred_url":"https://api.github.com/users/yutoJ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yutoJ/subscriptions","organizations_url":"https://api.github.com/users/yutoJ/orgs","repos_url":"https://api.github.com/users/yutoJ/repos","events_url":"https://api.github.com/users/yutoJ/events{/privacy}","received_events_url":"https://api.github.com/users/yutoJ/received_events","type":"User","site_admin":false},"repo":{"id":127636055,"name":"kanban","full_name":"yutoJ/kanban","owner":{"login":"yutoJ","id":19489801,"avatar_url":"https://avatars0.githubusercontent.com/u/19489801?v=4","gravatar_id":"","url":"https://api.github.com/users/yutoJ","html_url":"https://github.com/yutoJ","followers_url":"https://api.github.com/users/yutoJ/followers","following_url":"https://api.github.com/users/yutoJ/following{/other_user}","gists_url":"https://api.github.com/users/yutoJ/gists{/gist_id}","starred_url":"https://api.github.com/users/yutoJ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yutoJ/subscriptions","organizations_url":"https://api.github.com/users/yutoJ/orgs","repos_url":"https://api.github.com/users/yutoJ/repos","events_url":"https://api.github.com/users/yutoJ/events{/privacy}","received_events_url":"https://api.github.com/users/yutoJ/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/yutoJ/kanban","description":null,"fork":false,"url":"https://api.github.com/repos/yutoJ/kanban","forks_url":"https://api.github.com/repos/yutoJ/kanban/forks","keys_url":"https://api.github.com/repos/yutoJ/kanban/keys{/key_id}","collaborators_url":"https://api.github.com/repos/yutoJ/kanban/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/yutoJ/kanban/teams","hooks_url":"https://api.github.com/repos/yutoJ/kanban/hooks","issue_events_url":"https://api.github.com/repos/yutoJ/kanban/issues/events{/number}","events_url":"https://api.github.com/repos/yutoJ/kanban/events","assignees_url":"https://api.github.com/repos/yutoJ/kanban/assignees{/user}","branches_url":"https://api.github.com/repos/yutoJ/kanban/branches{/branch}","tags_url":"https://api.github.com/repos/yutoJ/kanban/tags","blobs_url":"https://api.github.com/repos/yutoJ/kanban/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/yutoJ/kanban/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/yutoJ/kanban/git/refs{/sha}","trees_url":"https://api.github.com/repos/yutoJ/kanban/git/trees{/sha}","statuses_url":"https://api.github.com/repos/yutoJ/kanban/statuses/{sha}","languages_url":"https://api.github.com/repos/yutoJ/kanban/languages","stargazers_url":"https://api.github.com/repos/yutoJ/kanban/stargazers","contributors_url":"https://api.github.com/repos/yutoJ/kanban/contributors","subscribers_url":"https://api.github.com/repos/yutoJ/kanban/subscribers","subscription_url":"https://api.github.com/repos/yutoJ/kanban/subscription","commits_url":"https://api.github.com/repos/yutoJ/kanban/commits{/sha}","git_commits_url":"https://api.github.com/repos/yutoJ/kanban/git/commits{/sha}","comments_url":"https://api.github.com/repos/yutoJ/kanban/comments{/number}","issue_comment_url":"https://api.github.com/repos/yutoJ/kanban/issues/comments{/number}","contents_url":"https://api.github.com/repos/yutoJ/kanban/contents/{+path}","compare_url":"https://api.github.com/repos/yutoJ/kanban/compare/{base}...{head}","merges_url":"https://api.github.com/repos/yutoJ/kanban/merges","archive_url":"https://api.github.com/repos/yutoJ/kanban/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/yutoJ/kanban/downloads","issues_url":"https://api.github.com/repos/yutoJ/kanban/issues{/number}","pulls_url":"https://api.github.com/repos/yutoJ/kanban/pulls{/number}","milestones_url":"https://api.github.com/repos/yutoJ/kanban/milestones{/number}","notifications_url":"https://api.github.com/repos/yutoJ/kanban/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/yutoJ/kanban/labels{/name}","releases_url":"https://api.github.com/repos/yutoJ/kanban/releases{/id}","deployments_url":"https://api.github.com/repos/yutoJ/kanban/deployments","created_at":"2018-04-01T14:21:41Z","updated_at":"2018-04-27T17:36:56Z","pushed_at":"2018-05-01T05:53:07Z","git_url":"git://github.com/yutoJ/kanban.git","ssh_url":"git@github.com:yutoJ/kanban.git","clone_url":"https://github.com/yutoJ/kanban.git","svn_url":"https://github.com/yutoJ/kanban","homepage":null,"size":306,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":9,"license":null,"forks":0,"open_issues":9,"watchers":0,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/yutoJ/kanban/pulls/32"},"html":{"href":"https://github.com/yutoJ/kanban/pull/32"},"issue":{"href":"https://api.github.com/repos/yutoJ/kanban/issues/32"},"comments":{"href":"https://api.github.com/repos/yutoJ/kanban/issues/32/comments"},"review_comments":{"href":"https://api.github.com/repos/yutoJ/kanban/pulls/32/comments"},"review_comment":{"href":"https://api.github.com/repos/yutoJ/kanban/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/yutoJ/kanban/pulls/32/commits"},"statuses":{"href":"https://api.github.com/repos/yutoJ/kanban/statuses/07515c1cf77dd0a1681573dcdcb3841714ba8f17"}},"author_association":"OWNER"}}
{"actor":{"display_login":"yutoJ"}}