diff --git a/web/src/utils/request.ts b/web/src/utils/request.ts index ac25c6d7..9824e58e 100644 --- a/web/src/utils/request.ts +++ b/web/src/utils/request.ts @@ -81,7 +81,7 @@ export function createApi(): Readonly { return request({ method, url: _path.join('/'), - data: args[0], + ...(method === 'get' ? { params: args[0] } : { data: args[0] }), }); }, { get(target: any, p: string) {