fix delete member and add member

This commit is contained in:
Peter Maquiran
2024-09-17 17:28:50 +01:00
parent 1bc5707321
commit 263f593260
9 changed files with 33 additions and 31 deletions
+3 -3
View File
@@ -98,7 +98,7 @@ export class HttpService {
}
async delete<T>(url: string, httpParamsObj = {}): Promise<Result<T, HttpErrorResponse>> {
async delete<T>(url: string, httpParamsObj = {}, body = {}): Promise<Result<T, HttpErrorResponse>> {
let httpParams = new HttpParams();
@@ -110,7 +110,8 @@ export class HttpService {
}
let opts = {
params : httpParams
params : httpParams,
body
}
try {
@@ -121,7 +122,6 @@ export class HttpService {
}
}
async patch<T>(url: string, body ={}): Promise<Result<T, HttpErrorResponse>> {
try {
const result = await this.http.patch<T>(url, body).toPromise();