{"action":"created","comment":{"url":"https://api.github.com/repos/framgia/fels_131/pulls/comments/62146191","id":62146191,"diff_hunk":"@@ -0,0 +1,96 @@\n+<?php\n+\n+use Illuminate\\Database\\Migrations\\Migration;\n+use Illuminate\\Database\\Schema\\Blueprint;\n+use Illuminate\\Database\\Eloquent\\Model;\n+\n+class CreateForeignKeys extends Migration {\n+\n+\tpublic function up()\n+\t{\n+\t\tSchema::table('words', function(Blueprint $table) {\n+\t\t\t$table->foreign('category_id')->references('id')->on('categories')\n+\t\t\t\t\t\t->onDelete('cascade')\n+\t\t\t\t\t\t->onUpdate('cascade');\n+\t\t});\n+\t\tSchema::table('lessons', function(Blueprint $table) {","path":"database/migrations/2016_05_05_013851_create_foreign_keys.php","position":16,"original_position":16,"commit_id":"5c08b845be94397b86739f6667d57f19a96ad41b","original_commit_id":"5c08b845be94397b86739f6667d57f19a96ad41b","user":{"login":"euclid1990","id":5584709,"avatar_url":"https://avatars.githubusercontent.com/u/5584709?v=3","gravatar_id":"","url":"https://api.github.com/users/euclid1990","html_url":"https://github.com/euclid1990","followers_url":"https://api.github.com/users/euclid1990/followers","following_url":"https://api.github.com/users/euclid1990/following{/other_user}","gists_url":"https://api.github.com/users/euclid1990/gists{/gist_id}","starred_url":"https://api.github.com/users/euclid1990/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/euclid1990/subscriptions","organizations_url":"https://api.github.com/users/euclid1990/orgs","repos_url":"https://api.github.com/users/euclid1990/repos","events_url":"https://api.github.com/users/euclid1990/events{/privacy}","received_events_url":"https://api.github.com/users/euclid1990/received_events","type":"User","site_admin":false},"body":"Bỏ hết các cascade này đi vì ko tốt cho performance","created_at":"2016-05-05T03:49:31Z","updated_at":"2016-05-05T03:49:31Z","html_url":"https://github.com/framgia/fels_131/pull/2#discussion_r62146191","pull_request_url":"https://api.github.com/repos/framgia/fels_131/pulls/2","_links":{"self":{"href":"https://api.github.com/repos/framgia/fels_131/pulls/comments/62146191"},"html":{"href":"https://github.com/framgia/fels_131/pull/2#discussion_r62146191"},"pull_request":{"href":"https://api.github.com/repos/framgia/fels_131/pulls/2"}}},"pull_request":{"url":"https://api.github.com/repos/framgia/fels_131/pulls/2","id":68963090,"html_url":"https://github.com/framgia/fels_131/pull/2","diff_url":"https://github.com/framgia/fels_131/pull/2.diff","patch_url":"https://github.com/framgia/fels_131/pull/2.patch","issue_url":"https://api.github.com/repos/framgia/fels_131/issues/2","number":2,"state":"open","locked":false,"title":"create migration, database, tables","user":{"login":"luongs3","id":12150725,"avatar_url":"https://avatars.githubusercontent.com/u/12150725?v=3","gravatar_id":"","url":"https://api.github.com/users/luongs3","html_url":"https://github.com/luongs3","followers_url":"https://api.github.com/users/luongs3/followers","following_url":"https://api.github.com/users/luongs3/following{/other_user}","gists_url":"https://api.github.com/users/luongs3/gists{/gist_id}","starred_url":"https://api.github.com/users/luongs3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luongs3/subscriptions","organizations_url":"https://api.github.com/users/luongs3/orgs","repos_url":"https://api.github.com/users/luongs3/repos","events_url":"https://api.github.com/users/luongs3/events{/privacy}","received_events_url":"https://api.github.com/users/luongs3/received_events","type":"User","site_admin":false},"body":"create migrations","created_at":"2016-05-05T03:41:49Z","updated_at":"2016-05-05T03:49:31Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dd46b7aef9281ff84743f027a1a0cae3d7fe3444","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/framgia/fels_131/pulls/2/commits","review_comments_url":"https://api.github.com/repos/framgia/fels_131/pulls/2/comments","review_comment_url":"https://api.github.com/repos/framgia/fels_131/pulls/comments{/number}","comments_url":"https://api.github.com/repos/framgia/fels_131/issues/2/comments","statuses_url":"https://api.github.com/repos/framgia/fels_131/statuses/5c08b845be94397b86739f6667d57f19a96ad41b","head":{"label":"luongs3:develop","ref":"develop","sha":"5c08b845be94397b86739f6667d57f19a96ad41b","user":{"login":"luongs3","id":12150725,"avatar_url":"https://avatars.githubusercontent.com/u/12150725?v=3","gravatar_id":"","url":"https://api.github.com/users/luongs3","html_url":"https://github.com/luongs3","followers_url":"https://api.github.com/users/luongs3/followers","following_url":"https://api.github.com/users/luongs3/following{/other_user}","gists_url":"https://api.github.com/users/luongs3/gists{/gist_id}","starred_url":"https://api.github.com/users/luongs3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luongs3/subscriptions","organizations_url":"https://api.github.com/users/luongs3/orgs","repos_url":"https://api.github.com/users/luongs3/repos","events_url":"https://api.github.com/users/luongs3/events{/privacy}","received_events_url":"https://api.github.com/users/luongs3/received_events","type":"User","site_admin":false},"repo":{"id":58017414,"name":"fels_131","full_name":"luongs3/fels_131","owner":{"login":"luongs3","id":12150725,"avatar_url":"https://avatars.githubusercontent.com/u/12150725?v=3","gravatar_id":"","url":"https://api.github.com/users/luongs3","html_url":"https://github.com/luongs3","followers_url":"https://api.github.com/users/luongs3/followers","following_url":"https://api.github.com/users/luongs3/following{/other_user}","gists_url":"https://api.github.com/users/luongs3/gists{/gist_id}","starred_url":"https://api.github.com/users/luongs3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luongs3/subscriptions","organizations_url":"https://api.github.com/users/luongs3/orgs","repos_url":"https://api.github.com/users/luongs3/repos","events_url":"https://api.github.com/users/luongs3/events{/privacy}","received_events_url":"https://api.github.com/users/luongs3/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/luongs3/fels_131","description":"Framgia E-Learning System (training)","fork":true,"url":"https://api.github.com/repos/luongs3/fels_131","forks_url":"https://api.github.com/repos/luongs3/fels_131/forks","keys_url":"https://api.github.com/repos/luongs3/fels_131/keys{/key_id}","collaborators_url":"https://api.github.com/repos/luongs3/fels_131/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/luongs3/fels_131/teams","hooks_url":"https://api.github.com/repos/luongs3/fels_131/hooks","issue_events_url":"https://api.github.com/repos/luongs3/fels_131/issues/events{/number}","events_url":"https://api.github.com/repos/luongs3/fels_131/events","assignees_url":"https://api.github.com/repos/luongs3/fels_131/assignees{/user}","branches_url":"https://api.github.com/repos/luongs3/fels_131/branches{/branch}","tags_url":"https://api.github.com/repos/luongs3/fels_131/tags","blobs_url":"https://api.github.com/repos/luongs3/fels_131/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/luongs3/fels_131/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/luongs3/fels_131/git/refs{/sha}","trees_url":"https://api.github.com/repos/luongs3/fels_131/git/trees{/sha}","statuses_url":"https://api.github.com/repos/luongs3/fels_131/statuses/{sha}","languages_url":"https://api.github.com/repos/luongs3/fels_131/languages","stargazers_url":"https://api.github.com/repos/luongs3/fels_131/stargazers","contributors_url":"https://api.github.com/repos/luongs3/fels_131/contributors","subscribers_url":"https://api.github.com/repos/luongs3/fels_131/subscribers","subscription_url":"https://api.github.com/repos/luongs3/fels_131/subscription","commits_url":"https://api.github.com/repos/luongs3/fels_131/commits{/sha}","git_commits_url":"https://api.github.com/repos/luongs3/fels_131/git/commits{/sha}","comments_url":"https://api.github.com/repos/luongs3/fels_131/comments{/number}","issue_comment_url":"https://api.github.com/repos/luongs3/fels_131/issues/comments{/number}","contents_url":"https://api.github.com/repos/luongs3/fels_131/contents/{+path}","compare_url":"https://api.github.com/repos/luongs3/fels_131/compare/{base}...{head}","merges_url":"https://api.github.com/repos/luongs3/fels_131/merges","archive_url":"https://api.github.com/repos/luongs3/fels_131/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/luongs3/fels_131/downloads","issues_url":"https://api.github.com/repos/luongs3/fels_131/issues{/number}","pulls_url":"https://api.github.com/repos/luongs3/fels_131/pulls{/number}","milestones_url":"https://api.github.com/repos/luongs3/fels_131/milestones{/number}","notifications_url":"https://api.github.com/repos/luongs3/fels_131/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/luongs3/fels_131/labels{/name}","releases_url":"https://api.github.com/repos/luongs3/fels_131/releases{/id}","deployments_url":"https://api.github.com/repos/luongs3/fels_131/deployments","created_at":"2016-05-04T02:40:59Z","updated_at":"2016-05-04T02:32:42Z","pushed_at":"2016-05-05T03:37:06Z","git_url":"git://github.com/luongs3/fels_131.git","ssh_url":"git@github.com:luongs3/fels_131.git","clone_url":"https://github.com/luongs3/fels_131.git","svn_url":"https://github.com/luongs3/fels_131","homepage":null,"size":43,"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":"c8cbc2347bd91407094308853db79b6027ed606f","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":58016936,"name":"fels_131","full_name":"framgia/fels_131","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/fels_131","description":"Framgia E-Learning System (training)","fork":false,"url":"https://api.github.com/repos/framgia/fels_131","forks_url":"https://api.github.com/repos/framgia/fels_131/forks","keys_url":"https://api.github.com/repos/framgia/fels_131/keys{/key_id}","collaborators_url":"https://api.github.com/repos/framgia/fels_131/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/framgia/fels_131/teams","hooks_url":"https://api.github.com/repos/framgia/fels_131/hooks","issue_events_url":"https://api.github.com/repos/framgia/fels_131/issues/events{/number}","events_url":"https://api.github.com/repos/framgia/fels_131/events","assignees_url":"https://api.github.com/repos/framgia/fels_131/assignees{/user}","branches_url":"https://api.github.com/repos/framgia/fels_131/branches{/branch}","tags_url":"https://api.github.com/repos/framgia/fels_131/tags","blobs_url":"https://api.github.com/repos/framgia/fels_131/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/framgia/fels_131/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/framgia/fels_131/git/refs{/sha}","trees_url":"https://api.github.com/repos/framgia/fels_131/git/trees{/sha}","statuses_url":"https://api.github.com/repos/framgia/fels_131/statuses/{sha}","languages_url":"https://api.github.com/repos/framgia/fels_131/languages","stargazers_url":"https://api.github.com/repos/framgia/fels_131/stargazers","contributors_url":"https://api.github.com/repos/framgia/fels_131/contributors","subscribers_url":"https://api.github.com/repos/framgia/fels_131/subscribers","subscription_url":"https://api.github.com/repos/framgia/fels_131/subscription","commits_url":"https://api.github.com/repos/framgia/fels_131/commits{/sha}","git_commits_url":"https://api.github.com/repos/framgia/fels_131/git/commits{/sha}","comments_url":"https://api.github.com/repos/framgia/fels_131/comments{/number}","issue_comment_url":"https://api.github.com/repos/framgia/fels_131/issues/comments{/number}","contents_url":"https://api.github.com/repos/framgia/fels_131/contents/{+path}","compare_url":"https://api.github.com/repos/framgia/fels_131/compare/{base}...{head}","merges_url":"https://api.github.com/repos/framgia/fels_131/merges","archive_url":"https://api.github.com/repos/framgia/fels_131/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/framgia/fels_131/downloads","issues_url":"https://api.github.com/repos/framgia/fels_131/issues{/number}","pulls_url":"https://api.github.com/repos/framgia/fels_131/pulls{/number}","milestones_url":"https://api.github.com/repos/framgia/fels_131/milestones{/number}","notifications_url":"https://api.github.com/repos/framgia/fels_131/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/framgia/fels_131/labels{/name}","releases_url":"https://api.github.com/repos/framgia/fels_131/releases{/id}","deployments_url":"https://api.github.com/repos/framgia/fels_131/deployments","created_at":"2016-05-04T02:32:42Z","updated_at":"2016-05-04T02:32:42Z","pushed_at":"2016-05-05T03:41:49Z","git_url":"git://github.com/framgia/fels_131.git","ssh_url":"git@github.com:framgia/fels_131.git","clone_url":"https://github.com/framgia/fels_131.git","svn_url":"https://github.com/framgia/fels_131","homepage":null,"size":41,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/framgia/fels_131/pulls/2"},"html":{"href":"https://github.com/framgia/fels_131/pull/2"},"issue":{"href":"https://api.github.com/repos/framgia/fels_131/issues/2"},"comments":{"href":"https://api.github.com/repos/framgia/fels_131/issues/2/comments"},"review_comments":{"href":"https://api.github.com/repos/framgia/fels_131/pulls/2/comments"},"review_comment":{"href":"https://api.github.com/repos/framgia/fels_131/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/framgia/fels_131/pulls/2/commits"},"statuses":{"href":"https://api.github.com/repos/framgia/fels_131/statuses/5c08b845be94397b86739f6667d57f19a96ad41b"}}}}