{"action":"created","comment":{"url":"https://api.github.com/repos/openregister/registers-frontend/pulls/comments/233862225","pull_request_review_id":175365018,"id":233862225,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMzg2MjIyNQ==","diff_hunk":"@@ -19,6 +19,14 @@ def download_format(format)\n     end\n   end\n \n+  def download_ods\n+    headers = register.fields_array\n+    data = register.records.where(entry_type: 'user').find_each.map do |r|\n+      headers.map { |f| r.data[f] }\n+    end\n+    SpreadsheetArchitect.to_ods(headers: headers, data: data)","path":"app/services/register_records_downloader.rb","position":9,"original_position":9,"commit_id":"df2a82482204a846e956d38b928ba69dc93c29eb","original_commit_id":"02c413a55ee905c70d1e024e4c7bfe8155b77525","user":{"login":"MatMoore","id":87579,"node_id":"MDQ6VXNlcjg3NTc5","avatar_url":"https://avatars1.githubusercontent.com/u/87579?v=4","gravatar_id":"","url":"https://api.github.com/users/MatMoore","html_url":"https://github.com/MatMoore","followers_url":"https://api.github.com/users/MatMoore/followers","following_url":"https://api.github.com/users/MatMoore/following{/other_user}","gists_url":"https://api.github.com/users/MatMoore/gists{/gist_id}","starred_url":"https://api.github.com/users/MatMoore/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MatMoore/subscriptions","organizations_url":"https://api.github.com/users/MatMoore/orgs","repos_url":"https://api.github.com/users/MatMoore/repos","events_url":"https://api.github.com/users/MatMoore/events{/privacy}","received_events_url":"https://api.github.com/users/MatMoore/received_events","type":"User","site_admin":false},"body":"Is there anything else we want to provide in this spreadsheet? For example, a different sheet with metadata in it?","created_at":"2018-11-15T14:29:50Z","updated_at":"2018-11-15T14:34:36Z","html_url":"https://github.com/openregister/registers-frontend/pull/496#discussion_r233862225","pull_request_url":"https://api.github.com/repos/openregister/registers-frontend/pulls/496","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/openregister/registers-frontend/pulls/comments/233862225"},"html":{"href":"https://github.com/openregister/registers-frontend/pull/496#discussion_r233862225"},"pull_request":{"href":"https://api.github.com/repos/openregister/registers-frontend/pulls/496"}}},"pull_request":{"url":"https://api.github.com/repos/openregister/registers-frontend/pulls/496","id":231204608,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMxMjA0NjA4","html_url":"https://github.com/openregister/registers-frontend/pull/496","diff_url":"https://github.com/openregister/registers-frontend/pull/496.diff","patch_url":"https://github.com/openregister/registers-frontend/pull/496.patch","issue_url":"https://api.github.com/repos/openregister/registers-frontend/issues/496","number":496,"state":"open","locked":false,"title":"Offer ODS downloads ","user":{"login":"gidsg","id":1764158,"node_id":"MDQ6VXNlcjE3NjQxNTg=","avatar_url":"https://avatars0.githubusercontent.com/u/1764158?v=4","gravatar_id":"","url":"https://api.github.com/users/gidsg","html_url":"https://github.com/gidsg","followers_url":"https://api.github.com/users/gidsg/followers","following_url":"https://api.github.com/users/gidsg/following{/other_user}","gists_url":"https://api.github.com/users/gidsg/gists{/gist_id}","starred_url":"https://api.github.com/users/gidsg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gidsg/subscriptions","organizations_url":"https://api.github.com/users/gidsg/orgs","repos_url":"https://api.github.com/users/gidsg/repos","events_url":"https://api.github.com/users/gidsg/events{/privacy}","received_events_url":"https://api.github.com/users/gidsg/received_events","type":"User","site_admin":false},"body":"### Context\r\nWe need to offer ODS downloads as we are deprecating XLSX\r\n\r\n### Changes proposed in this pull request\r\nSerialize to ODS from frontend DB\r\n\r\n### Guidance to review\r\nYou should be able to download a register as ODS following the frontend download journey.\r\nStill to do on this is to implement Analytics, need spec from @cliffshepp \r\n@mpwoods should also probably look over wording.\r\n","created_at":"2018-11-15T14:01:58Z","updated_at":"2018-11-15T14:34:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"aaac2aa96f6c2baf347c1666d579df054085aa8c","assignee":null,"assignees":[],"requested_reviewers":[{"login":"injms","id":1732331,"node_id":"MDQ6VXNlcjE3MzIzMzE=","avatar_url":"https://avatars1.githubusercontent.com/u/1732331?v=4","gravatar_id":"","url":"https://api.github.com/users/injms","html_url":"https://github.com/injms","followers_url":"https://api.github.com/users/injms/followers","following_url":"https://api.github.com/users/injms/following{/other_user}","gists_url":"https://api.github.com/users/injms/gists{/gist_id}","starred_url":"https://api.github.com/users/injms/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/injms/subscriptions","organizations_url":"https://api.github.com/users/injms/orgs","repos_url":"https://api.github.com/users/injms/repos","events_url":"https://api.github.com/users/injms/events{/privacy}","received_events_url":"https://api.github.com/users/injms/received_events","type":"User","site_admin":false},{"login":"mpwoods","id":33098366,"node_id":"MDQ6VXNlcjMzMDk4MzY2","avatar_url":"https://avatars3.githubusercontent.com/u/33098366?v=4","gravatar_id":"","url":"https://api.github.com/users/mpwoods","html_url":"https://github.com/mpwoods","followers_url":"https://api.github.com/users/mpwoods/followers","following_url":"https://api.github.com/users/mpwoods/following{/other_user}","gists_url":"https://api.github.com/users/mpwoods/gists{/gist_id}","starred_url":"https://api.github.com/users/mpwoods/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mpwoods/subscriptions","organizations_url":"https://api.github.com/users/mpwoods/orgs","repos_url":"https://api.github.com/users/mpwoods/repos","events_url":"https://api.github.com/users/mpwoods/events{/privacy}","received_events_url":"https://api.github.com/users/mpwoods/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/openregister/registers-frontend/pulls/496/commits","review_comments_url":"https://api.github.com/repos/openregister/registers-frontend/pulls/496/comments","review_comment_url":"https://api.github.com/repos/openregister/registers-frontend/pulls/comments{/number}","comments_url":"https://api.github.com/repos/openregister/registers-frontend/issues/496/comments","statuses_url":"https://api.github.com/repos/openregister/registers-frontend/statuses/df2a82482204a846e956d38b928ba69dc93c29eb","head":{"label":"openregister:ods","ref":"ods","sha":"df2a82482204a846e956d38b928ba69dc93c29eb","user":{"login":"openregister","id":10206003,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMjA2MDAz","avatar_url":"https://avatars1.githubusercontent.com/u/10206003?v=4","gravatar_id":"","url":"https://api.github.com/users/openregister","html_url":"https://github.com/openregister","followers_url":"https://api.github.com/users/openregister/followers","following_url":"https://api.github.com/users/openregister/following{/other_user}","gists_url":"https://api.github.com/users/openregister/gists{/gist_id}","starred_url":"https://api.github.com/users/openregister/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openregister/subscriptions","organizations_url":"https://api.github.com/users/openregister/orgs","repos_url":"https://api.github.com/users/openregister/repos","events_url":"https://api.github.com/users/openregister/events{/privacy}","received_events_url":"https://api.github.com/users/openregister/received_events","type":"Organization","site_admin":false},"repo":{"id":79900152,"node_id":"MDEwOlJlcG9zaXRvcnk3OTkwMDE1Mg==","name":"registers-frontend","full_name":"openregister/registers-frontend","private":false,"owner":{"login":"openregister","id":10206003,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMjA2MDAz","avatar_url":"https://avatars1.githubusercontent.com/u/10206003?v=4","gravatar_id":"","url":"https://api.github.com/users/openregister","html_url":"https://github.com/openregister","followers_url":"https://api.github.com/users/openregister/followers","following_url":"https://api.github.com/users/openregister/following{/other_user}","gists_url":"https://api.github.com/users/openregister/gists{/gist_id}","starred_url":"https://api.github.com/users/openregister/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openregister/subscriptions","organizations_url":"https://api.github.com/users/openregister/orgs","repos_url":"https://api.github.com/users/openregister/repos","events_url":"https://api.github.com/users/openregister/events{/privacy}","received_events_url":"https://api.github.com/users/openregister/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/openregister/registers-frontend","description":"GOV.UK Registers Frontend","fork":false,"url":"https://api.github.com/repos/openregister/registers-frontend","forks_url":"https://api.github.com/repos/openregister/registers-frontend/forks","keys_url":"https://api.github.com/repos/openregister/registers-frontend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openregister/registers-frontend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openregister/registers-frontend/teams","hooks_url":"https://api.github.com/repos/openregister/registers-frontend/hooks","issue_events_url":"https://api.github.com/repos/openregister/registers-frontend/issues/events{/number}","events_url":"https://api.github.com/repos/openregister/registers-frontend/events","assignees_url":"https://api.github.com/repos/openregister/registers-frontend/assignees{/user}","branches_url":"https://api.github.com/repos/openregister/registers-frontend/branches{/branch}","tags_url":"https://api.github.com/repos/openregister/registers-frontend/tags","blobs_url":"https://api.github.com/repos/openregister/registers-frontend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openregister/registers-frontend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openregister/registers-frontend/git/refs{/sha}","trees_url":"https://api.github.com/repos/openregister/registers-frontend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openregister/registers-frontend/statuses/{sha}","languages_url":"https://api.github.com/repos/openregister/registers-frontend/languages","stargazers_url":"https://api.github.com/repos/openregister/registers-frontend/stargazers","contributors_url":"https://api.github.com/repos/openregister/registers-frontend/contributors","subscribers_url":"https://api.github.com/repos/openregister/registers-frontend/subscribers","subscription_url":"https://api.github.com/repos/openregister/registers-frontend/subscription","commits_url":"https://api.github.com/repos/openregister/registers-frontend/commits{/sha}","git_commits_url":"https://api.github.com/repos/openregister/registers-frontend/git/commits{/sha}","comments_url":"https://api.github.com/repos/openregister/registers-frontend/comments{/number}","issue_comment_url":"https://api.github.com/repos/openregister/registers-frontend/issues/comments{/number}","contents_url":"https://api.github.com/repos/openregister/registers-frontend/contents/{+path}","compare_url":"https://api.github.com/repos/openregister/registers-frontend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openregister/registers-frontend/merges","archive_url":"https://api.github.com/repos/openregister/registers-frontend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openregister/registers-frontend/downloads","issues_url":"https://api.github.com/repos/openregister/registers-frontend/issues{/number}","pulls_url":"https://api.github.com/repos/openregister/registers-frontend/pulls{/number}","milestones_url":"https://api.github.com/repos/openregister/registers-frontend/milestones{/number}","notifications_url":"https://api.github.com/repos/openregister/registers-frontend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openregister/registers-frontend/labels{/name}","releases_url":"https://api.github.com/repos/openregister/registers-frontend/releases{/id}","deployments_url":"https://api.github.com/repos/openregister/registers-frontend/deployments","created_at":"2017-01-24T10:11:12Z","updated_at":"2018-11-12T11:33:07Z","pushed_at":"2018-11-15T14:33:10Z","git_url":"git://github.com/openregister/registers-frontend.git","ssh_url":"git@github.com:openregister/registers-frontend.git","clone_url":"https://github.com/openregister/registers-frontend.git","svn_url":"https://github.com/openregister/registers-frontend","homepage":"https://www.registers.service.gov.uk/","size":3497,"stargazers_count":3,"watchers_count":3,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":15,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":1,"open_issues":15,"watchers":3,"default_branch":"master"}},"base":{"label":"openregister:master","ref":"master","sha":"dd688d98ff91137233147a75b24570c87668b91f","user":{"login":"openregister","id":10206003,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMjA2MDAz","avatar_url":"https://avatars1.githubusercontent.com/u/10206003?v=4","gravatar_id":"","url":"https://api.github.com/users/openregister","html_url":"https://github.com/openregister","followers_url":"https://api.github.com/users/openregister/followers","following_url":"https://api.github.com/users/openregister/following{/other_user}","gists_url":"https://api.github.com/users/openregister/gists{/gist_id}","starred_url":"https://api.github.com/users/openregister/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openregister/subscriptions","organizations_url":"https://api.github.com/users/openregister/orgs","repos_url":"https://api.github.com/users/openregister/repos","events_url":"https://api.github.com/users/openregister/events{/privacy}","received_events_url":"https://api.github.com/users/openregister/received_events","type":"Organization","site_admin":false},"repo":{"id":79900152,"node_id":"MDEwOlJlcG9zaXRvcnk3OTkwMDE1Mg==","name":"registers-frontend","full_name":"openregister/registers-frontend","private":false,"owner":{"login":"openregister","id":10206003,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMjA2MDAz","avatar_url":"https://avatars1.githubusercontent.com/u/10206003?v=4","gravatar_id":"","url":"https://api.github.com/users/openregister","html_url":"https://github.com/openregister","followers_url":"https://api.github.com/users/openregister/followers","following_url":"https://api.github.com/users/openregister/following{/other_user}","gists_url":"https://api.github.com/users/openregister/gists{/gist_id}","starred_url":"https://api.github.com/users/openregister/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openregister/subscriptions","organizations_url":"https://api.github.com/users/openregister/orgs","repos_url":"https://api.github.com/users/openregister/repos","events_url":"https://api.github.com/users/openregister/events{/privacy}","received_events_url":"https://api.github.com/users/openregister/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/openregister/registers-frontend","description":"GOV.UK Registers Frontend","fork":false,"url":"https://api.github.com/repos/openregister/registers-frontend","forks_url":"https://api.github.com/repos/openregister/registers-frontend/forks","keys_url":"https://api.github.com/repos/openregister/registers-frontend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openregister/registers-frontend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openregister/registers-frontend/teams","hooks_url":"https://api.github.com/repos/openregister/registers-frontend/hooks","issue_events_url":"https://api.github.com/repos/openregister/registers-frontend/issues/events{/number}","events_url":"https://api.github.com/repos/openregister/registers-frontend/events","assignees_url":"https://api.github.com/repos/openregister/registers-frontend/assignees{/user}","branches_url":"https://api.github.com/repos/openregister/registers-frontend/branches{/branch}","tags_url":"https://api.github.com/repos/openregister/registers-frontend/tags","blobs_url":"https://api.github.com/repos/openregister/registers-frontend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openregister/registers-frontend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openregister/registers-frontend/git/refs{/sha}","trees_url":"https://api.github.com/repos/openregister/registers-frontend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openregister/registers-frontend/statuses/{sha}","languages_url":"https://api.github.com/repos/openregister/registers-frontend/languages","stargazers_url":"https://api.github.com/repos/openregister/registers-frontend/stargazers","contributors_url":"https://api.github.com/repos/openregister/registers-frontend/contributors","subscribers_url":"https://api.github.com/repos/openregister/registers-frontend/subscribers","subscription_url":"https://api.github.com/repos/openregister/registers-frontend/subscription","commits_url":"https://api.github.com/repos/openregister/registers-frontend/commits{/sha}","git_commits_url":"https://api.github.com/repos/openregister/registers-frontend/git/commits{/sha}","comments_url":"https://api.github.com/repos/openregister/registers-frontend/comments{/number}","issue_comment_url":"https://api.github.com/repos/openregister/registers-frontend/issues/comments{/number}","contents_url":"https://api.github.com/repos/openregister/registers-frontend/contents/{+path}","compare_url":"https://api.github.com/repos/openregister/registers-frontend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openregister/registers-frontend/merges","archive_url":"https://api.github.com/repos/openregister/registers-frontend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openregister/registers-frontend/downloads","issues_url":"https://api.github.com/repos/openregister/registers-frontend/issues{/number}","pulls_url":"https://api.github.com/repos/openregister/registers-frontend/pulls{/number}","milestones_url":"https://api.github.com/repos/openregister/registers-frontend/milestones{/number}","notifications_url":"https://api.github.com/repos/openregister/registers-frontend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openregister/registers-frontend/labels{/name}","releases_url":"https://api.github.com/repos/openregister/registers-frontend/releases{/id}","deployments_url":"https://api.github.com/repos/openregister/registers-frontend/deployments","created_at":"2017-01-24T10:11:12Z","updated_at":"2018-11-12T11:33:07Z","pushed_at":"2018-11-15T14:33:10Z","git_url":"git://github.com/openregister/registers-frontend.git","ssh_url":"git@github.com:openregister/registers-frontend.git","clone_url":"https://github.com/openregister/registers-frontend.git","svn_url":"https://github.com/openregister/registers-frontend","homepage":"https://www.registers.service.gov.uk/","size":3497,"stargazers_count":3,"watchers_count":3,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":15,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":1,"open_issues":15,"watchers":3,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/openregister/registers-frontend/pulls/496"},"html":{"href":"https://github.com/openregister/registers-frontend/pull/496"},"issue":{"href":"https://api.github.com/repos/openregister/registers-frontend/issues/496"},"comments":{"href":"https://api.github.com/repos/openregister/registers-frontend/issues/496/comments"},"review_comments":{"href":"https://api.github.com/repos/openregister/registers-frontend/pulls/496/comments"},"review_comment":{"href":"https://api.github.com/repos/openregister/registers-frontend/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/openregister/registers-frontend/pulls/496/commits"},"statuses":{"href":"https://api.github.com/repos/openregister/registers-frontend/statuses/df2a82482204a846e956d38b928ba69dc93c29eb"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"MatMoore"}}