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

[TASK-884] Implement reusable export button #5191

Merged
merged 9 commits into from
Oct 30, 2024

Conversation

pauloamorimbr
Copy link
Contributor

Task

Checklist

  1. If you've added code that should be tested, add tests
  2. If you've changed APIs, update (or create!) the documentation
  3. Ensure the tests pass
  4. Run ./python-format.sh to make sure that your code lints and that you've followed our coding style
  5. Write a title and, if necessary, a description of your work suitable for publishing in our release notes
  6. Mention any related issues in this repository (as #ISSUE) and in other repositories (as kobotoolbox/other#ISSUE)
  7. Open an issue in the docs if there are UI/UX changes
  8. Create a testing plan for the reviewer and add it to the Testing section

Description

This PR implements the functionality for the export button.

  • Actual export function is mocked and will not generate any data
  • The mocked results now have a 50% chance of failure for testing purposes

Notes

  • A new "ExportButton" component was created.
  • It receives an async function to be called when clicked
  • If the export process is successfully started it will display a message to the user
  • If an error occurs, alertify is used to display an error message

Testing

  • Access the project settings
  • Be sure to have the ?ff_activityLogsEnabled=true feature flag on
  • Access the Activity sub view
  • Click the export button some times.
  • It should display the successful or error message depending on the (random) result.

Copy link

Copy link

@pauloamorimbr pauloamorimbr force-pushed the task-884-implement-reusable-export-button branch from cd9a7f1 to 69b1102 Compare October 24, 2024 12:30
@pauloamorimbr pauloamorimbr force-pushed the task-884-implement-reusable-export-button branch from a15f130 to bb5d422 Compare October 30, 2024 18:38
@pauloamorimbr pauloamorimbr merged commit a2c4ca0 into main Oct 30, 2024
7 checks passed
@pauloamorimbr pauloamorimbr deleted the task-884-implement-reusable-export-button branch October 30, 2024 20:41
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.

3 participants