-
Notifications
You must be signed in to change notification settings - Fork 24
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
Disable UI starting dataset creating jobs for unprivileged users #7753
Merged
MichaelBuessemeyer
merged 11 commits into
master
from
only-allow-privilegde-user-dataset-creation-jobs
May 2, 2024
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
9fbe2d4
disable ui starting dataset creating jobs for non-admin/ datasetmanag…
MichaelBuessemeyer ff2a46b
hide materialize merger mode button instead of disabling it
MichaelBuessemeyer 6c35ddb
check for is team manager as well (and not only admin or dataset mana…
MichaelBuessemeyer 87e8632
Merge branch 'master' of github.com:scalableminds/webknossos into onl…
MichaelBuessemeyer e6e3b02
re-allow merge with fallback layer for team managers
MichaelBuessemeyer 683498e
Merge branch 'master' of github.com:scalableminds/webknossos into onl…
MichaelBuessemeyer 9bd4e66
add changelog entry
MichaelBuessemeyer e16e682
add improved image to permission enforcer view / forbidden view
MichaelBuessemeyer 5e0a08a
Merge branch 'master' of github.com:scalableminds/webknossos into onl…
MichaelBuessemeyer 406d3b7
add manager/admin permissions required view to privileged views
MichaelBuessemeyer 3636388
Merge branch 'master' into only-allow-privilegde-user-dataset-creatio…
MichaelBuessemeyer File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import React from "react"; | ||
import { Button, Result, Col, Row } from "antd"; | ||
import { Link } from "react-router-dom"; | ||
|
||
export function PageNotAvailableToNormalUser() { | ||
return ( | ||
<Row justify="center" align="middle" className="full-viewport-height"> | ||
<Col> | ||
<Result | ||
status="error" | ||
title="Forbidden" | ||
icon={<i className="drawing drawing-forbidden-view" />} | ||
subTitle={ | ||
<> | ||
Apologies, but you don't have permission to view this page. | ||
<br /> | ||
Please reach out to a team manager, dataset manager or administrator to assist you | ||
with the actions you'd like to take. | ||
</> | ||
} | ||
extra={ | ||
<Link to="/"> | ||
<Button type="primary">Return to Dashboard</Button> | ||
</Link> | ||
} | ||
/> | ||
</Col> | ||
</Row> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think, this prop can be added to a few other components:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for listing all other components 👍
Initially, I though that this should be added in a separate PR but doing it already here is also fine to me and might also save some time.
I'll test each route as admin and non-admin later :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done, worked out as expected 👍. All pages/view listed above are available to [email protected] but not to [email protected]