GitHub PullRequestReviewCommentEvent at 2014-10-02 07:56:33
Repository: fels_13
Actor: dinhhoanglong91
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/framgia/fels_13/pulls/comments/18326201","id":18326201,"diff_hunk":"@@ -0,0 +1,75 @@\n+<?php\n+/**\n+ * Application level Controller\n+ *\n+ * This file is application-wide controller file. You can put all\n+ * application-wide controller-related methods here.\n+ *\n+ * CakePHP(tm) : Rapid Development Framework (http://cakephp.org)\n+ * Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)\n+ *\n+ * Licensed under The MIT License\n+ * For full copyright and license information, please see the LICENSE.txt\n+ * Redistributions of files must retain the above copyright notice.\n+ *\n+ * @copyright     Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)\n+ * @link          http://cakephp.org CakePHP(tm) Project\n+ * @package       app.Controller\n+ * @since         CakePHP(tm) v 0.2.9\n+ * @license       http://www.opensource.org/licenses/mit-license.php MIT License\n+ */\n+\n+App::uses('Controller', 'Controller');\n+\n+/**\n+ * Application Controller\n+ *\n+ * Add your application-wide methods in the class below, your controllers\n+ * will inherit them.\n+ *\n+ * @package\t\tapp.Controller\n+ * @link\t\thttp://book.cakephp.org/2.0/en/controllers.html#the-app-controller\n+ */\n+class AppController extends Controller {\n+    /**\n+     * Config layout for user and admin\n+     */\n+    \n+    public function beforeFilter() {\n+        //parent::beforeFilter();\n+        \n+        /**\n+         * Không áp dụng cho các function trong mảng này\n+         */\n+        $excludeFunctions = array('admin_login', 'admin_logout');\n+        \n+        if($this->params['prefix'] == \"admin\" && isset($this->params[\"prefix\"])){\n+            //$this->layout = \"admin\";\n+            if($this->__adminAuthCheck() === TRUE){\n+                $this->layout = \"admin\";\n+            }elseif (!in_array($this->action, $excludeFunctions)) {\n+                $this->redirect(SITE_URL);\n+            }\n+        }else{\n+            \n+        }\n+    }\n+    \n+    /**\n+     * Check Admin authentication\n+     * \n+     * @return boolean Auth or Un-auth\n+     */\n+    private function __adminAuthCheck(){\n+        $session = $this->Session->read('UserSession');\n+        \n+        if(isset($session[\"isLogin\"])","path":"app/Controller/AppController.php","position":66,"original_position":66,"commit_id":"2efe2c2c615c1cbc17cd419fd4c237d6ef853497","original_commit_id":"2efe2c2c615c1cbc17cd419fd4c237d6ef853497","user":{"login":"dinhhoanglong91","id":1893820,"avatar_url":"https://avatars.githubusercontent.com/u/1893820?v=2","gravatar_id":"","url":"https://api.github.com/users/dinhhoanglong91","html_url":"https://github.com/dinhhoanglong91","followers_url":"https://api.github.com/users/dinhhoanglong91/followers","following_url":"https://api.github.com/users/dinhhoanglong91/following{/other_user}","gists_url":"https://api.github.com/users/dinhhoanglong91/gists{/gist_id}","starred_url":"https://api.github.com/users/dinhhoanglong91/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dinhhoanglong91/subscriptions","organizations_url":"https://api.github.com/users/dinhhoanglong91/orgs","repos_url":"https://api.github.com/users/dinhhoanglong91/repos","events_url":"https://api.github.com/users/dinhhoanglong91/events{/privacy}","received_events_url":"https://api.github.com/users/dinhhoanglong91/received_events","type":"User","site_admin":false},"body":"thiếu space trước ```(```","created_at":"2014-10-02T07:56:33Z","updated_at":"2014-10-02T07:56:33Z","html_url":"https://github.com/framgia/fels_13/pull/3#discussion_r18326201","pull_request_url":"https://api.github.com/repos/framgia/fels_13/pulls/3","_links":{"self":{"href":"https://api.github.com/repos/framgia/fels_13/pulls/comments/18326201"},"html":{"href":"https://github.com/framgia/fels_13/pull/3#discussion_r18326201"},"pull_request":{"href":"https://api.github.com/repos/framgia/fels_13/pulls/3"}}},"pull_request":{"url":"https://api.github.com/repos/framgia/fels_13/pulls/3","id":22124234,"html_url":"https://github.com/framgia/fels_13/pull/3","diff_url":"https://github.com/framgia/fels_13/pull/3.diff","patch_url":"https://github.com/framgia/fels_13/pull/3.patch","issue_url":"https://api.github.com/repos/framgia/fels_13/issues/3","number":3,"state":"open","locked":false,"title":"Upload source code","user":{"login":"namnv609","id":8691772,"avatar_url":"https://avatars.githubusercontent.com/u/8691772?v=2","gravatar_id":"","url":"https://api.github.com/users/namnv609","html_url":"https://github.com/namnv609","followers_url":"https://api.github.com/users/namnv609/followers","following_url":"https://api.github.com/users/namnv609/following{/other_user}","gists_url":"https://api.github.com/users/namnv609/gists{/gist_id}","starred_url":"https://api.github.com/users/namnv609/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/namnv609/subscriptions","organizations_url":"https://api.github.com/users/namnv609/orgs","repos_url":"https://api.github.com/users/namnv609/repos","events_url":"https://api.github.com/users/namnv609/events{/privacy}","received_events_url":"https://api.github.com/users/namnv609/received_events","type":"User","site_admin":false},"body":"# Upload CakePhp Core\r\n* Cấu hình\r\n* Thêm layout admin\r\n\t* app/Controller/HomeController.php\r\n\t* app/Model/Home.php\r\n\t* app/Model/Login.php\r\n\t* app/View/Layouts/admin.ctp\r\n\t* app/View/Home/admin_index.ctp\r\n\t* app/View/Home/admin_login.ctp\r\n* Thêm layout user\r\n\t* app/View/Home/index.ctp\r\n\r\nVà các file images, css, js","created_at":"2014-10-02T07:31:00Z","updated_at":"2014-10-02T07:56:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0e7642268f6fba8e4a64340f36c278b770b6c493","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/framgia/fels_13/pulls/3/commits","review_comments_url":"https://api.github.com/repos/framgia/fels_13/pulls/3/comments","review_comment_url":"https://api.github.com/repos/framgia/fels_13/pulls/comments/{number}","comments_url":"https://api.github.com/repos/framgia/fels_13/issues/3/comments","statuses_url":"https://api.github.com/repos/framgia/fels_13/statuses/2efe2c2c615c1cbc17cd419fd4c237d6ef853497","head":{"label":"namnv609:cakeCore","ref":"cakeCore","sha":"2efe2c2c615c1cbc17cd419fd4c237d6ef853497","user":{"login":"namnv609","id":8691772,"avatar_url":"https://avatars.githubusercontent.com/u/8691772?v=2","gravatar_id":"","url":"https://api.github.com/users/namnv609","html_url":"https://github.com/namnv609","followers_url":"https://api.github.com/users/namnv609/followers","following_url":"https://api.github.com/users/namnv609/following{/other_user}","gists_url":"https://api.github.com/users/namnv609/gists{/gist_id}","starred_url":"https://api.github.com/users/namnv609/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/namnv609/subscriptions","organizations_url":"https://api.github.com/users/namnv609/orgs","repos_url":"https://api.github.com/users/namnv609/repos","events_url":"https://api.github.com/users/namnv609/events{/privacy}","received_events_url":"https://api.github.com/users/namnv609/received_events","type":"User","site_admin":false},"repo":{"id":24668828,"name":"fels_13","full_name":"namnv609/fels_13","owner":{"login":"namnv609","id":8691772,"avatar_url":"https://avatars.githubusercontent.com/u/8691772?v=2","gravatar_id":"","url":"https://api.github.com/users/namnv609","html_url":"https://github.com/namnv609","followers_url":"https://api.github.com/users/namnv609/followers","following_url":"https://api.github.com/users/namnv609/following{/other_user}","gists_url":"https://api.github.com/users/namnv609/gists{/gist_id}","starred_url":"https://api.github.com/users/namnv609/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/namnv609/subscriptions","organizations_url":"https://api.github.com/users/namnv609/orgs","repos_url":"https://api.github.com/users/namnv609/repos","events_url":"https://api.github.com/users/namnv609/events{/privacy}","received_events_url":"https://api.github.com/users/namnv609/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/namnv609/fels_13","description":"Framgia E-Learning System","fork":true,"url":"https://api.github.com/repos/namnv609/fels_13","forks_url":"https://api.github.com/repos/namnv609/fels_13/forks","keys_url":"https://api.github.com/repos/namnv609/fels_13/keys{/key_id}","collaborators_url":"https://api.github.com/repos/namnv609/fels_13/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/namnv609/fels_13/teams","hooks_url":"https://api.github.com/repos/namnv609/fels_13/hooks","issue_events_url":"https://api.github.com/repos/namnv609/fels_13/issues/events{/number}","events_url":"https://api.github.com/repos/namnv609/fels_13/events","assignees_url":"https://api.github.com/repos/namnv609/fels_13/assignees{/user}","branches_url":"https://api.github.com/repos/namnv609/fels_13/branches{/branch}","tags_url":"https://api.github.com/repos/namnv609/fels_13/tags","blobs_url":"https://api.github.com/repos/namnv609/fels_13/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/namnv609/fels_13/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/namnv609/fels_13/git/refs{/sha}","trees_url":"https://api.github.com/repos/namnv609/fels_13/git/trees{/sha}","statuses_url":"https://api.github.com/repos/namnv609/fels_13/statuses/{sha}","languages_url":"https://api.github.com/repos/namnv609/fels_13/languages","stargazers_url":"https://api.github.com/repos/namnv609/fels_13/stargazers","contributors_url":"https://api.github.com/repos/namnv609/fels_13/contributors","subscribers_url":"https://api.github.com/repos/namnv609/fels_13/subscribers","subscription_url":"https://api.github.com/repos/namnv609/fels_13/subscription","commits_url":"https://api.github.com/repos/namnv609/fels_13/commits{/sha}","git_commits_url":"https://api.github.com/repos/namnv609/fels_13/git/commits{/sha}","comments_url":"https://api.github.com/repos/namnv609/fels_13/comments{/number}","issue_comment_url":"https://api.github.com/repos/namnv609/fels_13/issues/comments/{number}","contents_url":"https://api.github.com/repos/namnv609/fels_13/contents/{+path}","compare_url":"https://api.github.com/repos/namnv609/fels_13/compare/{base}...{head}","merges_url":"https://api.github.com/repos/namnv609/fels_13/merges","archive_url":"https://api.github.com/repos/namnv609/fels_13/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/namnv609/fels_13/downloads","issues_url":"https://api.github.com/repos/namnv609/fels_13/issues{/number}","pulls_url":"https://api.github.com/repos/namnv609/fels_13/pulls{/number}","milestones_url":"https://api.github.com/repos/namnv609/fels_13/milestones{/number}","notifications_url":"https://api.github.com/repos/namnv609/fels_13/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/namnv609/fels_13/labels{/name}","releases_url":"https://api.github.com/repos/namnv609/fels_13/releases{/id}","created_at":"2014-10-01T07:01:05Z","updated_at":"2014-10-01T06:57:05Z","pushed_at":"2014-10-02T07:02:21Z","git_url":"git://github.com/namnv609/fels_13.git","ssh_url":"git@github.com:namnv609/fels_13.git","clone_url":"https://github.com/namnv609/fels_13.git","svn_url":"https://github.com/namnv609/fels_13","homepage":null,"size":0,"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":"951153721e38210c43c450073f81af30bd88e926","user":{"login":"framgia","id":2322183,"avatar_url":"https://avatars.githubusercontent.com/u/2322183?v=2","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":24668728,"name":"fels_13","full_name":"framgia/fels_13","owner":{"login":"framgia","id":2322183,"avatar_url":"https://avatars.githubusercontent.com/u/2322183?v=2","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_13","description":"Framgia E-Learning System","fork":false,"url":"https://api.github.com/repos/framgia/fels_13","forks_url":"https://api.github.com/repos/framgia/fels_13/forks","keys_url":"https://api.github.com/repos/framgia/fels_13/keys{/key_id}","collaborators_url":"https://api.github.com/repos/framgia/fels_13/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/framgia/fels_13/teams","hooks_url":"https://api.github.com/repos/framgia/fels_13/hooks","issue_events_url":"https://api.github.com/repos/framgia/fels_13/issues/events{/number}","events_url":"https://api.github.com/repos/framgia/fels_13/events","assignees_url":"https://api.github.com/repos/framgia/fels_13/assignees{/user}","branches_url":"https://api.github.com/repos/framgia/fels_13/branches{/branch}","tags_url":"https://api.github.com/repos/framgia/fels_13/tags","blobs_url":"https://api.github.com/repos/framgia/fels_13/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/framgia/fels_13/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/framgia/fels_13/git/refs{/sha}","trees_url":"https://api.github.com/repos/framgia/fels_13/git/trees{/sha}","statuses_url":"https://api.github.com/repos/framgia/fels_13/statuses/{sha}","languages_url":"https://api.github.com/repos/framgia/fels_13/languages","stargazers_url":"https://api.github.com/repos/framgia/fels_13/stargazers","contributors_url":"https://api.github.com/repos/framgia/fels_13/contributors","subscribers_url":"https://api.github.com/repos/framgia/fels_13/subscribers","subscription_url":"https://api.github.com/repos/framgia/fels_13/subscription","commits_url":"https://api.github.com/repos/framgia/fels_13/commits{/sha}","git_commits_url":"https://api.github.com/repos/framgia/fels_13/git/commits{/sha}","comments_url":"https://api.github.com/repos/framgia/fels_13/comments{/number}","issue_comment_url":"https://api.github.com/repos/framgia/fels_13/issues/comments/{number}","contents_url":"https://api.github.com/repos/framgia/fels_13/contents/{+path}","compare_url":"https://api.github.com/repos/framgia/fels_13/compare/{base}...{head}","merges_url":"https://api.github.com/repos/framgia/fels_13/merges","archive_url":"https://api.github.com/repos/framgia/fels_13/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/framgia/fels_13/downloads","issues_url":"https://api.github.com/repos/framgia/fels_13/issues{/number}","pulls_url":"https://api.github.com/repos/framgia/fels_13/pulls{/number}","milestones_url":"https://api.github.com/repos/framgia/fels_13/milestones{/number}","notifications_url":"https://api.github.com/repos/framgia/fels_13/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/framgia/fels_13/labels{/name}","releases_url":"https://api.github.com/repos/framgia/fels_13/releases{/id}","created_at":"2014-10-01T06:57:05Z","updated_at":"2014-10-01T06:57:05Z","pushed_at":"2014-10-01T06:58:25Z","git_url":"git://github.com/framgia/fels_13.git","ssh_url":"git@github.com:framgia/fels_13.git","clone_url":"https://github.com/framgia/fels_13.git","svn_url":"https://github.com/framgia/fels_13","homepage":null,"size":0,"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_13/pulls/3"},"html":{"href":"https://github.com/framgia/fels_13/pull/3"},"issue":{"href":"https://api.github.com/repos/framgia/fels_13/issues/3"},"comments":{"href":"https://api.github.com/repos/framgia/fels_13/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/framgia/fels_13/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/framgia/fels_13/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/framgia/fels_13/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/framgia/fels_13/statuses/2efe2c2c615c1cbc17cd419fd4c237d6ef853497"}}}}