diff --git a/src/config/axios/index.ts b/src/config/axios/index.ts index e6c6af8d..79e558da 100644 --- a/src/config/axios/index.ts +++ b/src/config/axios/index.ts @@ -5,12 +5,13 @@ import { config } from './config' const { default_headers } = config const request = (option: any) => { - const { url, method, params, data, headersType, responseType } = option + const { url, method, params, data, headersType, responseType, ...config } = option return service({ url: url, method, params, data, + ...config, responseType: responseType, headers: { 'Content-Type': headersType || default_headers