{"action":"created","issue":{"url":"https://api.github.com/repos/google/ggrc-core/issues/7588","repository_url":"https://api.github.com/repos/google/ggrc-core","labels_url":"https://api.github.com/repos/google/ggrc-core/issues/7588/labels{/name}","comments_url":"https://api.github.com/repos/google/ggrc-core/issues/7588/comments","events_url":"https://api.github.com/repos/google/ggrc-core/issues/7588/events","html_url":"https://github.com/google/ggrc-core/pull/7588","id":310479446,"number":7588,"title":"GGRC-4714 Hide \"Clone Audit\" button if it is not allowed to update program","user":{"login":"Klim711","id":10946494,"avatar_url":"https://avatars1.githubusercontent.com/u/10946494?v=4","gravatar_id":"","url":"https://api.github.com/users/Klim711","html_url":"https://github.com/Klim711","followers_url":"https://api.github.com/users/Klim711/followers","following_url":"https://api.github.com/users/Klim711/following{/other_user}","gists_url":"https://api.github.com/users/Klim711/gists{/gist_id}","starred_url":"https://api.github.com/users/Klim711/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Klim711/subscriptions","organizations_url":"https://api.github.com/users/Klim711/orgs","repos_url":"https://api.github.com/users/Klim711/repos","events_url":"https://api.github.com/users/Klim711/events{/privacy}","received_events_url":"https://api.github.com/users/Klim711/received_events","type":"User","site_admin":false},"labels":[{"id":653911749,"url":"https://api.github.com/repos/google/ggrc-core/labels/cla:%20yes","name":"cla: yes","color":"ededed","default":false},{"id":352278423,"url":"https://api.github.com/repos/google/ggrc-core/labels/on%20hold","name":"on hold","color":"d93f0b","default":false}],"state":"open","locked":false,"assignee":{"login":"tor4","id":3773902,"avatar_url":"https://avatars2.githubusercontent.com/u/3773902?v=4","gravatar_id":"","url":"https://api.github.com/users/tor4","html_url":"https://github.com/tor4","followers_url":"https://api.github.com/users/tor4/followers","following_url":"https://api.github.com/users/tor4/following{/other_user}","gists_url":"https://api.github.com/users/tor4/gists{/gist_id}","starred_url":"https://api.github.com/users/tor4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tor4/subscriptions","organizations_url":"https://api.github.com/users/tor4/orgs","repos_url":"https://api.github.com/users/tor4/repos","events_url":"https://api.github.com/users/tor4/events{/privacy}","received_events_url":"https://api.github.com/users/tor4/received_events","type":"User","site_admin":false},"assignees":[{"login":"tor4","id":3773902,"avatar_url":"https://avatars2.githubusercontent.com/u/3773902?v=4","gravatar_id":"","url":"https://api.github.com/users/tor4","html_url":"https://github.com/tor4","followers_url":"https://api.github.com/users/tor4/followers","following_url":"https://api.github.com/users/tor4/following{/other_user}","gists_url":"https://api.github.com/users/tor4/gists{/gist_id}","starred_url":"https://api.github.com/users/tor4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tor4/subscriptions","organizations_url":"https://api.github.com/users/tor4/orgs","repos_url":"https://api.github.com/users/tor4/repos","events_url":"https://api.github.com/users/tor4/events{/privacy}","received_events_url":"https://api.github.com/users/tor4/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/google/ggrc-core/milestones/82","html_url":"https://github.com/google/ggrc-core/milestone/82","labels_url":"https://api.github.com/repos/google/ggrc-core/milestones/82/labels","id":3216634,"number":82,"title":"1.8.0-Strawberry","description":"","creator":{"login":"alieh-rymasheuski","id":9883236,"avatar_url":"https://avatars2.githubusercontent.com/u/9883236?v=4","gravatar_id":"","url":"https://api.github.com/users/alieh-rymasheuski","html_url":"https://github.com/alieh-rymasheuski","followers_url":"https://api.github.com/users/alieh-rymasheuski/followers","following_url":"https://api.github.com/users/alieh-rymasheuski/following{/other_user}","gists_url":"https://api.github.com/users/alieh-rymasheuski/gists{/gist_id}","starred_url":"https://api.github.com/users/alieh-rymasheuski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alieh-rymasheuski/subscriptions","organizations_url":"https://api.github.com/users/alieh-rymasheuski/orgs","repos_url":"https://api.github.com/users/alieh-rymasheuski/repos","events_url":"https://api.github.com/users/alieh-rymasheuski/events{/privacy}","received_events_url":"https://api.github.com/users/alieh-rymasheuski/received_events","type":"User","site_admin":false},"open_issues":42,"closed_issues":42,"state":"open","created_at":"2018-03-26T10:09:35Z","updated_at":"2018-04-02T13:03:57Z","due_on":null,"closed_at":null},"comments":0,"created_at":"2018-04-02T13:03:57Z","updated_at":"2018-04-02T13:44:08Z","closed_at":null,"author_association":"COLLABORATOR","pull_request":{"url":"https://api.github.com/repos/google/ggrc-core/pulls/7588","html_url":"https://github.com/google/ggrc-core/pull/7588","diff_url":"https://github.com/google/ggrc-core/pull/7588.diff","patch_url":"https://github.com/google/ggrc-core/pull/7588.patch"},"body":"<!-- If your PR depends on other tickets or PRs, you can list them here\r\n# Dependencies\r\n\r\nThis PR is `on hold` until the dependencies are merged:\r\n\r\n- [ ] GGRC-1234\r\n- [ ] #1234\r\n-->\r\n\r\n# Issue description\r\n\r\nAudit captain can see 'Clone Audit' button although he has no rights to modify program. As result, if he tries to clone it, he will get an permission error.\r\n\r\n# Steps to test the changes\r\n\r\nSteps to reproduce:\r\n1. Log as Global Creator user and create a program\r\n2. Create an audit\r\n3. Remove Global Creator as a program manager and assign another user\r\n4. As Global Creator (Audit Captain) try to clone Audit\r\n\r\nActual result:  User as an Audit captain is not able to clone Audit if such a user is removed as program manager. GET 403 error is shown\r\n\r\n# Solution description\r\n\r\nHide \"Audit Clone\" button if user has no rights to modify program:\r\nAdd check `{{#is_allowed 'update' program context='for'}}` on button.\r\n\r\n# Sanity checklist\r\n\r\n- [x] I have clicked through the app to make sure my changes work and not break the app.\r\n- [x] I have applied the correct milestone and labels.\r\n- [x] My changes fix the issue described in the description (and do nothing else). 🤞\r\n- [ ] My changes are covered by tests.\r\n- [ ] My changes follow our [performance guidelines](https://github.com/google/ggrc-core/blob/dev/docs/source/contributing/performance.rst).\r\n- [ ] My changes follow our [js](https://github.com/google/ggrc-core/blob/dev/docs/source/contributing/javascript.rst) and/or [python](https://github.com/google/ggrc-core/blob/dev/docs/source/contributing/python.rst) guidelines.\r\n- [x] My commits follow our [commit guidelines](https://github.com/google/ggrc-core/blob/dev/docs/source/contributing/git/how_to_write_a_commit_message.rst).\r\n\r\n<!-- If your PR includes a migration include the additional checklist items\r\n# Migration checklist\r\n- [ ] Migration passes all checks from our [PR review guidelines](https://github.com/google/ggrc-core/blob/dev/docs/source/contributing/git/reviewing_pull_requests.rst#reviewing-a-pr-containing-database-migration-scripts)\r\n-->\r\n\r\n# PR Review checklist\r\n\r\n- [ ] The changes fix the issue and don't cause any apparent regressions.\r\n- [ ] Labels and milestone are correctly set.\r\n- [ ] The solution description matches the changes in the code.\r\n- [ ] There is no apparent way to improve the performance & design of the new code.\r\n- [ ] The pull request is opened against the correct base branch.\r\n- [ ] Upon merging, the Jira ticket's fixversion is correctly set and the ticket is moved to \"QA - In Progress\".\r\n\r\n<!-- If your code is not finished yet can include a TODO check list\r\n# TODO\r\n\r\n- [ ] First item on the TODO\r\n-->\r\n"},"comment":{"url":"https://api.github.com/repos/google/ggrc-core/issues/comments/377931858","html_url":"https://github.com/google/ggrc-core/pull/7588#issuecomment-377931858","issue_url":"https://api.github.com/repos/google/ggrc-core/issues/7588","id":377931858,"user":{"login":"Klim711","id":10946494,"avatar_url":"https://avatars1.githubusercontent.com/u/10946494?v=4","gravatar_id":"","url":"https://api.github.com/users/Klim711","html_url":"https://github.com/Klim711","followers_url":"https://api.github.com/users/Klim711/followers","following_url":"https://api.github.com/users/Klim711/following{/other_user}","gists_url":"https://api.github.com/users/Klim711/gists{/gist_id}","starred_url":"https://api.github.com/users/Klim711/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Klim711/subscriptions","organizations_url":"https://api.github.com/users/Klim711/orgs","repos_url":"https://api.github.com/users/Klim711/repos","events_url":"https://api.github.com/users/Klim711/events{/privacy}","received_events_url":"https://api.github.com/users/Klim711/received_events","type":"User","site_admin":false},"created_at":"2018-04-02T13:44:08Z","updated_at":"2018-04-02T13:44:08Z","author_association":"COLLABORATOR","body":"On hold, need to clarify requirements."}}
{"actor":{"display_login":"Klim711"}}