mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
feature: allow delete request to accept body (#39817)
This commit is contained in:
parent
451d023c79
commit
fffbdf4c82
@ -140,7 +140,7 @@ export interface FetchError<T extends FetchErrorDataProps = any> {
|
|||||||
*/
|
*/
|
||||||
export interface BackendSrv {
|
export interface BackendSrv {
|
||||||
get(url: string, params?: any, requestId?: string): Promise<any>;
|
get(url: string, params?: any, requestId?: string): Promise<any>;
|
||||||
delete(url: string): Promise<any>;
|
delete(url: string, data?: any): Promise<any>;
|
||||||
post(url: string, data?: any): Promise<any>;
|
post(url: string, data?: any): Promise<any>;
|
||||||
patch(url: string, data?: any): Promise<any>;
|
patch(url: string, data?: any): Promise<any>;
|
||||||
put(url: string, data?: any): Promise<any>;
|
put(url: string, data?: any): Promise<any>;
|
||||||
|
@ -385,8 +385,8 @@ export class BackendSrv implements BackendService {
|
|||||||
return await this.request({ method: 'GET', url, params, requestId });
|
return await this.request({ method: 'GET', url, params, requestId });
|
||||||
}
|
}
|
||||||
|
|
||||||
async delete(url: string) {
|
async delete(url: string, data?: any) {
|
||||||
return await this.request({ method: 'DELETE', url });
|
return await this.request({ method: 'DELETE', url, data });
|
||||||
}
|
}
|
||||||
|
|
||||||
async post(url: string, data?: any) {
|
async post(url: string, data?: any) {
|
||||||
|
Loading…
Reference in New Issue
Block a user