aboutsummaryrefslogblamecommitdiffhomepage
path: root/client/src/app/account/account.component.html
blob: 4797fa9149c3e39157b0319fcc516e29f20186ae (plain) (tree)
1
2
3
4
5
6
7
8
9
10




                                                                            
                                                                                 



                                                                                
                                                           
     
                                                                                                                                                          







                                                                                                    
                                                                             




                                                                                                              
<h3>Account</h3>

<div *ngIf="information" class="alert alert-success">{{ information }}</div>
<div *ngIf="error" class="alert alert-danger">{{ error }}</div>

<form role="form" (ngSubmit)="changePassword()" [formGroup]="changePasswordForm">
  <div class="form-group">
    <label for="new-password">New password</label>
    <input
      type="password" class="form-control" name="new-password" id="new-password"
      [(ngModel)]="newPassword" #newPasswordInput="ngModel"
    >
    <div [hidden]="changePasswordForm.controls['new-password'].valid || changePasswordForm.controls['new-password'].pristine" class="alert alert-warning">
      The password should have more than 5 characters
    </div>
  </div>

  <div class="form-group">
    <label for="name">Confirm new password</label>
    <input
      type="password" class="form-control" name="new-confirmed-password" id="new-confirmed-password"
      [(ngModel)]="newConfirmedPassword" #newConfirmedPasswordInput="ngModel"
    >
  </div>

  <input type="submit" value="Change password" class="btn btn-default" [disabled]="!changePasswordForm.valid">
</form>