diff --git a/src/assets/json/readme.json b/src/assets/json/readme.json index 2be131f..cec774f 100644 --- a/src/assets/json/readme.json +++ b/src/assets/json/readme.json @@ -1,4 +1,3 @@ - { "first": "多功能校准源_字典:1", "second": "直流稳压电源检定装置_字典:2", @@ -6,16 +5,16 @@ "fourth": "0.02级活塞式压力计_字典:4", "fifth": "二等铂电阻温度计标准装置 _字典:5", "sixth": "安全阀校验装置_字典:6", - "seventh":"精密露点仪标准装置_字典:7", - "eighth":"E2等砝码标准装置_字典:8", - "ninth":"频谱分析仪检定装置_字典:9", - "tenth":"信号发生器检定装置_字典:10", - "eleventh":"微波衰减标准装置_字典:11", - "twelfth":"频率短期稳定度标准装置_字典:12", - "thirteenth":"示波器检定装置_字典:13", - "fourteenth":"铯原子频率标准装置_字典:14", - "fifteenth":"小功率标准装置_字典:15", - "sixteenth":"低频信号源检定装置_字典:16", - "seventeenth":"S参数标准装置_字典:17", - "eighteenth":"失真度标准装置_字典:18" + "seventh": "精密露点仪标准装置_字典:7", + "eighth": "E2等砝码标准装置_字典:8", + "ninth": "频谱分析仪检定装置_字典:9", + "tenth": "信号发生器检定装置_字典:10", + "eleventh": "微波衰减标准装置_字典:11", + "twelfth": "频率短期稳定度标准装置_字典:12", + "thirteenth": "示波器检定装置_字典:13", + "fourteenth": "铯原子频率标准装置_字典:14", + "fifteenth": "小功率标准装置_字典:15", + "sixteenth": "低频信号源检定装置_字典:16", + "seventeenth": "S参数标准装置_字典:17", + "eighteenth": "失真度标准装置_字典:18" } diff --git a/src/assets/json/readme.json b/src/assets/json/readme.json index 2be131f..cec774f 100644 --- a/src/assets/json/readme.json +++ b/src/assets/json/readme.json @@ -1,4 +1,3 @@ - { "first": "多功能校准源_字典:1", "second": "直流稳压电源检定装置_字典:2", @@ -6,16 +5,16 @@ "fourth": "0.02级活塞式压力计_字典:4", "fifth": "二等铂电阻温度计标准装置 _字典:5", "sixth": "安全阀校验装置_字典:6", - "seventh":"精密露点仪标准装置_字典:7", - "eighth":"E2等砝码标准装置_字典:8", - "ninth":"频谱分析仪检定装置_字典:9", - "tenth":"信号发生器检定装置_字典:10", - "eleventh":"微波衰减标准装置_字典:11", - "twelfth":"频率短期稳定度标准装置_字典:12", - "thirteenth":"示波器检定装置_字典:13", - "fourteenth":"铯原子频率标准装置_字典:14", - "fifteenth":"小功率标准装置_字典:15", - "sixteenth":"低频信号源检定装置_字典:16", - "seventeenth":"S参数标准装置_字典:17", - "eighteenth":"失真度标准装置_字典:18" + "seventh": "精密露点仪标准装置_字典:7", + "eighth": "E2等砝码标准装置_字典:8", + "ninth": "频谱分析仪检定装置_字典:9", + "tenth": "信号发生器检定装置_字典:10", + "eleventh": "微波衰减标准装置_字典:11", + "twelfth": "频率短期稳定度标准装置_字典:12", + "thirteenth": "示波器检定装置_字典:13", + "fourteenth": "铯原子频率标准装置_字典:14", + "fifteenth": "小功率标准装置_字典:15", + "sixteenth": "低频信号源检定装置_字典:16", + "seventeenth": "S参数标准装置_字典:17", + "eighteenth": "失真度标准装置_字典:18" } diff --git a/src/utils/String.ts b/src/utils/String.ts index 1943b0f..7ee7c1e 100644 --- a/src/utils/String.ts +++ b/src/utils/String.ts @@ -2,6 +2,10 @@ // 1.去除字符串中的特殊符号 export const clearSymbol = (str: any) => { + str = String(str) + if (!str) { + return '' + } if (str.includes('e') || str.includes('E')) { return str } diff --git a/src/assets/json/readme.json b/src/assets/json/readme.json index 2be131f..cec774f 100644 --- a/src/assets/json/readme.json +++ b/src/assets/json/readme.json @@ -1,4 +1,3 @@ - { "first": "多功能校准源_字典:1", "second": "直流稳压电源检定装置_字典:2", @@ -6,16 +5,16 @@ "fourth": "0.02级活塞式压力计_字典:4", "fifth": "二等铂电阻温度计标准装置 _字典:5", "sixth": "安全阀校验装置_字典:6", - "seventh":"精密露点仪标准装置_字典:7", - "eighth":"E2等砝码标准装置_字典:8", - "ninth":"频谱分析仪检定装置_字典:9", - "tenth":"信号发生器检定装置_字典:10", - "eleventh":"微波衰减标准装置_字典:11", - "twelfth":"频率短期稳定度标准装置_字典:12", - "thirteenth":"示波器检定装置_字典:13", - "fourteenth":"铯原子频率标准装置_字典:14", - "fifteenth":"小功率标准装置_字典:15", - "sixteenth":"低频信号源检定装置_字典:16", - "seventeenth":"S参数标准装置_字典:17", - "eighteenth":"失真度标准装置_字典:18" + "seventh": "精密露点仪标准装置_字典:7", + "eighth": "E2等砝码标准装置_字典:8", + "ninth": "频谱分析仪检定装置_字典:9", + "tenth": "信号发生器检定装置_字典:10", + "eleventh": "微波衰减标准装置_字典:11", + "twelfth": "频率短期稳定度标准装置_字典:12", + "thirteenth": "示波器检定装置_字典:13", + "fourteenth": "铯原子频率标准装置_字典:14", + "fifteenth": "小功率标准装置_字典:15", + "sixteenth": "低频信号源检定装置_字典:16", + "seventeenth": "S参数标准装置_字典:17", + "eighteenth": "失真度标准装置_字典:18" } diff --git a/src/utils/String.ts b/src/utils/String.ts index 1943b0f..7ee7c1e 100644 --- a/src/utils/String.ts +++ b/src/utils/String.ts @@ -2,6 +2,10 @@ // 1.去除字符串中的特殊符号 export const clearSymbol = (str: any) => { + str = String(str) + if (!str) { + return '' + } if (str.includes('e') || str.includes('E')) { return str } diff --git a/src/views/business/measure/item/components/sixteen/templateDetail.vue b/src/views/business/measure/item/components/sixteen/templateDetail.vue index 8dbaec5..a951929 100644 --- a/src/views/business/measure/item/components/sixteen/templateDetail.vue +++ b/src/views/business/measure/item/components/sixteen/templateDetail.vue @@ -396,7 +396,7 @@ fun(props.pageType === 'detail') } // 每个table对应的下拉框内容 字典 -const tableDict = ref<{ [key: string]: { value: string;name: string;id: string }[] }>({}) +const tableDict = ref<{ [key: string]: { value: string; name: string; id: string }[] }>({}) const changeLoadSituationa = (value: any, index: number, text: string, type: string, list: any[], item: string) => { if (item === '正弦信号平坦度') { if (text === '是否为基准点') { @@ -416,12 +416,12 @@ } // 获取字典 -const nominalValueUnit = ref<{ value: string;name: string;id: string }[]>([]) // 标称值单位 -const amplitudeUnit = ref<{ value: string;name: string;id: string }[]>([]) // 幅度单位 -const symbolList = ref<{ value: string;name: string;id: string }[]>([]) // 技术指标符号 -const standardVoltage = ref<{ value: string;name: string;id: string }[]>([]) // 电压单位 -const TechnicalIndexSymbolList = ref<{ value: string;name: string;id: string }[]>([]) // 技术指标前符号 -const secondList = ref<{ value: string;name: string;id: string }[]>([]) // 秒单位 +const nominalValueUnit = ref<{ value: string; name: string; id: string }[]>([]) // 标称值单位 +const amplitudeUnit = ref<{ value: string; name: string; id: string }[]>([]) // 幅度单位 +const symbolList = ref<{ value: string; name: string; id: string }[]>([]) // 技术指标符号 +const standardVoltage = ref<{ value: string; name: string; id: string }[]>([]) // 电压单位 +const TechnicalIndexSymbolList = ref<{ value: string; name: string; id: string }[]>([]) // 技术指标前符号 +const secondList = ref<{ value: string; name: string; id: string }[]>([]) // 秒单位 const fetchDict = async () => { // 标称值单位 const res1 = await getDictByCode('standardFrequencyUnit') @@ -467,22 +467,24 @@ @@ -522,11 +526,17 @@ @@ -534,17 +544,16 @@ @@ -557,11 +566,17 @@ @@ -569,25 +584,21 @@