-
Notifications
You must be signed in to change notification settings - Fork 17
[WIP]feat(fbcnms-ui): Add Host Portal Login Page #171
base: main
Are you sure you want to change the base?
Conversation
be81e11
to
8e9b382
Compare
8e9b382
to
8bf968f
Compare
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.
There's a few changes that this needs, and merging this will need to wait until after migrating from 'master' to 'host' as well, but otherwise this looks fairly straightforward.
const params = new URLSearchParams(window.location.search); | ||
const to = params.get('to'); | ||
|
||
const hostPortal = window.location.hostname.slice(0, 4) === 'mast'; |
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.
Add typing annotations
const params = new URLSearchParams(window.location.search); | ||
const to = params.get('to'); | ||
|
||
const hostPortal = window.location.hostname.slice(0, 4) === 'mast'; |
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.
While this works, you should really be parsing the entire organization name
ie. in master.nms.com/master
, you should check up until the first period.
There could be legitimate organization names that start with 'mast'.
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.
Sorry this was just to test.
This will be replaced by 'host'
const params = new URLSearchParams(window.location.search); | ||
const to = params.get('to'); | ||
|
||
const hostPortal = window.location.hostname.slice(0, 4) === 'mast'; | ||
const hostname = window.location.hostname; |
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.
While a decent substitute for the organization name, you'll want to access the proper spelling and capitalization for the organization through @fbcnms/sequelize-models
.
Signed-off-by: HannaFar <[email protected]>
8bf968f
to
bc7e5ed
Compare
Signed-off-by: HannaFar [email protected]
Add Host Portal and Organization Portal Login page
Host Portal Login Page :
Organization Portal Login Page :