mirror of
https://github.com/jeecgboot/JeecgBoot.git
synced 2025-12-29 16:05:31 +08:00
v3.8.1发布,上传前端代码
This commit is contained in:
@ -53,7 +53,8 @@ export function filterDictText(dictOptions, text) {
|
||||
let dictText = txt;
|
||||
for (let dictItem of dictOptions) {
|
||||
// update-begin--author:liaozhiyang---date:20240524---for:【TV360X-469】兼容数据null值防止报错
|
||||
if (dictItem == null) break;
|
||||
if (dictItem == null) continue;
|
||||
if (dictItem.value == null) continue;
|
||||
// update-end--author:liaozhiyang---date:20240524---for:【TV360X-469】兼容数据null值防止报错
|
||||
if (txt.toString() === dictItem.value.toString()) {
|
||||
dictText = dictItem.text || dictItem.title || dictItem.label;
|
||||
|
||||
@ -25,7 +25,7 @@ export const getDictItemsByCode = (code) => {
|
||||
|
||||
};
|
||||
/**
|
||||
* Popup字典翻译方法
|
||||
* 从缓存中获取Pop字典配置
|
||||
* @param text
|
||||
* @param code
|
||||
*/
|
||||
|
||||
@ -38,10 +38,15 @@ export function getAppEnvConfig() {
|
||||
VITE_GLOB_ONLINE_VIEW_URL,
|
||||
// 全局隐藏哪些布局,多个用逗号隔开
|
||||
VITE_GLOB_HIDE_LAYOUT_TYPES,
|
||||
// 当前运行在什么平台
|
||||
VITE_GLOB_RUN_PLATFORM,
|
||||
|
||||
// 【JEECG作为乾坤子应用】
|
||||
VITE_GLOB_QIANKUN_MICRO_APP_NAME,
|
||||
VITE_GLOB_QIANKUN_MICRO_APP_ENTRY,
|
||||
|
||||
//在线文档编辑版本。可选属性:wps, onlyoffice
|
||||
VITE_GLOB_ONLINE_DOCUMENT_VERSION,
|
||||
} = ENV;
|
||||
|
||||
// if (!/^[a-zA-Z\_]*$/.test(VITE_GLOB_APP_SHORT_NAME)) {
|
||||
@ -62,10 +67,14 @@ export function getAppEnvConfig() {
|
||||
VITE_GLOB_DOMAIN_URL,
|
||||
VITE_GLOB_ONLINE_VIEW_URL,
|
||||
VITE_GLOB_HIDE_LAYOUT_TYPES,
|
||||
VITE_GLOB_RUN_PLATFORM,
|
||||
|
||||
// 【JEECG作为乾坤子应用】
|
||||
VITE_GLOB_QIANKUN_MICRO_APP_NAME,
|
||||
VITE_GLOB_QIANKUN_MICRO_APP_ENTRY,
|
||||
|
||||
//在线文档编辑版本。可选属性:wps, onlyoffice
|
||||
VITE_GLOB_ONLINE_DOCUMENT_VERSION
|
||||
};
|
||||
}
|
||||
|
||||
@ -113,3 +122,14 @@ export function getHideLayoutTypes(): string[] {
|
||||
}
|
||||
return VITE_GLOB_HIDE_LAYOUT_TYPES.split(',');
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取在线文档版本号
|
||||
*/
|
||||
export function getOnlineDocumentVersion(): string {
|
||||
const { VITE_GLOB_ONLINE_DOCUMENT_VERSION } = getAppEnvConfig();
|
||||
if (typeof VITE_GLOB_ONLINE_DOCUMENT_VERSION !== 'string') {
|
||||
return 'wps';
|
||||
}
|
||||
return VITE_GLOB_ONLINE_DOCUMENT_VERSION;
|
||||
}
|
||||
|
||||
@ -99,6 +99,12 @@ const transform: AxiosTransform = {
|
||||
if(requestUrl!=null && (requestUrl.startsWith("http:") || requestUrl.startsWith("https:"))){
|
||||
isStartWithHttp = true;
|
||||
}
|
||||
// update-begin--author:sunjianlei---date:20250411---for:【QQYUN-9685】构建 electron 桌面应用
|
||||
if (!isStartWithHttp && requestUrl != null) {
|
||||
// 由于electron的url是file://开头的,所以需要判断一下
|
||||
isStartWithHttp = requestUrl.startsWith('file://');
|
||||
}
|
||||
// update-end----author:sunjianlei---date:20250411---for:【QQYUN-9685】构建 electron 桌面应用
|
||||
if (!isStartWithHttp && joinPrefix) {
|
||||
config.url = `${urlPrefix}${config.url}`;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user