add put method
This commit is contained in:
parent
33da1ce585
commit
27eebf7f78
@ -57,6 +57,19 @@ export abstract class GenericService<Entity> {
|
||||
});
|
||||
}
|
||||
|
||||
@Validate()
|
||||
protected _put<R = Entity>(
|
||||
@RequiredParam() body: unknown,
|
||||
modelPath = this._defaultModelPath,
|
||||
queryParams?: List<QueryParam>
|
||||
): Observable<R> {
|
||||
return this._http.put<R>(`/${encodeURI(modelPath)}`, body, {
|
||||
params: this._queryParams(queryParams),
|
||||
headers: HeadersConfiguration.getHeaders(),
|
||||
observe: 'body'
|
||||
});
|
||||
}
|
||||
|
||||
@Validate()
|
||||
protected _getOne<R = Entity>(
|
||||
@RequiredParam() path: List,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user