diff options
author | Ashwin Sharma <ashwin.shyam.sharma@att.com> | 2020-07-30 16:05:02 +0000 |
---|---|---|
committer | Ashwin Sharma <ashwin.shyam.sharma@att.com> | 2020-07-30 16:05:02 +0000 |
commit | e673a058c995392b3ad6cbab91a9571bed29a57b (patch) | |
tree | b9454b4ec885c25f628d03b137ccb94d8a83d9f7 /ui-react/src/api/UserService.js | |
parent | a7f63adca6933886bd3499044ae93c0daa01705c (diff) |
Clamp react ui to use url pathname dynamically instead of hardcoded prefix for calling apis
Issue-ID: CLAMP-914
Signed-off-by: Ashwin Sharma <ashwin.shyam.sharma@att.com>
Change-Id: I266aeafe9a543e95bcb96fcab6437227c148f8c4
Diffstat (limited to 'ui-react/src/api/UserService.js')
-rw-r--r-- | ui-react/src/api/UserService.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ui-react/src/api/UserService.js b/ui-react/src/api/UserService.js index 477ca4269..5fb4aa6b4 100644 --- a/ui-react/src/api/UserService.js +++ b/ui-react/src/api/UserService.js @@ -24,7 +24,7 @@ export default class UserService { static notLoggedUserName='Anonymous'; static login() { - return fetch('/restservices/clds/v1/user/getUser', { + return fetch(window.location.pathname + 'restservices/clds/v1/user/getUser', { method: 'GET', credentials: 'same-origin' }) @@ -49,7 +49,7 @@ export default class UserService { } static getUserInfo() { - return fetch('/restservices/clds/v2/clampInformation', { + return fetch(window.location.pathname + 'restservices/clds/v2/clampInformation', { method: 'GET', credentials: 'same-origin' }) |