GitHub PullRequestReviewCommentEvent at 2014-10-04 05:51:32
Repository: service.website
Actor: mathieumg
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/my-koop/service.website/pulls/comments/18427796","id":18427796,"diff_hunk":"@@ -33,163 +61,209 @@ var TableSorter = React.createClass({\n       columns: this.props.config.columns\n     };\n   },\n+\n   componentWillMount: function() {\n     var self = this;\n-      var itemsData = ajax.request( \n-        {endpoint: routeInfo.itemsData.fullPath}, \n-        function(err, res){\n-          if (err) {\n-            console.error(routeInfo.itemsData.fullPath, status, err.toString());\n-            return;\n-          }\n-          // use res object\n-          self.setState({items:res.body});\n-        });\n+    var itemsData = ajax.request(\n+      {endpoint: routeInfo.itemsData.fullPath},\n+      function(err, res){\n+        if (err) {\n+          console.error(routeInfo.itemsData.fullPath, status, err.toString());\n+          return;\n+        }\n+        // use res object\n+        self.setState({items:res.body});\n+      }\n+    );\n   },\n+\n   handleFilterTextChange: function(column) {\n+    var self = this;\n     return function(newValue) {\n       var obj = this.state.columns;\n       obj[column].filterText = newValue;\n \n       // Since we have already mutated the state, just call forceUpdate().\n       // Ideally we'd copy and setState or use an immutable data structure.\n-      this.forceUpdate();\n-    }.bind(this);\n+      self.forceUpdate();\n+    };\n   },\n+\n   columnNames: function() {\n-    return Object.keys(this.state.columns); \n+    return Object.keys(this.state.columns);\n   },\n+\n   sortColumn: function(column) {\n+    var self = this;\n     return function(event) {\n-      var newSortOrder = (this.state.sort.order == \"asc\") ? \"desc\" : \"asc\";\n+      var newSortOrder = (self.state.sort.order === \"asc\") ? \"desc\" : \"asc\";\n \n-      if (this.state.sort.column != column) {\n-          newSortOrder = this.state.columns[column].defaultSortOrder;\n+      if (self.state.sort.column != column) {\n+        newSortOrder = self.state.columns[column].defaultSortOrder || \"asc\";\n       }\n \n-      this.setState({sort: { column: column, order: newSortOrder }});\n-    }.bind(this);\n-  },\n-  sortClass: function(column) {\n-    var ascOrDesc = (this.state.sort.order == \"asc\") ? \"headerSortAsc\" : \"headerSortDesc\";\n-    return (this.state.sort.column == column) ? ascOrDesc : \"\";\n+      self.setState({sort: { column: column, order: newSortOrder }});\n+    };\n   },\n+\n   render: function() {\n-    var rows = [];\n+    var self = this;\n+    var allRows = [];\n \n-    var columnNames = this.columnNames();\n+    var columnNames = self.columnNames();\n     var filters = {};\n \n     var operandRegex = /^((?:(?:[<>]=?)|==))\\s?([-]?\\d+(?:\\.\\d+)?)$/;","path":"Koop/components/TableSorter.jsx","position":148,"original_position":148,"commit_id":"124b732ce124f169a27ec9d9dd5476e0513e1ab9","original_commit_id":"124b732ce124f169a27ec9d9dd5476e0513e1ab9","user":{"login":"mathieumg","id":1624812,"avatar_url":"https://avatars.githubusercontent.com/u/1624812?v=2","gravatar_id":"","url":"https://api.github.com/users/mathieumg","html_url":"https://github.com/mathieumg","followers_url":"https://api.github.com/users/mathieumg/followers","following_url":"https://api.github.com/users/mathieumg/following{/other_user}","gists_url":"https://api.github.com/users/mathieumg/gists{/gist_id}","starred_url":"https://api.github.com/users/mathieumg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mathieumg/subscriptions","organizations_url":"https://api.github.com/users/mathieumg/orgs","repos_url":"https://api.github.com/users/mathieumg/repos","events_url":"https://api.github.com/users/mathieumg/events{/privacy}","received_events_url":"https://api.github.com/users/mathieumg/received_events","type":"User","site_admin":false},"body":"Why is this here while `operators` is outside the component?","created_at":"2014-10-04T05:51:32Z","updated_at":"2014-10-04T05:51:32Z","html_url":"https://github.com/my-koop/service.website/pull/126#discussion_r18427796","pull_request_url":"https://api.github.com/repos/my-koop/service.website/pulls/126","_links":{"self":{"href":"https://api.github.com/repos/my-koop/service.website/pulls/comments/18427796"},"html":{"href":"https://github.com/my-koop/service.website/pull/126#discussion_r18427796"},"pull_request":{"href":"https://api.github.com/repos/my-koop/service.website/pulls/126"}}},"pull_request":{"url":"https://api.github.com/repos/my-koop/service.website/pulls/126","id":22232036,"html_url":"https://github.com/my-koop/service.website/pull/126","diff_url":"https://github.com/my-koop/service.website/pull/126.diff","patch_url":"https://github.com/my-koop/service.website/pull/126.patch","issue_url":"https://api.github.com/repos/my-koop/service.website/issues/126","number":126,"state":"open","locked":false,"title":"Mike refactor table sort","user":{"login":"Cellule","id":4157103,"avatar_url":"https://avatars.githubusercontent.com/u/4157103?v=2","gravatar_id":"","url":"https://api.github.com/users/Cellule","html_url":"https://github.com/Cellule","followers_url":"https://api.github.com/users/Cellule/followers","following_url":"https://api.github.com/users/Cellule/following{/other_user}","gists_url":"https://api.github.com/users/Cellule/gists{/gist_id}","starred_url":"https://api.github.com/users/Cellule/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Cellule/subscriptions","organizations_url":"https://api.github.com/users/Cellule/orgs","repos_url":"https://api.github.com/users/Cellule/repos","events_url":"https://api.github.com/users/Cellule/events{/privacy}","received_events_url":"https://api.github.com/users/Cellule/received_events","type":"User","site_admin":false},"body":"\r\n\r\n<!---\r\n@huboard:{\"milestone_order\":126.0,\"order\":3.375,\"custom_state\":\"\"}\n-->\r\n","created_at":"2014-10-03T21:45:40Z","updated_at":"2014-10-04T05:51:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f992ab587d70100a63f5245023de6d5e1afca3e9","assignee":{"login":"mathieumg","id":1624812,"avatar_url":"https://avatars.githubusercontent.com/u/1624812?v=2","gravatar_id":"","url":"https://api.github.com/users/mathieumg","html_url":"https://github.com/mathieumg","followers_url":"https://api.github.com/users/mathieumg/followers","following_url":"https://api.github.com/users/mathieumg/following{/other_user}","gists_url":"https://api.github.com/users/mathieumg/gists{/gist_id}","starred_url":"https://api.github.com/users/mathieumg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mathieumg/subscriptions","organizations_url":"https://api.github.com/users/mathieumg/orgs","repos_url":"https://api.github.com/users/mathieumg/repos","events_url":"https://api.github.com/users/mathieumg/events{/privacy}","received_events_url":"https://api.github.com/users/mathieumg/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/my-koop/service.website/milestones/3","labels_url":"https://api.github.com/repos/my-koop/service.website/milestones/3/labels","id":780501,"number":3,"title":"0.1","description":"Early prototype.","creator":{"login":"mathieumg","id":1624812,"avatar_url":"https://avatars.githubusercontent.com/u/1624812?v=2","gravatar_id":"","url":"https://api.github.com/users/mathieumg","html_url":"https://github.com/mathieumg","followers_url":"https://api.github.com/users/mathieumg/followers","following_url":"https://api.github.com/users/mathieumg/following{/other_user}","gists_url":"https://api.github.com/users/mathieumg/gists{/gist_id}","starred_url":"https://api.github.com/users/mathieumg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mathieumg/subscriptions","organizations_url":"https://api.github.com/users/mathieumg/orgs","repos_url":"https://api.github.com/users/mathieumg/repos","events_url":"https://api.github.com/users/mathieumg/events{/privacy}","received_events_url":"https://api.github.com/users/mathieumg/received_events","type":"User","site_admin":false},"open_issues":34,"closed_issues":45,"state":"open","created_at":"2014-09-06T03:10:07Z","updated_at":"2014-10-04T01:48:34Z","due_on":"2014-10-10T07:00:00Z"},"commits_url":"https://api.github.com/repos/my-koop/service.website/pulls/126/commits","review_comments_url":"https://api.github.com/repos/my-koop/service.website/pulls/126/comments","review_comment_url":"https://api.github.com/repos/my-koop/service.website/pulls/comments/{number}","comments_url":"https://api.github.com/repos/my-koop/service.website/issues/126/comments","statuses_url":"https://api.github.com/repos/my-koop/service.website/statuses/124b732ce124f169a27ec9d9dd5476e0513e1ab9","head":{"label":"my-koop:mike_refactor_table_sort","ref":"mike_refactor_table_sort","sha":"124b732ce124f169a27ec9d9dd5476e0513e1ab9","user":{"login":"my-koop","id":8674744,"avatar_url":"https://avatars.githubusercontent.com/u/8674744?v=2","gravatar_id":"","url":"https://api.github.com/users/my-koop","html_url":"https://github.com/my-koop","followers_url":"https://api.github.com/users/my-koop/followers","following_url":"https://api.github.com/users/my-koop/following{/other_user}","gists_url":"https://api.github.com/users/my-koop/gists{/gist_id}","starred_url":"https://api.github.com/users/my-koop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/my-koop/subscriptions","organizations_url":"https://api.github.com/users/my-koop/orgs","repos_url":"https://api.github.com/users/my-koop/repos","events_url":"https://api.github.com/users/my-koop/events{/privacy}","received_events_url":"https://api.github.com/users/my-koop/received_events","type":"Organization","site_admin":false},"repo":{"id":23725016,"name":"service.website","full_name":"my-koop/service.website","owner":{"login":"my-koop","id":8674744,"avatar_url":"https://avatars.githubusercontent.com/u/8674744?v=2","gravatar_id":"","url":"https://api.github.com/users/my-koop","html_url":"https://github.com/my-koop","followers_url":"https://api.github.com/users/my-koop/followers","following_url":"https://api.github.com/users/my-koop/following{/other_user}","gists_url":"https://api.github.com/users/my-koop/gists{/gist_id}","starred_url":"https://api.github.com/users/my-koop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/my-koop/subscriptions","organizations_url":"https://api.github.com/users/my-koop/orgs","repos_url":"https://api.github.com/users/my-koop/repos","events_url":"https://api.github.com/users/my-koop/events{/privacy}","received_events_url":"https://api.github.com/users/my-koop/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/my-koop/service.website","description":"Website service","fork":false,"url":"https://api.github.com/repos/my-koop/service.website","forks_url":"https://api.github.com/repos/my-koop/service.website/forks","keys_url":"https://api.github.com/repos/my-koop/service.website/keys{/key_id}","collaborators_url":"https://api.github.com/repos/my-koop/service.website/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/my-koop/service.website/teams","hooks_url":"https://api.github.com/repos/my-koop/service.website/hooks","issue_events_url":"https://api.github.com/repos/my-koop/service.website/issues/events{/number}","events_url":"https://api.github.com/repos/my-koop/service.website/events","assignees_url":"https://api.github.com/repos/my-koop/service.website/assignees{/user}","branches_url":"https://api.github.com/repos/my-koop/service.website/branches{/branch}","tags_url":"https://api.github.com/repos/my-koop/service.website/tags","blobs_url":"https://api.github.com/repos/my-koop/service.website/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/my-koop/service.website/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/my-koop/service.website/git/refs{/sha}","trees_url":"https://api.github.com/repos/my-koop/service.website/git/trees{/sha}","statuses_url":"https://api.github.com/repos/my-koop/service.website/statuses/{sha}","languages_url":"https://api.github.com/repos/my-koop/service.website/languages","stargazers_url":"https://api.github.com/repos/my-koop/service.website/stargazers","contributors_url":"https://api.github.com/repos/my-koop/service.website/contributors","subscribers_url":"https://api.github.com/repos/my-koop/service.website/subscribers","subscription_url":"https://api.github.com/repos/my-koop/service.website/subscription","commits_url":"https://api.github.com/repos/my-koop/service.website/commits{/sha}","git_commits_url":"https://api.github.com/repos/my-koop/service.website/git/commits{/sha}","comments_url":"https://api.github.com/repos/my-koop/service.website/comments{/number}","issue_comment_url":"https://api.github.com/repos/my-koop/service.website/issues/comments/{number}","contents_url":"https://api.github.com/repos/my-koop/service.website/contents/{+path}","compare_url":"https://api.github.com/repos/my-koop/service.website/compare/{base}...{head}","merges_url":"https://api.github.com/repos/my-koop/service.website/merges","archive_url":"https://api.github.com/repos/my-koop/service.website/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/my-koop/service.website/downloads","issues_url":"https://api.github.com/repos/my-koop/service.website/issues{/number}","pulls_url":"https://api.github.com/repos/my-koop/service.website/pulls{/number}","milestones_url":"https://api.github.com/repos/my-koop/service.website/milestones{/number}","notifications_url":"https://api.github.com/repos/my-koop/service.website/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/my-koop/service.website/labels{/name}","releases_url":"https://api.github.com/repos/my-koop/service.website/releases{/id}","created_at":"2014-09-06T02:53:12Z","updated_at":"2014-10-01T19:08:55Z","pushed_at":"2014-10-03T23:54:27Z","git_url":"git://github.com/my-koop/service.website.git","ssh_url":"git@github.com:my-koop/service.website.git","clone_url":"https://github.com/my-koop/service.website.git","svn_url":"https://github.com/my-koop/service.website","homepage":null,"size":2400,"stargazers_count":5,"watchers_count":5,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":48,"forks":0,"open_issues":48,"watchers":5,"default_branch":"Prototype"}},"base":{"label":"my-koop:Prototype","ref":"Prototype","sha":"a8a72a094d6d3ce649d907bc53ac70ebb3fbf52b","user":{"login":"my-koop","id":8674744,"avatar_url":"https://avatars.githubusercontent.com/u/8674744?v=2","gravatar_id":"","url":"https://api.github.com/users/my-koop","html_url":"https://github.com/my-koop","followers_url":"https://api.github.com/users/my-koop/followers","following_url":"https://api.github.com/users/my-koop/following{/other_user}","gists_url":"https://api.github.com/users/my-koop/gists{/gist_id}","starred_url":"https://api.github.com/users/my-koop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/my-koop/subscriptions","organizations_url":"https://api.github.com/users/my-koop/orgs","repos_url":"https://api.github.com/users/my-koop/repos","events_url":"https://api.github.com/users/my-koop/events{/privacy}","received_events_url":"https://api.github.com/users/my-koop/received_events","type":"Organization","site_admin":false},"repo":{"id":23725016,"name":"service.website","full_name":"my-koop/service.website","owner":{"login":"my-koop","id":8674744,"avatar_url":"https://avatars.githubusercontent.com/u/8674744?v=2","gravatar_id":"","url":"https://api.github.com/users/my-koop","html_url":"https://github.com/my-koop","followers_url":"https://api.github.com/users/my-koop/followers","following_url":"https://api.github.com/users/my-koop/following{/other_user}","gists_url":"https://api.github.com/users/my-koop/gists{/gist_id}","starred_url":"https://api.github.com/users/my-koop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/my-koop/subscriptions","organizations_url":"https://api.github.com/users/my-koop/orgs","repos_url":"https://api.github.com/users/my-koop/repos","events_url":"https://api.github.com/users/my-koop/events{/privacy}","received_events_url":"https://api.github.com/users/my-koop/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/my-koop/service.website","description":"Website service","fork":false,"url":"https://api.github.com/repos/my-koop/service.website","forks_url":"https://api.github.com/repos/my-koop/service.website/forks","keys_url":"https://api.github.com/repos/my-koop/service.website/keys{/key_id}","collaborators_url":"https://api.github.com/repos/my-koop/service.website/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/my-koop/service.website/teams","hooks_url":"https://api.github.com/repos/my-koop/service.website/hooks","issue_events_url":"https://api.github.com/repos/my-koop/service.website/issues/events{/number}","events_url":"https://api.github.com/repos/my-koop/service.website/events","assignees_url":"https://api.github.com/repos/my-koop/service.website/assignees{/user}","branches_url":"https://api.github.com/repos/my-koop/service.website/branches{/branch}","tags_url":"https://api.github.com/repos/my-koop/service.website/tags","blobs_url":"https://api.github.com/repos/my-koop/service.website/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/my-koop/service.website/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/my-koop/service.website/git/refs{/sha}","trees_url":"https://api.github.com/repos/my-koop/service.website/git/trees{/sha}","statuses_url":"https://api.github.com/repos/my-koop/service.website/statuses/{sha}","languages_url":"https://api.github.com/repos/my-koop/service.website/languages","stargazers_url":"https://api.github.com/repos/my-koop/service.website/stargazers","contributors_url":"https://api.github.com/repos/my-koop/service.website/contributors","subscribers_url":"https://api.github.com/repos/my-koop/service.website/subscribers","subscription_url":"https://api.github.com/repos/my-koop/service.website/subscription","commits_url":"https://api.github.com/repos/my-koop/service.website/commits{/sha}","git_commits_url":"https://api.github.com/repos/my-koop/service.website/git/commits{/sha}","comments_url":"https://api.github.com/repos/my-koop/service.website/comments{/number}","issue_comment_url":"https://api.github.com/repos/my-koop/service.website/issues/comments/{number}","contents_url":"https://api.github.com/repos/my-koop/service.website/contents/{+path}","compare_url":"https://api.github.com/repos/my-koop/service.website/compare/{base}...{head}","merges_url":"https://api.github.com/repos/my-koop/service.website/merges","archive_url":"https://api.github.com/repos/my-koop/service.website/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/my-koop/service.website/downloads","issues_url":"https://api.github.com/repos/my-koop/service.website/issues{/number}","pulls_url":"https://api.github.com/repos/my-koop/service.website/pulls{/number}","milestones_url":"https://api.github.com/repos/my-koop/service.website/milestones{/number}","notifications_url":"https://api.github.com/repos/my-koop/service.website/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/my-koop/service.website/labels{/name}","releases_url":"https://api.github.com/repos/my-koop/service.website/releases{/id}","created_at":"2014-09-06T02:53:12Z","updated_at":"2014-10-01T19:08:55Z","pushed_at":"2014-10-03T23:54:27Z","git_url":"git://github.com/my-koop/service.website.git","ssh_url":"git@github.com:my-koop/service.website.git","clone_url":"https://github.com/my-koop/service.website.git","svn_url":"https://github.com/my-koop/service.website","homepage":null,"size":2400,"stargazers_count":5,"watchers_count":5,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":48,"forks":0,"open_issues":48,"watchers":5,"default_branch":"Prototype"}},"_links":{"self":{"href":"https://api.github.com/repos/my-koop/service.website/pulls/126"},"html":{"href":"https://github.com/my-koop/service.website/pull/126"},"issue":{"href":"https://api.github.com/repos/my-koop/service.website/issues/126"},"comments":{"href":"https://api.github.com/repos/my-koop/service.website/issues/126/comments"},"review_comments":{"href":"https://api.github.com/repos/my-koop/service.website/pulls/126/comments"},"review_comment":{"href":"https://api.github.com/repos/my-koop/service.website/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/my-koop/service.website/pulls/126/commits"},"statuses":{"href":"https://api.github.com/repos/my-koop/service.website/statuses/124b732ce124f169a27ec9d9dd5476e0513e1ab9"}}}}