Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Download Excel Data #1293

Merged
merged 3 commits into from Mar 31, 2021
Merged

Download Excel Data #1293

merged 3 commits into from Mar 31, 2021

Conversation

TaiWilkin
Copy link
Contributor

@TaiWilkin TaiWilkin commented Mar 30, 2021

Overview

Allows users to download the facilities list as an .xlsx file, in addition to .csv.

Connects #955

Demo

Screen Shot 2021-03-30 at 10 17 39 AM

Testing Instructions

  • vagrant ssh and run ./scripts/update
  • Run ./scripts/server
  • Navigate to :6543 and click 'download'
    • You should see a dropdown with CSV and Excel
  • Click Excel
    • An XLSX file of the data should be downloaded

Checklist

  • fixup! commits have been squashed
  • CI passes after rebase
  • CHANGELOG.md updated with summary of features or fixes, following Keep a Changelog guidelines

@jwalgran
Copy link
Contributor

Looking at this now.

Copy link
Contributor

@jwalgran jwalgran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works perfectly. I verified CSV download still works and then downloaded facilities from Turkey as an XLSX, which often have unicode characters in names and addresses. I was able to open and view the XLSX in LibreOffice, Numbers, and Google Sheets and see the unicode characters correctly.

src/app/src/components/DownloadFacilitiesButton.jsx Outdated Show resolved Hide resolved
src/app/src/util/util.js Outdated Show resolved Hide resolved
@jwalgran jwalgran assigned TaiWilkin and unassigned jwalgran Mar 30, 2021
Moves the download button from the two files in which it appears
into a single component, in order to more easily update the code
to allow .xlsx downloads.
Switch the download button to a dropdown menu, and allow users to
choose between XLSX and CSV format.
@TaiWilkin
Copy link
Contributor Author

Thanks for the review!

@TaiWilkin TaiWilkin merged commit 5df0f8c into develop Mar 31, 2021
@TaiWilkin TaiWilkin deleted the tw/download-excel-data branch March 31, 2021 16:20
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants