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

chore: get embedded user with roles and permissions #19813

Merged

Conversation

suddjian
Copy link
Member

@suddjian suddjian commented Apr 21, 2022

SUMMARY

The embedded page can now find out what permissions the user has.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags:
  • 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

@lilykuang lilykuang marked this pull request as ready for review April 29, 2022 21:06
@codecov
Copy link

codecov bot commented Apr 29, 2022

Codecov Report

Merging #19813 (c10c498) into master (e1f53f2) will decrease coverage by 12.58%.
The diff coverage is 40.00%.

❗ Current head c10c498 differs from pull request most recent head c1089d2. Consider uploading reports for the commit c1089d2 to get more accurate results

@@             Coverage Diff             @@
##           master   #19813       +/-   ##
===========================================
- Coverage   66.53%   53.95%   -12.59%     
===========================================
  Files        1714     1714               
  Lines       65044    65046        +2     
  Branches     6723     6718        -5     
===========================================
- Hits        43278    35095     -8183     
- Misses      20055    28243     +8188     
+ Partials     1711     1708        -3     
Flag Coverage Δ
javascript 51.24% <33.33%> (-0.03%) ⬇️
mysql ?
postgres ?
sqlite ?

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

Impacted Files Coverage Δ
...rset-frontend/src/dashboard/util/findPermission.ts 92.30% <ø> (ø)
superset-frontend/src/embedded/index.tsx 0.00% <0.00%> (ø)
...nts/ExploreAdditionalActionsMenu/ExploreReport.tsx 57.89% <ø> (ø)
superset-frontend/src/preamble.ts 0.00% <ø> (ø)
superset-frontend/src/types/bootstrapTypes.ts 100.00% <ø> (ø)
superset-frontend/src/views/store.ts 80.00% <66.66%> (-10.00%) ⬇️
...perset-frontend/src/views/CRUD/welcome/Welcome.tsx 74.22% <100.00%> (ø)
superset/views/users/api.py 66.66% <100.00%> (-22.23%) ⬇️
superset/views/utils.py 43.96% <100.00%> (-36.97%) ⬇️
superset/utils/dashboard_import_export.py 0.00% <0.00%> (-100.00%) ⬇️
... and 287 more

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 e1f53f2...c1089d2. Read the comment docs.

Lily Kuang added 2 commits April 29, 2022 14:16
 into lily/user-with-roles-and-permission

# Conflicts:
#	superset-frontend/src/types/bootstrapTypes.ts
Copy link
Member Author

@suddjian suddjian left a comment

Choose a reason for hiding this comment

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

Backend looks good to me, @lilykuang if you'd like to review the frontend side that I worked on I think we can merge this.

Copy link
Member

@lilykuang lilykuang left a comment

Choose a reason for hiding this comment

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

tested. LGTM

@lilykuang lilykuang merged commit 7f8279b into apache:master May 3, 2022
@lilykuang lilykuang deleted the lily/user-with-roles-and-permission branch May 4, 2022 00:04
hughhhh pushed a commit to hve-labs/superset that referenced this pull request May 11, 2022
* feat: get user roles endpoint

* add tests

* fix test

* get user with permission and roles with full user

* frontend

* type juggling

* the hash slinging slasher

* user reducer and action

* make it happy

* result

* lint

Co-authored-by: Lily Kuang <lily@preset.io>
philipher29 pushed a commit to ValtechMobility/superset that referenced this pull request Jun 9, 2022
* feat: get user roles endpoint

* add tests

* fix test

* get user with permission and roles with full user

* frontend

* type juggling

* the hash slinging slasher

* user reducer and action

* make it happy

* result

* lint

Co-authored-by: Lily Kuang <lily@preset.io>
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 2.0.0 labels Mar 13, 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 preset-io size/L 🚢 2.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants