国际化
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
import { http } from '@/utils/http/axios';
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
const baseUrl = '/api'
|
||||
|
||||
/**
|
||||
* @description: getLoansInfo
|
||||
*/
|
||||
export function getDefaultLocal() {
|
||||
// zh_CN 中文
|
||||
// gu_IN 印度
|
||||
const language = localStorage.getItem('lang')
|
||||
let lang = 'zh_CN'
|
||||
if (language === 'zh') {
|
||||
lang = 'zh_CN'
|
||||
} else if (language === 'id') {
|
||||
lang = 'gu_IN'
|
||||
}
|
||||
return http.request({
|
||||
url: `${baseUrl}/app/home/loans/defaultLocal`,
|
||||
method: 'GET',
|
||||
params: {
|
||||
lang
|
||||
}
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user