Browse Source
Merge pull request #3107 from vvlladd28/bug/encode-email
[3.0] Fixed request 'resend activation'
pull/3108/head
Igor Kulikov
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
6 additions and
3 deletions
-
ui-ngx/src/app/core/auth/auth.service.ts
-
ui-ngx/src/app/core/http/user.service.ts
|
|
|
@ -159,7 +159,8 @@ export class AuthService { |
|
|
|
} |
|
|
|
|
|
|
|
public resendEmailActivation(email: string) { |
|
|
|
return this.http.post(`/api/noauth/resendEmailActivation?email=${email}`, |
|
|
|
const encodeEmail = encodeURIComponent(email); |
|
|
|
return this.http.post(`/api/noauth/resendEmailActivation?email=${encodeEmail}`, |
|
|
|
null, defaultHttpOptions()); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@ -18,10 +18,11 @@ import { Injectable } from '@angular/core'; |
|
|
|
import { defaultHttpOptionsFromConfig, RequestConfig } from './http-utils'; |
|
|
|
import { User } from '@shared/models/user.model'; |
|
|
|
import { Observable } from 'rxjs'; |
|
|
|
import { HttpClient } from '@angular/common/http'; |
|
|
|
import { HttpClient, HttpParams } from '@angular/common/http'; |
|
|
|
import { PageLink } from '@shared/models/page/page-link'; |
|
|
|
import { PageData } from '@shared/models/page/page-data'; |
|
|
|
import { isDefined } from '@core/utils'; |
|
|
|
import { InterceptorHttpParams } from '@core/interceptors/interceptor-http-params'; |
|
|
|
|
|
|
|
@Injectable({ |
|
|
|
providedIn: 'root' |
|
|
|
@ -71,7 +72,8 @@ export class UserService { |
|
|
|
} |
|
|
|
|
|
|
|
public sendActivationEmail(email: string, config?: RequestConfig) { |
|
|
|
return this.http.post(`/api/user/sendActivationMail?email=${email}`, null, defaultHttpOptionsFromConfig(config)); |
|
|
|
const encodeEmail = encodeURIComponent(email); |
|
|
|
return this.http.post(`/api/user/sendActivationMail?email=${encodeEmail}`, null, defaultHttpOptionsFromConfig(config)); |
|
|
|
} |
|
|
|
|
|
|
|
public setUserCredentialsEnabled(userId: string, userCredentialsEnabled?: boolean, config?: RequestConfig): Observable<any> { |
|
|
|
|