diff options
author | Kotta, Shireesha (sk434m) <sk434m@att.com> | 2019-06-13 14:41:15 -0400 |
---|---|---|
committer | Kotta, Shireesha (sk434m) <sk434m@att.com> | 2019-06-17 15:51:28 -0400 |
commit | b75f35b0a1824aab32b4329fa62076b0f0307853 (patch) | |
tree | 97582ed38384d8a9b984107522440aa126130cd6 /ecomp-portal-FE-common/client/app/views/users/new-user-dialogs | |
parent | 4027435c28e1433df2476b83a6e77ba4d1d865bd (diff) |
Application Onboarding page changes
Issue-ID: PORTAL-644
Application Onboarding page changes , DB scripts
Change-Id: Id689e15f5abd56192420e6761440659531108ab4
Signed-off-by: Kotta, Shireesha (sk434m) <sk434m@att.com>
Diffstat (limited to 'ecomp-portal-FE-common/client/app/views/users/new-user-dialogs')
3 files changed, 56 insertions, 11 deletions
diff --git a/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/bulk-user.controller.js b/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/bulk-user.controller.js index 718879a0..ae3907b2 100644 --- a/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/bulk-user.controller.js +++ b/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/bulk-user.controller.js @@ -377,7 +377,7 @@ if (prevRow == null || prevRow.orgUserId.toLowerCase() !== uploadRow.orgUserId.toLowerCase()) { if (debug) $log.debug('BulkUserModalCtrl::buildAppRoleChecks: create request for orgUserId ' + uploadRow.orgUserId); - let appPromise = usersService.getUserAppRoles(appId, uploadRow.orgUserId,true).promise().then( (userAppRolesResult) => { + let appPromise = usersService.getUserAppRoles(appId, uploadRow.orgUserId,true, false).promise().then( (userAppRolesResult) => { // Reply for unknown user has all defined roles with isApplied=false on each. if (typeof userAppRolesResult[0] !== "undefined") { if (debug) diff --git a/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/new-user.controller.js b/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/new-user.controller.js index 512c3a0c..3df58daa 100644 --- a/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/new-user.controller.js +++ b/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/new-user.controller.js @@ -43,6 +43,18 @@ class NewUserModalCtrl { constructor($scope, $log, usersService, applicationsService, confirmBoxService, items) { var extRequestValue = false; + var isSystemUser = false; + + $scope.ngRepeatDemo = [ + {id: 'userButton', value: 'true', labelvalue: 'user'}, + {id: 'systemUserButton', value: 'false', labelvalue: 'system'} + ] + + $scope.selectedvalueradioButtonGroup = { + type: 'true' + } + + let init = () => { //$log.info('NewUserModalCtrl::init'); this.isSaving = false; @@ -94,7 +106,7 @@ this.dialogState = 1; return; } - //$log.debug('NewUserModalCtrl::getUserAppsRoles: about to call getAdminAppsSimpler'); + $log.debug('NewUserModalCtrl::getUserAppsRoles: about to call getAdminAppsSimpler'); this.isGettingAdminApps = true; applicationsService.getAdminAppsSimpler().then((apps) => { //$log.debug('NewUserModalCtrl::getUserAppsRoles: beginning of then for getAdminAppsSimpler'); @@ -123,7 +135,11 @@ app.isErrorUpdating = false; app.isDoneUpdating = false; app.errorMessage = ""; - usersService.getUserAppRoles(app.id, this.selectedUser.orgUserId, extRequestValue).promise().then((userAppRolesResult) => { + if($scope.selectedvalueradioButtonGroup.type == 'false') + { + isSystemUser = true; + } + usersService.getUserAppRoles(app.id, this.selectedUser.orgUserId, extRequestValue,isSystemUser).promise().then((userAppRolesResult) => { //$log.debug('NewUserModalCtrl::getUserAppsRoles: got a result for app: ',app.id,': ',app.name,': ',userAppRolesResult); app.appRoles = userAppRolesResult; app.isLoading = false; @@ -179,11 +195,18 @@ } } + if($scope.selectedvalueradioButtonGroup.type == 'false') + { + isSystemUser = true; + }else{ + isSystemUser = false; + } var newUserAppRoles = { orgUserId: this.selectedUser.orgUserId, appId: app.id, appRoles: app.appRoles, - appName: app.name + appName: app.name, + isSystemUser : isSystemUser }; usersService.updateUserAppRoles(newUserAppRoles).promise() .then(res => { diff --git a/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/new-user.modal.html b/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/new-user.modal.html index a68cd55c..dc93006e 100644 --- a/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/new-user.modal.html +++ b/ecomp-portal-FE-common/client/app/views/users/new-user-dialogs/new-user.modal.html @@ -55,22 +55,44 @@ <div class="b2b-modal-header"> <h2 class="heading-medium" id="newAdmin">New User</h2> - + <div class="corner-button in"> <button type="button" class="close" aria-label="Close" id="user-button-close" ng-click="$dismiss('cancel')"></button> </div> </div> - - <div class="b2b-modal-body" tabindex="0" + + <fieldset style="height: 75px;" role="radiogroup" + b2b-radio-group-accessibility aria-labelledby="radiolabel2"> + <div class="form-row" role="radio" + ng-repeat="radioObj in ngRepeatDemo"> + <label style="margin-top: 10px;" for="{{radioObj.id}}" + class="radio"> <input type="radio" + ng-model="selectedvalueradioButtonGroup.type" + id="{{radioObj.id}}" + name="nameradioButton" value="{{radioObj.value}}"> <i + style= "margin-top: 10px; margin-left: 38px;" class="skin"></i> <span + style="margin-top: 10px; margin-left: 70px;">{{radioObj.labelvalue}}</span> + </label> + </div> + </fieldset> + <div class="systemUser" ng-show="selectedvalueradioButtonGroup.type =='false'" style="color: #5a5a5a; + font-family: Omnes-ECOMP-W02, Arial;font-size: 14px;margin-bottom: 8px; padding-left: 30px;">Enter system UserId</div> + <div ng-show="selectedvalueradioButtonGroup.type =='false'"> + <input id="action-property-input" + class="adminForm-name-property-input" placeholder="xxxxxx@org.com" + ng-model="newUser.selectedUser.orgUserId" + type="text" maxlength="60" style="padding: 20px; + margin-left: 30px; width: 60%;"/> + </div> + <div class="b2b-modal-body" tabindex="0" ng-show="selectedvalueradioButtonGroup.type =='true'" aria-label="Modal header text content" role="region"> <search-users search-title="" selected-user="newUser.selectedUser"></search-users> - </div> - + </div> <div class="b2b-modal-footer"> <div class="cta-button-group in"> <button class="btn btn-alt btn-small" id="next-button" ng-click="newUser.selectedUser && newUser.getUserAppsRoles()" - ng-class="{disabled: !newUser.selectedUser}">Next + ng-disabled = "(!newUser.selectedUser && selectedvalueradioButtonGroup.type =='true' ) || (selectedvalueradioButtonGroup.type =='false' && !newUser.selectedUser) ||(newUser.selectedUser && newUser.selectedUser.orgUserId.length <1)">Next </button> <button id="search-users-button-cancel" class="btn btn-alt btn-small" ng-click="$dismiss('cancel')">Cancel</button> @@ -78,7 +100,7 @@ </div> </div> - <div ng-if="newUser.dialogState===3"> + <div ng-if="newUser.dialogState===3" > <div class="b2b-modal-header"> <div class="title" |