angular icon indicating copy to clipboard operation
angular copied to clipboard

[BUG] Reset Password Form

Open jacopo-93 opened this issue 2 years ago • 2 comments

Environment

Please provide as many details as you can:

  • Hosting type
    • [] Form.io
    • [x ] Local deployment
      • Version: 1.0.0
  • Formio.js version: 4.15.0
  • Frontend framework: angular 14.0.0
  • Browser: Google Chrome
  • Browser version: 114.0.5735.134

Steps to Reproduce

  1. Install library
  2. Use FormioAuthService
  3. start server

Expected behavior

In the section Reset Password should be shown the reset password form.

Observed behavior

In the section Reset Password should be shown the reset password form, but the library automatically opens the registration form.

Example

When is initialize the FormioAuthService the properties resetPass has the value of registration.form endpoint because it seems that is filled in this way:

     this.resetPassForm =
      this.appConfig.appUrl +
      '/' +
      get(this.config, 'register.form', 'resetpass');

while it should be initialized in the following way:

this.resetPassForm =
  this.appConfig.appUrl +
  '/' +
  get(this.config, 'resetpass.form', 'resetpass');

Note that in the FormioAuthConfig class the property resetpass.form is valorized.

jacopo-93 avatar Jun 26 '23 07:06 jacopo-93

I add the alert for the initialization onResetPass event, that is declared at line 22 public onResetPass: EventEmitter<object>;

but it is not initialized:

    this.onLogin = new EventEmitter();
    this.onLogout = new EventEmitter();
    this.onRegister = new EventEmitter();
    this.onUser = new EventEmitter();
    this.onError = new EventEmitter();

    this.ready = new Promise((resolve: any, reject: any) => {
      this.readyResolve = resolve;
      this.readyReject = reject;
    });

Following the error:

image

jacopo-93 avatar Jun 26 '23 09:06 jacopo-93

@jacopo-93 Can you update your version of angular from 1.0.0 to 6.0.0? 6.0.0 is more compatible with the 4.15.0 formio.js version you are using.

daneformio avatar Mar 13 '24 13:03 daneformio

Thank you for your contribution. As this issue has been inactive for over 90 days, I will close it for now. If you wish to reopen the issue, please respond, and we can resume the triage process.

lane-formio avatar Jun 12 '24 13:06 lane-formio