diff --git a/src/app/features/profile/partials/profile.html b/src/app/features/profile/partials/profile.html
index 76e3fc64ef3..2f5df6146ed 100644
--- a/src/app/features/profile/partials/profile.html
+++ b/src/app/features/profile/partials/profile.html
@@ -58,8 +58,8 @@
@@ -69,7 +69,9 @@
Name: {{ac.name}} |
Role: {{ac.role}} |
- currently using this account
+
+ active now
+
|
@@ -78,7 +80,34 @@
|
+
+
diff --git a/src/app/features/profile/profileCtrl.js b/src/app/features/profile/profileCtrl.js
index 3683fdc5621..0a2ea70efe7 100644
--- a/src/app/features/profile/profileCtrl.js
+++ b/src/app/features/profile/profileCtrl.js
@@ -8,6 +8,8 @@ function (angular) {
module.controller('ProfileCtrl', function($scope, $http, backendSrv) {
+ $scope.newAccount = {name: ''};
+
$scope.init = function() {
$scope.getUser();
$scope.getUserAccounts();
@@ -26,11 +28,7 @@ function (angular) {
};
$scope.setUsingAccount = function(account) {
- backendSrv.request({
- method: 'POST',
- url: '/api/user/using/' + account.accountId,
- desc: 'Change active account',
- }).then($scope.getUserAccounts);
+ backendSrv.post('/api/user/using/' + account.accountId).then($scope.getUserAccounts);
};
$scope.update = function() {
@@ -39,6 +37,10 @@ function (angular) {
backendSrv.post('/api/user/', $scope.user);
};
+ $scope.createAccount = function() {
+ backendSrv.put('/api/account/', $scope.newAccount).then($scope.getUserAccounts);
+ };
+
$scope.init();
});
diff --git a/src/css/less/bootswatch.dark.less b/src/css/less/bootswatch.dark.less
index 98b91b4b8d8..f3d83683f51 100644
--- a/src/css/less/bootswatch.dark.less
+++ b/src/css/less/bootswatch.dark.less
@@ -486,7 +486,7 @@ legend, label {
}
.label {
- color: @grayLighter;
+ color: @white;
}
.badge {