|
@@ -6,10 +6,14 @@ const { default_headers } = config
|
|
|
|
|
|
|
|
const request = (option: any) => {
|
|
const request = (option: any) => {
|
|
|
const { headersType, headers, ...otherOption } = option
|
|
const { headersType, headers, ...otherOption } = option
|
|
|
|
|
+
|
|
|
|
|
+ const langStore = JSON.parse(localStorage.getItem('lang') || '{}')
|
|
|
|
|
+
|
|
|
return service({
|
|
return service({
|
|
|
...otherOption,
|
|
...otherOption,
|
|
|
headers: {
|
|
headers: {
|
|
|
'Content-Type': headersType || default_headers,
|
|
'Content-Type': headersType || default_headers,
|
|
|
|
|
+ Lang: langStore.v,
|
|
|
...headers
|
|
...headers
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|