-
Notifications
You must be signed in to change notification settings - Fork 1.2k
UI: Create Account form to set proper domain and role based on route #12200
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
base: main
Are you sure you want to change the base?
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #12200 +/- ##
============================================
- Coverage 17.57% 17.44% -0.13%
- Complexity 15550 15595 +45
============================================
Files 5913 5913
Lines 529428 534975 +5547
Branches 64677 66646 +1969
============================================
+ Hits 93022 93337 +315
- Misses 425944 431171 +5227
- Partials 10462 10467 +5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
@DaanHoogland a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress. |
|
UI build: ✔️ |
DaanHoogland
left a comment
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.
clgtm, tested in qa and works as described
shwstppr
left a comment
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.
Idea lgtm, changes can be simplified
| if (this.isAdmin()) { | ||
| if (this.isNonRootDomain) { | ||
| const domainAdminRole = this.roles.find(role => role.type === 'DomainAdmin') | ||
| if (domainAdminRole) { | ||
| this.form.roleid = domainAdminRole.id | ||
| return | ||
| } | ||
| } else { | ||
| const rootAdminRole = this.roles.find(role => role.type === 'Admin') | ||
| if (rootAdminRole) { | ||
| this.form.roleid = rootAdminRole.id | ||
| return | ||
| } | ||
| } | ||
| } |
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.
How about filtering Admin role when it is not the ROOT domain?
|
@Pearl1594 a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress. |
|
UI build: ✔️ |
|



Description
This PR adds an enhancement, where in when we log in as root admin, create a domain and then go to accounts from that domain - while creating the account for the domain, it should correctly select the right domain and role in the create account form.
It also takes care of setting the right role type when changing the domain
As Root Admin:
If domain selected isn't the root domain, then the Role type selected by default will be Domain Admin
If the domain is then changed to root domain, the role type on the form will automatically change to Root Admin.
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Screenshots (if appropriate):
How Has This Been Tested?
How did you try to break this feature and the system with this change?