设备点检记录新增

This commit is contained in:
2026-05-21 17:54:57 +08:00
parent c09ca584c3
commit 2496d05349
25 changed files with 2188 additions and 12 deletions

View File

@@ -1,4 +1,3 @@
import { useGlobSetting } from '/@/hooks/setting';
import { merge, random } from 'lodash-es';
import { isArray } from '/@/utils/is';
import { FormSchema } from '/@/components/Form';
@@ -14,11 +13,10 @@ import { useI18n } from "@/hooks/web/useI18n";
import {$electron} from "@/electron";
import {router} from "@/router";
import {encryptByBase64} from "@/utils/cipher";
import { resolveApiBaseUrl } from '/@/utils/env/apiBaseUrl';
//存放部门路径的数组
const departNamePath = ref<Record<string, string>>({});
const globSetting = useGlobSetting();
const baseApiUrl = globSetting.domainUrl;
/**
* 获取文件服务访问路径
* @param fileUrl 文件路径
@@ -31,10 +29,10 @@ export const getFileAccessHttpUrl = (fileUrl, prefix = 'http') => {
//判断是否是数组格式
let isArray = fileUrl.indexOf('[') != -1;
if (!isArray) {
let prefix = `${baseApiUrl}/sys/common/static/`;
const staticPrefix = `${resolveApiBaseUrl()}/sys/common/static/`;
// 判断是否已包含前缀
if (!fileUrl.startsWith(prefix)) {
result = `${prefix}${fileUrl}`;
if (!fileUrl.startsWith(staticPrefix)) {
result = `${staticPrefix}${fileUrl}`;
}
}
}