{"action":"closed","number":1214,"pull_request":{"url":"https://api.github.com/repos/mautic/mautic/pulls/1214","id":52097839,"html_url":"https://github.com/mautic/mautic/pull/1214","diff_url":"https://github.com/mautic/mautic/pull/1214.diff","patch_url":"https://github.com/mautic/mautic/pull/1214.patch","issue_url":"https://api.github.com/repos/mautic/mautic/issues/1214","number":1214,"state":"closed","locked":false,"title":"Fixed lead list view own permission","user":{"login":"escopecz","id":1235442,"avatar_url":"https://avatars.githubusercontent.com/u/1235442?v=3","gravatar_id":"","url":"https://api.github.com/users/escopecz","html_url":"https://github.com/escopecz","followers_url":"https://api.github.com/users/escopecz/followers","following_url":"https://api.github.com/users/escopecz/following{/other_user}","gists_url":"https://api.github.com/users/escopecz/gists{/gist_id}","starred_url":"https://api.github.com/users/escopecz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/escopecz/subscriptions","organizations_url":"https://api.github.com/users/escopecz/orgs","repos_url":"https://api.github.com/users/escopecz/repos","events_url":"https://api.github.com/users/escopecz/events{/privacy}","received_events_url":"https://api.github.com/users/escopecz/received_events","type":"User","site_admin":false},"body":"I was working on fix for https://github.com/mautic/mautic/issues/1213, but I maybe don't fully understand the problematic of why the code is how it is so this PR is more for discussion than suggested change. Questions are probably to @alanhartless:\r\n\r\n1. If the permission is `lead:lists:viewother` apply filter `$filter[\"force\"] = \" ($mine or $global)\";`. Is that some really old, unnecessary code or does it have some deep meaning I don't get (as usual)?\r\n2. Why there is no `lead:lists:viewown` permission and `lead:leads:viewown` is used for lead lists instead? Viewing lead lists is required to view leads?","created_at":"2015-11-30T08:52:24Z","updated_at":"2015-12-04T07:19:54Z","closed_at":"2015-12-04T07:19:54Z","merged_at":null,"merge_commit_sha":"f6768ee2459ece74c97c1a5248e23ae761a9863b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mautic/mautic/pulls/1214/commits","review_comments_url":"https://api.github.com/repos/mautic/mautic/pulls/1214/comments","review_comment_url":"https://api.github.com/repos/mautic/mautic/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mautic/mautic/issues/1214/comments","statuses_url":"https://api.github.com/repos/mautic/mautic/statuses/6df825614af99966c4e6d0de4cfc5486d471e13e","head":{"label":"escopecz:lead-view-permissions","ref":"lead-view-permissions","sha":"6df825614af99966c4e6d0de4cfc5486d471e13e","user":{"login":"escopecz","id":1235442,"avatar_url":"https://avatars.githubusercontent.com/u/1235442?v=3","gravatar_id":"","url":"https://api.github.com/users/escopecz","html_url":"https://github.com/escopecz","followers_url":"https://api.github.com/users/escopecz/followers","following_url":"https://api.github.com/users/escopecz/following{/other_user}","gists_url":"https://api.github.com/users/escopecz/gists{/gist_id}","starred_url":"https://api.github.com/users/escopecz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/escopecz/subscriptions","organizations_url":"https://api.github.com/users/escopecz/orgs","repos_url":"https://api.github.com/users/escopecz/repos","events_url":"https://api.github.com/users/escopecz/events{/privacy}","received_events_url":"https://api.github.com/users/escopecz/received_events","type":"User","site_admin":false},"repo":{"id":31202004,"name":"mautic","full_name":"escopecz/mautic","owner":{"login":"escopecz","id":1235442,"avatar_url":"https://avatars.githubusercontent.com/u/1235442?v=3","gravatar_id":"","url":"https://api.github.com/users/escopecz","html_url":"https://github.com/escopecz","followers_url":"https://api.github.com/users/escopecz/followers","following_url":"https://api.github.com/users/escopecz/following{/other_user}","gists_url":"https://api.github.com/users/escopecz/gists{/gist_id}","starred_url":"https://api.github.com/users/escopecz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/escopecz/subscriptions","organizations_url":"https://api.github.com/users/escopecz/orgs","repos_url":"https://api.github.com/users/escopecz/repos","events_url":"https://api.github.com/users/escopecz/events{/privacy}","received_events_url":"https://api.github.com/users/escopecz/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/escopecz/mautic","description":"Mautic: Open Source Marketing Automation Software.","fork":true,"url":"https://api.github.com/repos/escopecz/mautic","forks_url":"https://api.github.com/repos/escopecz/mautic/forks","keys_url":"https://api.github.com/repos/escopecz/mautic/keys{/key_id}","collaborators_url":"https://api.github.com/repos/escopecz/mautic/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/escopecz/mautic/teams","hooks_url":"https://api.github.com/repos/escopecz/mautic/hooks","issue_events_url":"https://api.github.com/repos/escopecz/mautic/issues/events{/number}","events_url":"https://api.github.com/repos/escopecz/mautic/events","assignees_url":"https://api.github.com/repos/escopecz/mautic/assignees{/user}","branches_url":"https://api.github.com/repos/escopecz/mautic/branches{/branch}","tags_url":"https://api.github.com/repos/escopecz/mautic/tags","blobs_url":"https://api.github.com/repos/escopecz/mautic/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/escopecz/mautic/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/escopecz/mautic/git/refs{/sha}","trees_url":"https://api.github.com/repos/escopecz/mautic/git/trees{/sha}","statuses_url":"https://api.github.com/repos/escopecz/mautic/statuses/{sha}","languages_url":"https://api.github.com/repos/escopecz/mautic/languages","stargazers_url":"https://api.github.com/repos/escopecz/mautic/stargazers","contributors_url":"https://api.github.com/repos/escopecz/mautic/contributors","subscribers_url":"https://api.github.com/repos/escopecz/mautic/subscribers","subscription_url":"https://api.github.com/repos/escopecz/mautic/subscription","commits_url":"https://api.github.com/repos/escopecz/mautic/commits{/sha}","git_commits_url":"https://api.github.com/repos/escopecz/mautic/git/commits{/sha}","comments_url":"https://api.github.com/repos/escopecz/mautic/comments{/number}","issue_comment_url":"https://api.github.com/repos/escopecz/mautic/issues/comments{/number}","contents_url":"https://api.github.com/repos/escopecz/mautic/contents/{+path}","compare_url":"https://api.github.com/repos/escopecz/mautic/compare/{base}...{head}","merges_url":"https://api.github.com/repos/escopecz/mautic/merges","archive_url":"https://api.github.com/repos/escopecz/mautic/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/escopecz/mautic/downloads","issues_url":"https://api.github.com/repos/escopecz/mautic/issues{/number}","pulls_url":"https://api.github.com/repos/escopecz/mautic/pulls{/number}","milestones_url":"https://api.github.com/repos/escopecz/mautic/milestones{/number}","notifications_url":"https://api.github.com/repos/escopecz/mautic/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/escopecz/mautic/labels{/name}","releases_url":"https://api.github.com/repos/escopecz/mautic/releases{/id}","created_at":"2015-02-23T09:52:24Z","updated_at":"2015-03-09T14:56:38Z","pushed_at":"2015-12-03T16:28:08Z","git_url":"git://github.com/escopecz/mautic.git","ssh_url":"git@github.com:escopecz/mautic.git","clone_url":"https://github.com/escopecz/mautic.git","svn_url":"https://github.com/escopecz/mautic","homepage":"http://mautic.org","size":31574,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"mautic:staging","ref":"staging","sha":"1ea413a6a63bf3827d0c86268ccba244f91c6303","user":{"login":"mautic","id":5257677,"avatar_url":"https://avatars.githubusercontent.com/u/5257677?v=3","gravatar_id":"","url":"https://api.github.com/users/mautic","html_url":"https://github.com/mautic","followers_url":"https://api.github.com/users/mautic/followers","following_url":"https://api.github.com/users/mautic/following{/other_user}","gists_url":"https://api.github.com/users/mautic/gists{/gist_id}","starred_url":"https://api.github.com/users/mautic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mautic/subscriptions","organizations_url":"https://api.github.com/users/mautic/orgs","repos_url":"https://api.github.com/users/mautic/repos","events_url":"https://api.github.com/users/mautic/events{/privacy}","received_events_url":"https://api.github.com/users/mautic/received_events","type":"Organization","site_admin":false},"repo":{"id":12204147,"name":"mautic","full_name":"mautic/mautic","owner":{"login":"mautic","id":5257677,"avatar_url":"https://avatars.githubusercontent.com/u/5257677?v=3","gravatar_id":"","url":"https://api.github.com/users/mautic","html_url":"https://github.com/mautic","followers_url":"https://api.github.com/users/mautic/followers","following_url":"https://api.github.com/users/mautic/following{/other_user}","gists_url":"https://api.github.com/users/mautic/gists{/gist_id}","starred_url":"https://api.github.com/users/mautic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mautic/subscriptions","organizations_url":"https://api.github.com/users/mautic/orgs","repos_url":"https://api.github.com/users/mautic/repos","events_url":"https://api.github.com/users/mautic/events{/privacy}","received_events_url":"https://api.github.com/users/mautic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mautic/mautic","description":"Mautic: Open Source Marketing Automation Software.","fork":false,"url":"https://api.github.com/repos/mautic/mautic","forks_url":"https://api.github.com/repos/mautic/mautic/forks","keys_url":"https://api.github.com/repos/mautic/mautic/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mautic/mautic/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mautic/mautic/teams","hooks_url":"https://api.github.com/repos/mautic/mautic/hooks","issue_events_url":"https://api.github.com/repos/mautic/mautic/issues/events{/number}","events_url":"https://api.github.com/repos/mautic/mautic/events","assignees_url":"https://api.github.com/repos/mautic/mautic/assignees{/user}","branches_url":"https://api.github.com/repos/mautic/mautic/branches{/branch}","tags_url":"https://api.github.com/repos/mautic/mautic/tags","blobs_url":"https://api.github.com/repos/mautic/mautic/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mautic/mautic/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mautic/mautic/git/refs{/sha}","trees_url":"https://api.github.com/repos/mautic/mautic/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mautic/mautic/statuses/{sha}","languages_url":"https://api.github.com/repos/mautic/mautic/languages","stargazers_url":"https://api.github.com/repos/mautic/mautic/stargazers","contributors_url":"https://api.github.com/repos/mautic/mautic/contributors","subscribers_url":"https://api.github.com/repos/mautic/mautic/subscribers","subscription_url":"https://api.github.com/repos/mautic/mautic/subscription","commits_url":"https://api.github.com/repos/mautic/mautic/commits{/sha}","git_commits_url":"https://api.github.com/repos/mautic/mautic/git/commits{/sha}","comments_url":"https://api.github.com/repos/mautic/mautic/comments{/number}","issue_comment_url":"https://api.github.com/repos/mautic/mautic/issues/comments{/number}","contents_url":"https://api.github.com/repos/mautic/mautic/contents/{+path}","compare_url":"https://api.github.com/repos/mautic/mautic/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mautic/mautic/merges","archive_url":"https://api.github.com/repos/mautic/mautic/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mautic/mautic/downloads","issues_url":"https://api.github.com/repos/mautic/mautic/issues{/number}","pulls_url":"https://api.github.com/repos/mautic/mautic/pulls{/number}","milestones_url":"https://api.github.com/repos/mautic/mautic/milestones{/number}","notifications_url":"https://api.github.com/repos/mautic/mautic/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mautic/mautic/labels{/name}","releases_url":"https://api.github.com/repos/mautic/mautic/releases{/id}","created_at":"2013-08-19T00:36:28Z","updated_at":"2015-12-04T04:39:23Z","pushed_at":"2015-12-04T07:18:30Z","git_url":"git://github.com/mautic/mautic.git","ssh_url":"git@github.com:mautic/mautic.git","clone_url":"https://github.com/mautic/mautic.git","svn_url":"https://github.com/mautic/mautic","homepage":"https://www.mautic.org","size":47233,"stargazers_count":432,"watchers_count":432,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":148,"mirror_url":null,"open_issues_count":318,"forks":148,"open_issues":318,"watchers":432,"default_branch":"staging"}},"_links":{"self":{"href":"https://api.github.com/repos/mautic/mautic/pulls/1214"},"html":{"href":"https://github.com/mautic/mautic/pull/1214"},"issue":{"href":"https://api.github.com/repos/mautic/mautic/issues/1214"},"comments":{"href":"https://api.github.com/repos/mautic/mautic/issues/1214/comments"},"review_comments":{"href":"https://api.github.com/repos/mautic/mautic/pulls/1214/comments"},"review_comment":{"href":"https://api.github.com/repos/mautic/mautic/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mautic/mautic/pulls/1214/commits"},"statuses":{"href":"https://api.github.com/repos/mautic/mautic/statuses/6df825614af99966c4e6d0de4cfc5486d471e13e"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":2,"review_comments":0,"commits":1,"additions":5,"deletions":6,"changed_files":1}}