Skip to content

Commit 30fee72

Browse files
committed
fix:reset password to null
PR-quality resolved input fields coloring added indentations fixing
1 parent 79dc87b commit 30fee72

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

ui/src/app/login/controllers/LoginCtrl.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@
1616
$scope.unApproved = true;
1717
} else if(status.state == 403) {
1818
$scope.incorrectCredentials = true;
19+
$scope.user.password = '';
20+
document.getElementById('user_name')
21+
.style.borderBottomColor = 'red';
22+
document.getElementById('user_name').style.color = 'red';
23+
document.getElementById('user_name_label').style.color = 'red';
24+
document.getElementById('password')
25+
.style.borderBottomColor = 'red';
26+
document.getElementById('password_label').style.color = 'red';
1927
}
2028
});
2129
};

ui/src/app/views/login.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
<img class="logo" ng-src="assets/images/logo.png">
33
<div layout="column" class="login-content">
44
<md-input-container class="input-container">
5-
<label>User name</label>
6-
<input type="text" ng-model="user.user_name" />
5+
<label id="user_name_label">User name</label>
6+
<input type="text" ng-model="user.user_name" id="user_name"/>
77
</md-input-container>
88
<md-input-container class="input-container">
9-
<label>Password</label>
10-
<input type="password" ng-model="user.password" ng-enter="login()" />
9+
<label id="password_label">Password</label>
10+
<input type="password" ng-model="user.password" ng-enter="login()" id="password" />
1111
</md-input-container>
1212
<md-button class="md-raised md-primary login-button" ng-click="login()">Login</md-button>
1313
<div layout="row">

0 commit comments

Comments
 (0)