core/authentication/current-password-modal.component.ts
selector | c8y-current-password-modal |
templateUrl | ./current-password-modal.component.html |
Properties |
Methods |
Outputs |
constructor(modal: BsModalRef)
|
||||||
Parameters :
|
currentPasswordEmitter |
Type : EventEmitter
|
cancel |
cancel()
|
Returns :
void
|
passwordConfirm |
passwordConfirm()
|
Returns :
void
|
password |
Type : string
|
<c8y-modal [customFooter]="true" [title]="'Confirm your current password' | translate" #modal>
<form #confirmForm="ngForm" (ngSubmit)="confirmForm.form.valid && passwordConfirm()">
<div class="d-block p-24">
<c8y-form-group [hasWarning]="true">
<label translate for="currentPassword">Enter your password</label>
<input
id="currentPassword"
[(ngModel)]="password"
type="password"
name="password"
class="form-control"
required
/>
<c8y-messages>
<c8y-message translate>
The password of the user that you are currently logged in with.
</c8y-message>
</c8y-messages>
</c8y-form-group>
</div>
<div class="modal-footer separator-top bg-white sticky-bottom">
<button
title="{{ 'Cancel' | translate }}"
class="btn btn-default"
type="button"
(click)="cancel()"
translate
>
Cancel
</button>
<button
title="{{ 'Confirm' | translate }}"
class="btn btn-primary"
type="submit"
[disabled]="!confirmForm.form.valid"
translate
>
Confirm
</button>
</div>
</form>
</c8y-modal>