diff --git a/src/mes/common/siderInfoComponent/index.js b/src/mes/common/siderInfoComponent/index.js index 07a6552..b9400be 100644 --- a/src/mes/common/siderInfoComponent/index.js +++ b/src/mes/common/siderInfoComponent/index.js @@ -641,7 +641,20 @@ const DeviceTargetInfoComponent = () => { .filter(col => col?.bVisible === 1) .map(col => col.sName) ); - const result = showConfig.filter(field => visibleFieldNames.has(field.sName)); // 筛选数据 + const list = sColumnConfig + .slice(1) + .filter(col => col?.bVisible === 1) + const listMap = new Map(list.map(x => [x.sName, x])) + // const result = showConfig.filter(field => visibleFieldNames.has(field.sName)); // 筛选数据 + const result = showConfig + .filter(item => item?.sName != null && listMap.has(item.sName)) + .map(item => { + const matched = listMap.get(item.sName); + return { + ...item, + showName: matched.showName, + }; + }); return (