mirror of
https://github.com/mealie-recipes/mealie.git
synced 2025-07-24 15:49:42 +02:00
refactor(frontend): 🚧 Add group/user CRUD support for admins
This commit is contained in:
parent
917177da5b
commit
695d7e96ae
46 changed files with 2015 additions and 102 deletions
|
@ -1,16 +1,15 @@
|
|||
import { AxiosResponse } from "axios";
|
||||
|
||||
interface RequestResponse<T> {
|
||||
response: AxiosResponse<T> | null;
|
||||
data: T | null;
|
||||
error: any;
|
||||
}
|
||||
|
||||
export interface ApiRequestInstance {
|
||||
get<T>(url: string, data?: T | object): Promise<RequestResponse<T>>;
|
||||
post<T>(url: string, data: T | object): Promise<RequestResponse<T>>;
|
||||
put<T>(url: string, data: T | object): Promise<RequestResponse<T>>;
|
||||
patch<T>(url: string, data: T | object): Promise<RequestResponse<T>>;
|
||||
delete<T>(url: string, data?: T | object): Promise<RequestResponse<T>>;
|
||||
response: AxiosResponse<T> | null;
|
||||
data: T | null;
|
||||
error: any;
|
||||
}
|
||||
|
||||
export interface ApiRequestInstance {
|
||||
get<T>(url: string, data?: T | object): Promise<RequestResponse<T>>;
|
||||
post<T>(url: string, data: T | object | any): Promise<RequestResponse<T>>;
|
||||
put<T>(url: string, data: T | object): Promise<RequestResponse<T>>;
|
||||
patch<T>(url: string, data: T | object): Promise<RequestResponse<T>>;
|
||||
delete<T>(url: string, data?: T | object): Promise<RequestResponse<T>>;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue