diff --git a/npm/ng-packs/packages/theme-basic/src/lib/components/change-password/change-password.component.html b/npm/ng-packs/packages/theme-basic/src/lib/components/change-password/change-password.component.html index d1dc99b109..738a673945 100644 --- a/npm/ng-packs/packages/theme-basic/src/lib/components/change-password/change-password.component.html +++ b/npm/ng-packs/packages/theme-basic/src/lib/components/change-password/change-password.component.html @@ -1,9 +1,9 @@ - +

{{ 'AbpIdentity::ChangePassword' | abpLocalization }}

-
+
* {{ 'AbpIdentity::Cancel' | abpLocalization }} - {{ 'AbpIdentity::Save' | abpLocalization }} + {{ 'AbpIdentity::Save' | abpLocalization }} diff --git a/npm/ng-packs/packages/theme-basic/src/lib/components/change-password/change-password.component.ts b/npm/ng-packs/packages/theme-basic/src/lib/components/change-password/change-password.component.ts index fe3d8da60d..6c372a4620 100644 --- a/npm/ng-packs/packages/theme-basic/src/lib/components/change-password/change-password.component.ts +++ b/npm/ng-packs/packages/theme-basic/src/lib/components/change-password/change-password.component.ts @@ -15,6 +15,7 @@ import { FormBuilder, FormGroup, Validators } from '@angular/forms'; import { comparePasswords } from '@ngx-validate/core'; import { Store } from '@ngxs/store'; import snq from 'snq'; +import { finalize } from 'rxjs/operators'; const { minLength, required } = Validators; @@ -43,6 +44,8 @@ export class ChangePasswordComponent implements OnInit, OnChanges { form: FormGroup; + modalBusy: boolean = false; + constructor(private fb: FormBuilder, private store: Store, private toasterService: ToasterService) {} ngOnInit(): void { @@ -60,6 +63,7 @@ export class ChangePasswordComponent implements OnInit, OnChanges { onSubmit() { if (this.form.invalid) return; + this.modalBusy = true; this.store .dispatch( @@ -68,6 +72,11 @@ export class ChangePasswordComponent implements OnInit, OnChanges { newPassword: this.form.get('newPassword').value, }), ) + .pipe( + finalize(() => { + this.modalBusy = false; + }), + ) .subscribe({ next: () => { this.visible = false;