GitHub PullRequestReviewCommentEvent at 2014-09-12 14:40:02
Repository: qt-client
Actor: gilmoskowitz
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/xtuple/qt-client/pulls/comments/17481953","id":17481953,"diff_hunk":"@@ -34,22 +35,30 @@ void updateCreditStatusByCustomer::languageChange()\n \n void updateCreditStatusByCustomer::sUpdate()\n {\n-  XSqlQuery updateUpdate;\n-  updateUpdate.prepare( \"UPDATE custinfo \"\n-             \"SET cust_creditstatus=:cust_creditstatus \"\n-             \"WHERE (cust_id=:cust_id);\" );\n-  updateUpdate.bindValue(\":cust_id\", _cust->id());\n+  if (_privileges->check(\"UpdateCustomerCreditStatus\"))","path":"guiclient/updateCreditStatusByCustomer.cpp","position":17,"original_position":17,"commit_id":"d527750b885cd005e9682651089d763d5bbf7f3e","original_commit_id":"d527750b885cd005e9682651089d763d5bbf7f3e","user":{"login":"gilmoskowitz","id":704111,"avatar_url":"https://avatars.githubusercontent.com/u/704111?v=2","gravatar_id":"cc47324499eafb8470bd77a19366b0c1","url":"https://api.github.com/users/gilmoskowitz","html_url":"https://github.com/gilmoskowitz","followers_url":"https://api.github.com/users/gilmoskowitz/followers","following_url":"https://api.github.com/users/gilmoskowitz/following{/other_user}","gists_url":"https://api.github.com/users/gilmoskowitz/gists{/gist_id}","starred_url":"https://api.github.com/users/gilmoskowitz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gilmoskowitz/subscriptions","organizations_url":"https://api.github.com/users/gilmoskowitz/orgs","repos_url":"https://api.github.com/users/gilmoskowitz/repos","events_url":"https://api.github.com/users/gilmoskowitz/events{/privacy}","received_events_url":"https://api.github.com/users/gilmoskowitz/received_events","type":"User","site_admin":false},"body":"Agreed. The problem is that anyone with `MaintainCustomerMasters` can update the credit status via the Customer window, completely bypassing the `UpdateCustomerCreditStatus` priv. The only way to strictly enforce `UpdateCustomerCreditStatus` is to break precedent as described above or do weird stuff in the trigger.","created_at":"2014-09-12T14:40:02Z","updated_at":"2014-09-12T14:40:02Z","html_url":"https://github.com/xtuple/qt-client/pull/470#discussion_r17481953","pull_request_url":"https://api.github.com/repos/xtuple/qt-client/pulls/470","_links":{"self":{"href":"https://api.github.com/repos/xtuple/qt-client/pulls/comments/17481953"},"html":{"href":"https://github.com/xtuple/qt-client/pull/470#discussion_r17481953"},"pull_request":{"href":"https://api.github.com/repos/xtuple/qt-client/pulls/470"}}},"pull_request":{"url":"https://api.github.com/repos/xtuple/qt-client/pulls/470","id":20787927,"html_url":"https://github.com/xtuple/qt-client/pull/470","diff_url":"https://github.com/xtuple/qt-client/pull/470.diff","patch_url":"https://github.com/xtuple/qt-client/pull/470.patch","issue_url":"https://api.github.com/repos/xtuple/qt-client/issues/470","number":470,"state":"open","locked":false,"title":"Privilege check added to update function and message","user":{"login":"malfredo32","id":5040740,"avatar_url":"https://avatars.githubusercontent.com/u/5040740?v=2","gravatar_id":"bc8e82bf946fac574680a2947ff8a87b","url":"https://api.github.com/users/malfredo32","html_url":"https://github.com/malfredo32","followers_url":"https://api.github.com/users/malfredo32/followers","following_url":"https://api.github.com/users/malfredo32/following{/other_user}","gists_url":"https://api.github.com/users/malfredo32/gists{/gist_id}","starred_url":"https://api.github.com/users/malfredo32/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/malfredo32/subscriptions","organizations_url":"https://api.github.com/users/malfredo32/orgs","repos_url":"https://api.github.com/users/malfredo32/repos","events_url":"https://api.github.com/users/malfredo32/events{/privacy}","received_events_url":"https://api.github.com/users/malfredo32/received_events","type":"User","site_admin":false},"body":"Based on bug report, menuSales.cpp was reviewed and detected that menu privilege check is OR linked with CustomerMasterMaintain so CustomerMasterMaintain activates the menu option. The behavior requested by the bug will make the utility to work only having the update credit status privilege. As bug is confirmed I have programmed the privilege and a error message if the user don't have it.","created_at":"2014-09-05T04:44:10Z","updated_at":"2014-09-12T14:40:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c09dd3514123d5954a44027c9a304dbb0e493e4b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/xtuple/qt-client/pulls/470/commits","review_comments_url":"https://api.github.com/repos/xtuple/qt-client/pulls/470/comments","review_comment_url":"https://api.github.com/repos/xtuple/qt-client/pulls/comments/{number}","comments_url":"https://api.github.com/repos/xtuple/qt-client/issues/470/comments","statuses_url":"https://api.github.com/repos/xtuple/qt-client/statuses/d527750b885cd005e9682651089d763d5bbf7f3e","head":{"label":"malfredo32:haxtuple1","ref":"haxtuple1","sha":"d527750b885cd005e9682651089d763d5bbf7f3e","user":{"login":"malfredo32","id":5040740,"avatar_url":"https://avatars.githubusercontent.com/u/5040740?v=2","gravatar_id":"bc8e82bf946fac574680a2947ff8a87b","url":"https://api.github.com/users/malfredo32","html_url":"https://github.com/malfredo32","followers_url":"https://api.github.com/users/malfredo32/followers","following_url":"https://api.github.com/users/malfredo32/following{/other_user}","gists_url":"https://api.github.com/users/malfredo32/gists{/gist_id}","starred_url":"https://api.github.com/users/malfredo32/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/malfredo32/subscriptions","organizations_url":"https://api.github.com/users/malfredo32/orgs","repos_url":"https://api.github.com/users/malfredo32/repos","events_url":"https://api.github.com/users/malfredo32/events{/privacy}","received_events_url":"https://api.github.com/users/malfredo32/received_events","type":"User","site_admin":false},"repo":{"id":12412291,"name":"qt-client","full_name":"malfredo32/qt-client","owner":{"login":"malfredo32","id":5040740,"avatar_url":"https://avatars.githubusercontent.com/u/5040740?v=2","gravatar_id":"bc8e82bf946fac574680a2947ff8a87b","url":"https://api.github.com/users/malfredo32","html_url":"https://github.com/malfredo32","followers_url":"https://api.github.com/users/malfredo32/followers","following_url":"https://api.github.com/users/malfredo32/following{/other_user}","gists_url":"https://api.github.com/users/malfredo32/gists{/gist_id}","starred_url":"https://api.github.com/users/malfredo32/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/malfredo32/subscriptions","organizations_url":"https://api.github.com/users/malfredo32/orgs","repos_url":"https://api.github.com/users/malfredo32/repos","events_url":"https://api.github.com/users/malfredo32/events{/privacy}","received_events_url":"https://api.github.com/users/malfredo32/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/malfredo32/qt-client","description":"Desktop Client and Database","fork":true,"url":"https://api.github.com/repos/malfredo32/qt-client","forks_url":"https://api.github.com/repos/malfredo32/qt-client/forks","keys_url":"https://api.github.com/repos/malfredo32/qt-client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/malfredo32/qt-client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/malfredo32/qt-client/teams","hooks_url":"https://api.github.com/repos/malfredo32/qt-client/hooks","issue_events_url":"https://api.github.com/repos/malfredo32/qt-client/issues/events{/number}","events_url":"https://api.github.com/repos/malfredo32/qt-client/events","assignees_url":"https://api.github.com/repos/malfredo32/qt-client/assignees{/user}","branches_url":"https://api.github.com/repos/malfredo32/qt-client/branches{/branch}","tags_url":"https://api.github.com/repos/malfredo32/qt-client/tags","blobs_url":"https://api.github.com/repos/malfredo32/qt-client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/malfredo32/qt-client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/malfredo32/qt-client/git/refs{/sha}","trees_url":"https://api.github.com/repos/malfredo32/qt-client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/malfredo32/qt-client/statuses/{sha}","languages_url":"https://api.github.com/repos/malfredo32/qt-client/languages","stargazers_url":"https://api.github.com/repos/malfredo32/qt-client/stargazers","contributors_url":"https://api.github.com/repos/malfredo32/qt-client/contributors","subscribers_url":"https://api.github.com/repos/malfredo32/qt-client/subscribers","subscription_url":"https://api.github.com/repos/malfredo32/qt-client/subscription","commits_url":"https://api.github.com/repos/malfredo32/qt-client/commits{/sha}","git_commits_url":"https://api.github.com/repos/malfredo32/qt-client/git/commits{/sha}","comments_url":"https://api.github.com/repos/malfredo32/qt-client/comments{/number}","issue_comment_url":"https://api.github.com/repos/malfredo32/qt-client/issues/comments/{number}","contents_url":"https://api.github.com/repos/malfredo32/qt-client/contents/{+path}","compare_url":"https://api.github.com/repos/malfredo32/qt-client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/malfredo32/qt-client/merges","archive_url":"https://api.github.com/repos/malfredo32/qt-client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/malfredo32/qt-client/downloads","issues_url":"https://api.github.com/repos/malfredo32/qt-client/issues{/number}","pulls_url":"https://api.github.com/repos/malfredo32/qt-client/pulls{/number}","milestones_url":"https://api.github.com/repos/malfredo32/qt-client/milestones{/number}","notifications_url":"https://api.github.com/repos/malfredo32/qt-client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/malfredo32/qt-client/labels{/name}","releases_url":"https://api.github.com/repos/malfredo32/qt-client/releases{/id}","created_at":"2013-08-27T17:06:43Z","updated_at":"2014-02-20T14:11:09Z","pushed_at":"2014-09-05T05:43:04Z","git_url":"git://github.com/malfredo32/qt-client.git","ssh_url":"git@github.com:malfredo32/qt-client.git","clone_url":"https://github.com/malfredo32/qt-client.git","svn_url":"https://github.com/malfredo32/qt-client","homepage":null,"size":57127,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"xtuple:4_7_x","ref":"4_7_x","sha":"08b731868a07427e1e55dd0464a02b1e77eab1a3","user":{"login":"xtuple","id":703922,"avatar_url":"https://avatars.githubusercontent.com/u/703922?v=2","gravatar_id":"50375c477e5e16ff431a203c64fc9c38","url":"https://api.github.com/users/xtuple","html_url":"https://github.com/xtuple","followers_url":"https://api.github.com/users/xtuple/followers","following_url":"https://api.github.com/users/xtuple/following{/other_user}","gists_url":"https://api.github.com/users/xtuple/gists{/gist_id}","starred_url":"https://api.github.com/users/xtuple/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xtuple/subscriptions","organizations_url":"https://api.github.com/users/xtuple/orgs","repos_url":"https://api.github.com/users/xtuple/repos","events_url":"https://api.github.com/users/xtuple/events{/privacy}","received_events_url":"https://api.github.com/users/xtuple/received_events","type":"Organization","site_admin":false},"repo":{"id":10383821,"name":"qt-client","full_name":"xtuple/qt-client","owner":{"login":"xtuple","id":703922,"avatar_url":"https://avatars.githubusercontent.com/u/703922?v=2","gravatar_id":"50375c477e5e16ff431a203c64fc9c38","url":"https://api.github.com/users/xtuple","html_url":"https://github.com/xtuple","followers_url":"https://api.github.com/users/xtuple/followers","following_url":"https://api.github.com/users/xtuple/following{/other_user}","gists_url":"https://api.github.com/users/xtuple/gists{/gist_id}","starred_url":"https://api.github.com/users/xtuple/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xtuple/subscriptions","organizations_url":"https://api.github.com/users/xtuple/orgs","repos_url":"https://api.github.com/users/xtuple/repos","events_url":"https://api.github.com/users/xtuple/events{/privacy}","received_events_url":"https://api.github.com/users/xtuple/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/xtuple/qt-client","description":"Desktop Client","fork":false,"url":"https://api.github.com/repos/xtuple/qt-client","forks_url":"https://api.github.com/repos/xtuple/qt-client/forks","keys_url":"https://api.github.com/repos/xtuple/qt-client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/xtuple/qt-client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/xtuple/qt-client/teams","hooks_url":"https://api.github.com/repos/xtuple/qt-client/hooks","issue_events_url":"https://api.github.com/repos/xtuple/qt-client/issues/events{/number}","events_url":"https://api.github.com/repos/xtuple/qt-client/events","assignees_url":"https://api.github.com/repos/xtuple/qt-client/assignees{/user}","branches_url":"https://api.github.com/repos/xtuple/qt-client/branches{/branch}","tags_url":"https://api.github.com/repos/xtuple/qt-client/tags","blobs_url":"https://api.github.com/repos/xtuple/qt-client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/xtuple/qt-client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/xtuple/qt-client/git/refs{/sha}","trees_url":"https://api.github.com/repos/xtuple/qt-client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/xtuple/qt-client/statuses/{sha}","languages_url":"https://api.github.com/repos/xtuple/qt-client/languages","stargazers_url":"https://api.github.com/repos/xtuple/qt-client/stargazers","contributors_url":"https://api.github.com/repos/xtuple/qt-client/contributors","subscribers_url":"https://api.github.com/repos/xtuple/qt-client/subscribers","subscription_url":"https://api.github.com/repos/xtuple/qt-client/subscription","commits_url":"https://api.github.com/repos/xtuple/qt-client/commits{/sha}","git_commits_url":"https://api.github.com/repos/xtuple/qt-client/git/commits{/sha}","comments_url":"https://api.github.com/repos/xtuple/qt-client/comments{/number}","issue_comment_url":"https://api.github.com/repos/xtuple/qt-client/issues/comments/{number}","contents_url":"https://api.github.com/repos/xtuple/qt-client/contents/{+path}","compare_url":"https://api.github.com/repos/xtuple/qt-client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/xtuple/qt-client/merges","archive_url":"https://api.github.com/repos/xtuple/qt-client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/xtuple/qt-client/downloads","issues_url":"https://api.github.com/repos/xtuple/qt-client/issues{/number}","pulls_url":"https://api.github.com/repos/xtuple/qt-client/pulls{/number}","milestones_url":"https://api.github.com/repos/xtuple/qt-client/milestones{/number}","notifications_url":"https://api.github.com/repos/xtuple/qt-client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/xtuple/qt-client/labels{/name}","releases_url":"https://api.github.com/repos/xtuple/qt-client/releases{/id}","created_at":"2013-05-30T13:54:04Z","updated_at":"2014-09-07T10:59:04Z","pushed_at":"2014-09-10T14:39:20Z","git_url":"git://github.com/xtuple/qt-client.git","ssh_url":"git@github.com:xtuple/qt-client.git","clone_url":"https://github.com/xtuple/qt-client.git","svn_url":"https://github.com/xtuple/qt-client","homepage":"","size":92580,"stargazers_count":14,"watchers_count":14,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"forks_count":67,"mirror_url":null,"open_issues_count":15,"forks":67,"open_issues":15,"watchers":14,"default_branch":"4_7_x"}},"_links":{"self":{"href":"https://api.github.com/repos/xtuple/qt-client/pulls/470"},"html":{"href":"https://github.com/xtuple/qt-client/pull/470"},"issue":{"href":"https://api.github.com/repos/xtuple/qt-client/issues/470"},"comments":{"href":"https://api.github.com/repos/xtuple/qt-client/issues/470/comments"},"review_comments":{"href":"https://api.github.com/repos/xtuple/qt-client/pulls/470/comments"},"review_comment":{"href":"https://api.github.com/repos/xtuple/qt-client/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/xtuple/qt-client/pulls/470/commits"},"statuses":{"href":"https://api.github.com/repos/xtuple/qt-client/statuses/d527750b885cd005e9682651089d763d5bbf7f3e"}}}}