Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding button to download dataset as CSV #184

Merged
merged 2 commits into from
Oct 29, 2023

Conversation

bazzyadb
Copy link
Contributor

@bazzyadb bazzyadb commented Oct 28, 2023

Description

  • Adding button to directly download dataset as CSV

  • Only showing button once user selects a dataset

  • Using streamlit download button to download the dataset

  • Showing success prompt once user clicks on download button

  • Relevant Issues : Issue 171

  • Type of change :

    • New feature
    • Bug fix for existing feature
    • Code quality improvement
    • Addition or Improvement of tests
    • Addition or Improvement of documentation

Adding button to directly download dataset as CSV
@@ -98,6 +101,9 @@ def style_page():
"""
streamlit.markdown(style, unsafe_allow_html=True)

def showDownloadMessage():
streamlit.success("Downloading dataset to system")
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we put the message as "Your dataset has been saved"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated message

@@ -47,6 +47,9 @@ def handle_dataset_search():
repository_url = data["fullurl"]
df = pd.read_csv(repository_url)
streamlit.data_editor(df)
streamlit.download_button(
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we check if we edit the dataset and then download are the changes retained?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It won't retain the changes but we can modify this to retain the changes if required.

Copy link
Contributor

Choose a reason for hiding this comment

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

Merging this, can you open a new issue and work on saving the in memory CSV file

Updating download success prompt
@stationeros stationeros merged commit 8713fec into intuit:master Oct 29, 2023
2 checks passed
@stationeros
Copy link
Contributor

@bazzyadb Please star the repo for showing us some support as well

@bazzyadb
Copy link
Contributor Author

bazzyadb commented Oct 31, 2023

@stationeros @namitad Can one of you please add hacktoberfest and hacktoberfest-accepted labels to this pull request?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants