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

feat: allow exporting all tabs to a single PDF in report #30694

Merged
merged 9 commits into from
Nov 4, 2024

Conversation

US579
Copy link
Contributor

@US579 US579 commented Oct 23, 2024

SUMMARY

This update will give user an option to export all tabs if there are more then one in a dashboard, all tabs will be included in a single PDF document

ANIMATED GIF

output10

BEFORE/AFTER SCREENSHOTS

Before user could only include one tab into a PDF report

Screenshot 2024-10-24 at 10 54 02 am

example output:

1_ FCC New Coder Survey 2018 (1).pdf

After user could choose to include all tabs to their report

Screenshot 2024-10-24 at 10 53 04 am

example output:
1_ FCC New Coder Survey 2018.pdf

NOTE: This feature can also be modified to include specific tabs in the email, but it would require changes on the frontend (allow users to select multiple tabs).

TESTING INSTRUCTIONS

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags: this need to enable feature flag: ALERT_REPORT_TABS
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

@US579 US579 changed the title feat(wip): allow exporting all tabs to a single PDF feat(wip): allow exporting all tabs to a single PDF in report Oct 23, 2024
@dosubot dosubot bot added the alert-reports Namespace | Anything related to the Alert & Reports feature label Oct 23, 2024
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Congrats on making your first PR and thank you for contributing to Superset! 🎉 ❤️

We hope to see you in our Slack community too! Not signed up? Use our Slack App to self-register.

@US579 US579 force-pushed the feat-exporting-from-multiple-tabs branch from 7965b6a to 82bc99d Compare October 23, 2024 23:39
@US579 US579 force-pushed the feat-exporting-from-multiple-tabs branch from 82bc99d to 7685a15 Compare October 23, 2024 23:42
@geido geido self-requested a review October 24, 2024 09:42
@US579 US579 changed the title feat(wip): allow exporting all tabs to a single PDF in report feat: allow exporting all tabs to a single PDF in report Oct 24, 2024
Copy link

codecov bot commented Oct 24, 2024

Codecov Report

Attention: Patch coverage is 79.59184% with 10 lines in your changes missing coverage. Please review.

Project coverage is 70.77%. Comparing base (76d897e) to head (36dc62a).
Report is 921 commits behind head on master.

Files with missing lines Patch % Lines
...-frontend/src/features/alerts/AlertReportModal.tsx 9.09% 9 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           master   #30694       +/-   ##
===========================================
+ Coverage   60.48%   70.77%   +10.29%     
===========================================
  Files        1931     1987       +56     
  Lines       76236    80260     +4024     
  Branches     8568     9171      +603     
===========================================
+ Hits        46114    56808    +10694     
+ Misses      28017    21221     -6796     
- Partials     2105     2231      +126     
Flag Coverage Δ
hive ?
javascript 58.60% <9.09%> (+0.88%) ⬆️
mysql 76.75% <94.73%> (?)
postgres 76.87% <94.73%> (?)
presto 53.38% <10.52%> (-0.43%) ⬇️
python 83.82% <100.00%> (+20.33%) ⬆️
sqlite 76.32% <94.73%> (?)
unit 60.91% <42.10%> (+3.29%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rusackas
Copy link
Member

Running CI again... let me know if you want me to keep clicking the button, or if you have tests running locally ;)

@US579
Copy link
Contributor Author

US579 commented Oct 28, 2024

Running CI again... let me know if you want me to keep clicking the button, or if you have tests running locally ;)

ah sorry my bad, should have run all the tests

@eschutho
Copy link
Member

/testenv up FEATURE_ALERT_REPORTS=True FEATURE_ALERT_REPORT_TABS = True

Copy link
Member

@eschutho eschutho left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks @US579!

Copy link
Contributor

@eschutho Ephemeral environment spinning up at http://35.163.133.83:8080. Credentials are admin/admin. Please allow several minutes for bootstrapping and startup.

@eschutho eschutho merged commit 29e3f4b into apache:master Nov 4, 2024
38 checks passed
Copy link
Contributor

github-actions bot commented Nov 4, 2024

Ephemeral environment shutdown and build artifacts deleted.

@US579 US579 deleted the feat-exporting-from-multiple-tabs branch November 4, 2024 04:39
@yousoph
Copy link
Member

yousoph commented Nov 4, 2024

Hi @US579 ! Thanks for adding this feature :)

We noticed that the all tabs export doesn't seem to export the tabs in any specific order (our report with 3 tabs exported with tab 2, then 3, then 1 in the PDF). Would you be open to making an enhancement to export the tabs in the order they appear in the dashboard?

Thanks!

@US579
Copy link
Contributor Author

US579 commented Nov 5, 2024

thanks for the feedback @yousoph ! yep i will take a look and get back to you

@US579 US579 mentioned this pull request Nov 10, 2024
9 tasks
@US579
Copy link
Contributor Author

US579 commented Nov 10, 2024

Hi @US579 ! Thanks for adding this feature :)

We noticed that the all tabs export doesn't seem to export the tabs in any specific order (our report with 3 tabs exported with tab 2, then 3, then 1 in the PDF). Would you be open to making an enhancement to export the tabs in the order they appear in the dashboard?

Thanks!

thanks for the feedback again! I have created an MR for fixing the order issue here
#30888

@lihan
Copy link

lihan commented Nov 26, 2024

Can we get this into a stable release?

ihoskovecpetr pushed a commit to CoverGenius/superset that referenced this pull request Jan 2, 2025
nyohasstium pushed a commit to Webgains/superset that referenced this pull request Jan 2, 2025
betodealmeida pushed a commit that referenced this pull request Jan 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
alert-reports Namespace | Anything related to the Alert & Reports feature size/XXL
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants