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

FIX: Query downloads were being passed an incorrect query object. #359

Merged
merged 1 commit into from
Feb 13, 2025

Conversation

pento
Copy link
Member

@pento pento commented Feb 13, 2025

✨ What's This?

This is a follow-up to #356.

The previous PR missed changing the name of the query object when passing it to QueryResultsWrapper, which resulted in the download links not working properly after a query was run.

This change fixes that bug, and includes an acceptance test to ensure it stays fixed during future work on this plugin.

👑 Testing

  • Visit /admin/plugins/explorer
  • Click on any query.
  • Click the Run button.
  • Click the CSV and JSON buttons, make sure the download happens as expected.

@pento pento self-assigned this Feb 13, 2025

await click("form.query-run button");

const createElement = document.createElement.bind(document);
Copy link
Contributor

Choose a reason for hiding this comment

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

Personally I would have written this as a system spec to avoid needing to do all these mocks and stubs, but it's cool you got it to work this way 👍

@pento pento merged commit c13e79d into main Feb 13, 2025
6 checks passed
@pento pento deleted the pento/fix-query-downloads branch February 13, 2025 23:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants