import { ApiDomain, BaseAdapter, METHOD, Response } from '@/types'; interface ApiInterface { get: (data?: any) => Promise; getById: (data?: any) => Promise; post: (data?: any) => Promise; patch: (data?: any) => Promise; delete: (data?: any) => Promise; put: (data?: any) => Promise; getDic: (data?: any) => Promise; } export declare type Query = { urlData?: string; data?: any; }; /** * 请求类 */ export default class RequestUtil implements ApiInterface { private _http; private _response; private _api; constructor(_http: BaseAdapter, _response: BaseAdapter, api: string | ApiDomain); delete(id: string | number): Promise; get(params?: Query): Promise; getById(id: string | number): Promise; getDic(url: string): Promise; patch(params: any): Promise; post(params: any): Promise; put(params: any): Promise; _req({ method, url, params, data }: { method: METHOD; url: string; params?: any; data?: any; }): Promise; private resolveApiConfig; } export {};