1 <div class=
"margin-content">
2 <div class=
"title-page title-page-single">
6 <div *
ngIf=
"error" class=
"alert alert-danger">{{ error }}
</div>
8 <form role=
"form" (ngSubmit)=
"login()" [formGroup]=
"form">
9 <div class=
"form-group">
10 <label for=
"username">User
</label>
12 type=
"text" id=
"username" placeholder=
"Username or email address" required
13 formControlName=
"username" [ngClass]=
"{ 'input-error': formErrors['username'] }"
15 <div *
ngIf=
"formErrors.username" class=
"form-error">
16 {{ formErrors.username }}
20 <div class=
"form-group">
21 <label for=
"password">Password
</label>
24 type=
"password" name=
"password" id=
"password" placeholder=
"Password" required
25 formControlName=
"password" [ngClass]=
"{ 'input-error': formErrors['password'] }"
27 <div class=
"forgot-password-button" (click)=
"openForgotPasswordModal()">I forgot my password
</div>
29 <div *
ngIf=
"formErrors.password" class=
"form-error">
30 {{ formErrors.password }}
34 <input type=
"submit" value=
"Login" [disabled]=
"!form.valid">
38 <div bsModal #
forgotPasswordModal=
"bs-modal" (onShown)=
"onForgotPasswordModalShown()" class=
"modal" tabindex=
"-1">
39 <div class=
"modal-dialog">
40 <div class=
"modal-content">
42 <div class=
"modal-header">
43 <span class=
"close" aria-hidden=
"true" (click)=
"hideForgotPasswordModal()"></span>
44 <h4 class=
"modal-title">Forgot your password
</h4>
47 <div class=
"modal-body">
48 <div class=
"form-group">
49 <label for=
"forgot-password-email">Email
</label>
51 type=
"email" id=
"forgot-password-email" placeholder=
"Email address" required
52 [(ngModel)]=
"forgotPasswordEmail" #forgotPasswordEmailInput
56 <div class=
"form-group inputs">
57 <span class=
"action-button action-button-cancel" (click)=
"hideForgotPasswordModal()">
62 type=
"submit" value=
"Send me an email to reset my password" class=
"action-button-submit"
63 (click)=
"askResetPassword()" [disabled]=
"!forgotPasswordEmailInput.validity.valid"