Merge pull request #72 in TEA/dafa-web-monorepo from bugfix/TV-307 to develop
Squashed commit of the following: commit 297b139869ab7bd1164b12e2cdc8cff32b7a77a4 Author: fueno <nicolas.fuentes-maturana@arbetsformedlingen.se> Date: Mon Aug 30 09:19:43 2021 +0200 TV-307 changed http method to patch
This commit is contained in:
@@ -179,7 +179,7 @@ export class EmployeeService extends UnsubscribeDirective {
|
||||
|
||||
public postEmployeeInvitation(email: string): Observable<string[]> {
|
||||
return this.httpClient
|
||||
.post<{ data: EmployeeInviteRequestData }>(`${this._apiBaseUrl}/invite`, {
|
||||
.patch<{ data: EmployeeInviteRequestData }>(`${this._apiBaseUrl}/invite`, {
|
||||
emails: Object.values(email),
|
||||
})
|
||||
.pipe(
|
||||
@@ -190,7 +190,7 @@ export class EmployeeService extends UnsubscribeDirective {
|
||||
}
|
||||
|
||||
public updateEmployeeData(employeeData: Employee): Observable<string> {
|
||||
return /* this.httpClient.put<{ id: string }>(`${this._apiBaseUrl}/${employeeData.id}`,
|
||||
return /* this.httpClient.put<{ id: string }>(`${this._apiBaseUrl}/${employeeData.id}`,
|
||||
mapEmployeeToRequestData(employeeData), API_HEADERS).pipe(
|
||||
map(({ id }) => id),
|
||||
catchError(error => throwError({ message: error as string, type: ErrorType.API }))
|
||||
|
||||
Reference in New Issue
Block a user