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(alerts/reports): delete and bulk delete actions #12053

Merged
merged 5 commits into from
Dec 16, 2020

Conversation

nytai
Copy link
Member

@nytai nytai commented Dec 15, 2020

SUMMARY

  • adds row delete action to Alerts/Reports list view
  • adds bulk actions (bulk delete) to Alerts/Reports list view

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

After:
Screen Shot 2020-12-14 at 10 12 49 PM
Screen Shot 2020-12-14 at 10 13 09 PM

TEST PLAN

  • unit tested
  • manual test
    • individual Alert & Report rows can be deleted.
    • Alert & Report list views can bulk select and delete rows.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Changes UI
  • Requires DB Migration.
  • Confirm DB Migration upgrade and downgrade tested.
  • Introduces new feature or API
  • Removes existing feature or API

@codecov-io
Copy link

codecov-io commented Dec 15, 2020

Codecov Report

Merging #12053 (e7138d8) into master (7dac150) will decrease coverage by 0.05%.
The diff coverage is 77.50%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #12053      +/-   ##
==========================================
- Coverage   63.81%   63.76%   -0.06%     
==========================================
  Files         956      956              
  Lines       46845    46945     +100     
  Branches     4590     4597       +7     
==========================================
+ Hits        29895    29933      +38     
- Misses      16766    16828      +62     
  Partials      184      184              
Flag Coverage Δ
javascript 62.76% <77.50%> (+0.08%) ⬆️
python 64.37% <ø> (-0.14%) ⬇️

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

Impacted Files Coverage Δ
superset-frontend/src/views/CRUD/alert/types.ts 100.00% <ø> (ø)
...perset-frontend/src/views/CRUD/alert/AlertList.tsx 76.47% <76.92%> (+12.51%) ⬆️
...frontend/src/views/CRUD/alert/AlertReportModal.tsx 50.53% <100.00%> (-0.14%) ⬇️
superset/cli.py 34.68% <0.00%> (-5.85%) ⬇️
superset/db_engine_specs/presto.py 81.75% <0.00%> (-0.65%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7dac150...e7138d8. Read the comment docs.

@nytai nytai force-pushed the tai/alerts-delete-flow branch from 2a67b09 to 67b436b Compare December 15, 2020 06:38
@@ -66,7 +66,7 @@
"@data-ui/sparkline": "^0.0.84",
"@emotion/core": "^10.0.35",
"@superset-ui/chart-controls": "^0.15.13",
"@superset-ui/core": "^0.15.13",
"@superset-ui/core": "^0.15.17",
Copy link
Member Author

Choose a reason for hiding this comment

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

update to take advantage of new rison requestType for makeApi

@nytai nytai marked this pull request as ready for review December 15, 2020 07:21
@nytai nytai force-pushed the tai/alerts-delete-flow branch from 67b436b to 74336d1 Compare December 15, 2020 19:23
@@ -52,7 +52,7 @@ export type AlertObject = {
database?: MetaObject;
description?: string;
grace_period?: number;
id?: number;
id: number;
Copy link
Contributor

Choose a reason for hiding this comment

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

Does this not throw a ts error when creating alerts?

Copy link
Member Author

Choose a reason for hiding this comment

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

I updated the state type to be Partial<AlertObject> so that we can store incomplete AlertObjects in state.

@nytai nytai merged commit e299dbf into apache:master Dec 16, 2020
@nytai nytai deleted the tai/alerts-delete-flow branch December 16, 2020 20:57
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.0.0 labels Mar 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/L 🚢 1.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants