Change the encrypted password dialog to use the user's external username, if one exists.
Fixes #1538
This commit is contained in:
parent
f36442aa0d
commit
4b3420eddf
3 changed files with 33 additions and 6 deletions
|
@ -87,14 +87,19 @@
|
|||
|
||||
$scope.generateClientToken = function() {
|
||||
var generateToken = function(password) {
|
||||
if (!password) {
|
||||
return;
|
||||
}
|
||||
|
||||
var data = {
|
||||
'password': password
|
||||
};
|
||||
|
||||
ApiService.generateUserClientKey(data).then(function(resp) {
|
||||
$scope.context.encryptedPasswordCredentials = {
|
||||
'username': $scope.context.viewuser.username,
|
||||
'password': resp['key']
|
||||
'username': UserService.getCLIUsername(),
|
||||
'password': resp['key'],
|
||||
'namespace': UserService.currentUser().username
|
||||
};
|
||||
}, ApiService.errorDisplay('Could not generate token'));
|
||||
};
|
||||
|
|
Reference in a new issue