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

[Workspace] fix:Prevent user from visiting dashboards / visualizations when out of a workspace #8107

Conversation

Qxisylolo
Copy link
Contributor

Description

This pr adresses:

  1. Prevent user from visiting dashboards / visualizations when out of a workspace
  2. However, the admin could be able to access dashboards and visualize

Screenshot

If the user is not an admin and tries to access dashboards or visualizations, a message saying "Application not found" will be shown.
截屏2024-09-10 17 50 51

Changelog

  • fix: Prevent user from visiting dashboards / visualizations when out of a workspace

Check List

  • All tests pass
    • yarn test:jest
    • yarn test:jest_integration
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

Copy link

codecov bot commented Sep 29, 2024

Codecov Report

Attention: Patch coverage is 40.00000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 60.58%. Comparing base (dfc7def) to head (c0cdd6c).
Report is 324 commits behind head on main.

Files with missing lines Patch % Lines
src/plugins/workspace/public/plugin.ts 40.00% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8107      +/-   ##
==========================================
- Coverage   60.58%   60.58%   -0.01%     
==========================================
  Files        3738     3738              
  Lines       88670    88687      +17     
  Branches    13782    13790       +8     
==========================================
+ Hits        53725    53735      +10     
- Misses      31661    31665       +4     
- Partials     3284     3287       +3     
Flag Coverage Δ
Linux_1 28.76% <40.00%> (-0.01%) ⬇️
Linux_2 56.28% <ø> (+0.01%) ⬆️
Linux_3 37.51% <ø> (-0.01%) ⬇️
Linux_4 29.60% <ø> (-0.01%) ⬇️
Windows_1 28.77% <40.00%> (-0.01%) ⬇️
Windows_2 56.23% <ø> (+0.01%) ⬆️
Windows_3 37.51% <ø> (-0.01%) ⬇️
Windows_4 29.60% <ø> (-0.01%) ⬇️

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.

@ruanyl
Copy link
Member

ruanyl commented Oct 30, 2024

I suggest to rely on something like app.workspaceAvailability to have a more robust solution so it works generally for all applications.

@ruanyl ruanyl marked this pull request as draft October 30, 2024 09:42
@ruanyl ruanyl closed this Dec 24, 2024
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.

4 participants