{"action":"created","comment":{"url":"https://api.github.com/repos/alphagov/e-petitions/pulls/comments/32716802","id":32716802,"diff_hunk":"@@ -2,7 +2,11 @@\n \n   <%= render :partial => 'petition_details', :locals => { :f => f } %>\n \n-  <div>\n+  <div class=\"row\">\n+    <%= link_to 'Edit petition content', admin_petition_petition_details_path(@petition) %>\n+  </div>","path":"app/views/admin/petitions/edit.html.erb","position":7,"original_position":7,"commit_id":"ff22b8834ec23141a34b020a6ce101fed5d91fa4","original_commit_id":"453ef29a26e1f11d85f1b57df9ecbe366a3b5249","user":{"login":"h-lame","id":608,"avatar_url":"https://avatars.githubusercontent.com/u/608?v=3","gravatar_id":"","url":"https://api.github.com/users/h-lame","html_url":"https://github.com/h-lame","followers_url":"https://api.github.com/users/h-lame/followers","following_url":"https://api.github.com/users/h-lame/following{/other_user}","gists_url":"https://api.github.com/users/h-lame/gists{/gist_id}","starred_url":"https://api.github.com/users/h-lame/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/h-lame/subscriptions","organizations_url":"https://api.github.com/users/h-lame/orgs","repos_url":"https://api.github.com/users/h-lame/repos","events_url":"https://api.github.com/users/h-lame/events{/privacy}","received_events_url":"https://api.github.com/users/h-lame/received_events","type":"User","site_admin":false},"body":"You can put a guard clause on showing the link though, so it only appears for the petitions you're allowed to edit in this way (it's what I did for the debate outcomes link).","created_at":"2015-06-18T10:30:24Z","updated_at":"2015-06-18T10:30:24Z","html_url":"https://github.com/alphagov/e-petitions/pull/154#discussion_r32716802","pull_request_url":"https://api.github.com/repos/alphagov/e-petitions/pulls/154","_links":{"self":{"href":"https://api.github.com/repos/alphagov/e-petitions/pulls/comments/32716802"},"html":{"href":"https://github.com/alphagov/e-petitions/pull/154#discussion_r32716802"},"pull_request":{"href":"https://api.github.com/repos/alphagov/e-petitions/pulls/154"}}},"pull_request":{"url":"https://api.github.com/repos/alphagov/e-petitions/pulls/154","id":37978450,"html_url":"https://github.com/alphagov/e-petitions/pull/154","diff_url":"https://github.com/alphagov/e-petitions/pull/154.diff","patch_url":"https://github.com/alphagov/e-petitions/pull/154.patch","issue_url":"https://api.github.com/repos/alphagov/e-petitions/issues/154","number":154,"state":"open","locked":false,"title":"Moderator can edit petition before publishing","user":{"login":"mybits","id":5237879,"avatar_url":"https://avatars.githubusercontent.com/u/5237879?v=3","gravatar_id":"","url":"https://api.github.com/users/mybits","html_url":"https://github.com/mybits","followers_url":"https://api.github.com/users/mybits/followers","following_url":"https://api.github.com/users/mybits/following{/other_user}","gists_url":"https://api.github.com/users/mybits/gists{/gist_id}","starred_url":"https://api.github.com/users/mybits/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mybits/subscriptions","organizations_url":"https://api.github.com/users/mybits/orgs","repos_url":"https://api.github.com/users/mybits/repos","events_url":"https://api.github.com/users/mybits/events{/privacy}","received_events_url":"https://api.github.com/users/mybits/received_events","type":"User","site_admin":false},"body":"- Style is not implemented, but a template follows the markup we're gonna use while adding new style to the admin.\r\n- After updating petition moderator is redirected to back to the petition page (not the index page)\r\n\r\nPT: https://www.pivotaltracker.com/n/projects/307301/stories/96865488","created_at":"2015-06-18T07:31:15Z","updated_at":"2015-06-18T10:30:24Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d7a88c42b79a3d2a2604b987eac38efb64782ab0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/alphagov/e-petitions/pulls/154/commits","review_comments_url":"https://api.github.com/repos/alphagov/e-petitions/pulls/154/comments","review_comment_url":"https://api.github.com/repos/alphagov/e-petitions/pulls/comments{/number}","comments_url":"https://api.github.com/repos/alphagov/e-petitions/issues/154/comments","statuses_url":"https://api.github.com/repos/alphagov/e-petitions/statuses/ff22b8834ec23141a34b020a6ce101fed5d91fa4","head":{"label":"alphagov:moderator-can-edit-petition-before-publishing","ref":"moderator-can-edit-petition-before-publishing","sha":"ff22b8834ec23141a34b020a6ce101fed5d91fa4","user":{"login":"alphagov","id":596977,"avatar_url":"https://avatars.githubusercontent.com/u/596977?v=3","gravatar_id":"","url":"https://api.github.com/users/alphagov","html_url":"https://github.com/alphagov","followers_url":"https://api.github.com/users/alphagov/followers","following_url":"https://api.github.com/users/alphagov/following{/other_user}","gists_url":"https://api.github.com/users/alphagov/gists{/gist_id}","starred_url":"https://api.github.com/users/alphagov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alphagov/subscriptions","organizations_url":"https://api.github.com/users/alphagov/orgs","repos_url":"https://api.github.com/users/alphagov/repos","events_url":"https://api.github.com/users/alphagov/events{/privacy}","received_events_url":"https://api.github.com/users/alphagov/received_events","type":"Organization","site_admin":false},"repo":{"id":4434819,"name":"e-petitions","full_name":"alphagov/e-petitions","owner":{"login":"alphagov","id":596977,"avatar_url":"https://avatars.githubusercontent.com/u/596977?v=3","gravatar_id":"","url":"https://api.github.com/users/alphagov","html_url":"https://github.com/alphagov","followers_url":"https://api.github.com/users/alphagov/followers","following_url":"https://api.github.com/users/alphagov/following{/other_user}","gists_url":"https://api.github.com/users/alphagov/gists{/gist_id}","starred_url":"https://api.github.com/users/alphagov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alphagov/subscriptions","organizations_url":"https://api.github.com/users/alphagov/orgs","repos_url":"https://api.github.com/users/alphagov/repos","events_url":"https://api.github.com/users/alphagov/events{/privacy}","received_events_url":"https://api.github.com/users/alphagov/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/alphagov/e-petitions","description":"This is the code base for the UK Government's e-petitions service (http://epetitions.direct.gov.uk)","fork":false,"url":"https://api.github.com/repos/alphagov/e-petitions","forks_url":"https://api.github.com/repos/alphagov/e-petitions/forks","keys_url":"https://api.github.com/repos/alphagov/e-petitions/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alphagov/e-petitions/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alphagov/e-petitions/teams","hooks_url":"https://api.github.com/repos/alphagov/e-petitions/hooks","issue_events_url":"https://api.github.com/repos/alphagov/e-petitions/issues/events{/number}","events_url":"https://api.github.com/repos/alphagov/e-petitions/events","assignees_url":"https://api.github.com/repos/alphagov/e-petitions/assignees{/user}","branches_url":"https://api.github.com/repos/alphagov/e-petitions/branches{/branch}","tags_url":"https://api.github.com/repos/alphagov/e-petitions/tags","blobs_url":"https://api.github.com/repos/alphagov/e-petitions/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alphagov/e-petitions/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alphagov/e-petitions/git/refs{/sha}","trees_url":"https://api.github.com/repos/alphagov/e-petitions/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alphagov/e-petitions/statuses/{sha}","languages_url":"https://api.github.com/repos/alphagov/e-petitions/languages","stargazers_url":"https://api.github.com/repos/alphagov/e-petitions/stargazers","contributors_url":"https://api.github.com/repos/alphagov/e-petitions/contributors","subscribers_url":"https://api.github.com/repos/alphagov/e-petitions/subscribers","subscription_url":"https://api.github.com/repos/alphagov/e-petitions/subscription","commits_url":"https://api.github.com/repos/alphagov/e-petitions/commits{/sha}","git_commits_url":"https://api.github.com/repos/alphagov/e-petitions/git/commits{/sha}","comments_url":"https://api.github.com/repos/alphagov/e-petitions/comments{/number}","issue_comment_url":"https://api.github.com/repos/alphagov/e-petitions/issues/comments{/number}","contents_url":"https://api.github.com/repos/alphagov/e-petitions/contents/{+path}","compare_url":"https://api.github.com/repos/alphagov/e-petitions/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alphagov/e-petitions/merges","archive_url":"https://api.github.com/repos/alphagov/e-petitions/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alphagov/e-petitions/downloads","issues_url":"https://api.github.com/repos/alphagov/e-petitions/issues{/number}","pulls_url":"https://api.github.com/repos/alphagov/e-petitions/pulls{/number}","milestones_url":"https://api.github.com/repos/alphagov/e-petitions/milestones{/number}","notifications_url":"https://api.github.com/repos/alphagov/e-petitions/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alphagov/e-petitions/labels{/name}","releases_url":"https://api.github.com/repos/alphagov/e-petitions/releases{/id}","created_at":"2012-05-24T16:04:02Z","updated_at":"2015-05-15T08:26:34Z","pushed_at":"2015-06-18T10:27:45Z","git_url":"git://github.com/alphagov/e-petitions.git","ssh_url":"git@github.com:alphagov/e-petitions.git","clone_url":"https://github.com/alphagov/e-petitions.git","svn_url":"https://github.com/alphagov/e-petitions","homepage":"http://epetitions.direct.gov.uk","size":5614,"stargazers_count":18,"watchers_count":18,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":6,"forks":10,"open_issues":6,"watchers":18,"default_branch":"master"}},"base":{"label":"alphagov:master","ref":"master","sha":"78beb77506de0c44636c5b92d01c84e0257cf9e4","user":{"login":"alphagov","id":596977,"avatar_url":"https://avatars.githubusercontent.com/u/596977?v=3","gravatar_id":"","url":"https://api.github.com/users/alphagov","html_url":"https://github.com/alphagov","followers_url":"https://api.github.com/users/alphagov/followers","following_url":"https://api.github.com/users/alphagov/following{/other_user}","gists_url":"https://api.github.com/users/alphagov/gists{/gist_id}","starred_url":"https://api.github.com/users/alphagov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alphagov/subscriptions","organizations_url":"https://api.github.com/users/alphagov/orgs","repos_url":"https://api.github.com/users/alphagov/repos","events_url":"https://api.github.com/users/alphagov/events{/privacy}","received_events_url":"https://api.github.com/users/alphagov/received_events","type":"Organization","site_admin":false},"repo":{"id":4434819,"name":"e-petitions","full_name":"alphagov/e-petitions","owner":{"login":"alphagov","id":596977,"avatar_url":"https://avatars.githubusercontent.com/u/596977?v=3","gravatar_id":"","url":"https://api.github.com/users/alphagov","html_url":"https://github.com/alphagov","followers_url":"https://api.github.com/users/alphagov/followers","following_url":"https://api.github.com/users/alphagov/following{/other_user}","gists_url":"https://api.github.com/users/alphagov/gists{/gist_id}","starred_url":"https://api.github.com/users/alphagov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alphagov/subscriptions","organizations_url":"https://api.github.com/users/alphagov/orgs","repos_url":"https://api.github.com/users/alphagov/repos","events_url":"https://api.github.com/users/alphagov/events{/privacy}","received_events_url":"https://api.github.com/users/alphagov/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/alphagov/e-petitions","description":"This is the code base for the UK Government's e-petitions service (http://epetitions.direct.gov.uk)","fork":false,"url":"https://api.github.com/repos/alphagov/e-petitions","forks_url":"https://api.github.com/repos/alphagov/e-petitions/forks","keys_url":"https://api.github.com/repos/alphagov/e-petitions/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alphagov/e-petitions/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alphagov/e-petitions/teams","hooks_url":"https://api.github.com/repos/alphagov/e-petitions/hooks","issue_events_url":"https://api.github.com/repos/alphagov/e-petitions/issues/events{/number}","events_url":"https://api.github.com/repos/alphagov/e-petitions/events","assignees_url":"https://api.github.com/repos/alphagov/e-petitions/assignees{/user}","branches_url":"https://api.github.com/repos/alphagov/e-petitions/branches{/branch}","tags_url":"https://api.github.com/repos/alphagov/e-petitions/tags","blobs_url":"https://api.github.com/repos/alphagov/e-petitions/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alphagov/e-petitions/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alphagov/e-petitions/git/refs{/sha}","trees_url":"https://api.github.com/repos/alphagov/e-petitions/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alphagov/e-petitions/statuses/{sha}","languages_url":"https://api.github.com/repos/alphagov/e-petitions/languages","stargazers_url":"https://api.github.com/repos/alphagov/e-petitions/stargazers","contributors_url":"https://api.github.com/repos/alphagov/e-petitions/contributors","subscribers_url":"https://api.github.com/repos/alphagov/e-petitions/subscribers","subscription_url":"https://api.github.com/repos/alphagov/e-petitions/subscription","commits_url":"https://api.github.com/repos/alphagov/e-petitions/commits{/sha}","git_commits_url":"https://api.github.com/repos/alphagov/e-petitions/git/commits{/sha}","comments_url":"https://api.github.com/repos/alphagov/e-petitions/comments{/number}","issue_comment_url":"https://api.github.com/repos/alphagov/e-petitions/issues/comments{/number}","contents_url":"https://api.github.com/repos/alphagov/e-petitions/contents/{+path}","compare_url":"https://api.github.com/repos/alphagov/e-petitions/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alphagov/e-petitions/merges","archive_url":"https://api.github.com/repos/alphagov/e-petitions/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alphagov/e-petitions/downloads","issues_url":"https://api.github.com/repos/alphagov/e-petitions/issues{/number}","pulls_url":"https://api.github.com/repos/alphagov/e-petitions/pulls{/number}","milestones_url":"https://api.github.com/repos/alphagov/e-petitions/milestones{/number}","notifications_url":"https://api.github.com/repos/alphagov/e-petitions/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alphagov/e-petitions/labels{/name}","releases_url":"https://api.github.com/repos/alphagov/e-petitions/releases{/id}","created_at":"2012-05-24T16:04:02Z","updated_at":"2015-05-15T08:26:34Z","pushed_at":"2015-06-18T10:27:45Z","git_url":"git://github.com/alphagov/e-petitions.git","ssh_url":"git@github.com:alphagov/e-petitions.git","clone_url":"https://github.com/alphagov/e-petitions.git","svn_url":"https://github.com/alphagov/e-petitions","homepage":"http://epetitions.direct.gov.uk","size":5614,"stargazers_count":18,"watchers_count":18,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":6,"forks":10,"open_issues":6,"watchers":18,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/alphagov/e-petitions/pulls/154"},"html":{"href":"https://github.com/alphagov/e-petitions/pull/154"},"issue":{"href":"https://api.github.com/repos/alphagov/e-petitions/issues/154"},"comments":{"href":"https://api.github.com/repos/alphagov/e-petitions/issues/154/comments"},"review_comments":{"href":"https://api.github.com/repos/alphagov/e-petitions/pulls/154/comments"},"review_comment":{"href":"https://api.github.com/repos/alphagov/e-petitions/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/alphagov/e-petitions/pulls/154/commits"},"statuses":{"href":"https://api.github.com/repos/alphagov/e-petitions/statuses/ff22b8834ec23141a34b020a6ce101fed5d91fa4"}}}}