diff --git a/src/enums/JwpyOrgMapping.js b/src/enums/JwpyOrgMapping.js index a6412ef..634fa40 100644 --- a/src/enums/JwpyOrgMapping.js +++ b/src/enums/JwpyOrgMapping.js @@ -34,8 +34,8 @@ export function mapOrgNameMapping(backendData, valueMapping) { const mappedName = orgMapping[item.OrganizeName] || item.OrganizeName; return { ...item, - originalName: setNameFun(item.OrganizeName) , // 保留原始名称,就是后端传送的名字 - name: mappedName, + originalName: item.OrganizeName , // 保留原始名称,就是后端传送的名字 + name: setNameFun(mappedName), value: Number(item[valueMapping] || 0), // 自定义属性 }; }); diff --git a/src/views/datav/RightsComfort.vue b/src/views/datav/RightsComfort.vue index 62bdf22..1bdc688 100644 --- a/src/views/datav/RightsComfort.vue +++ b/src/views/datav/RightsComfort.vue @@ -460,7 +460,7 @@ const getMapData = async (timeValue) => { } return { ...item, - originalName: setNameFun(item.name), // 添加原始名称 + originalName: item.name, // 添加原始名称 name: setNameFun(item.name), value: item.totalCase, }; diff --git a/src/views/datav/SceneInsp.vue b/src/views/datav/SceneInsp.vue index 6572d42..cd9d08d 100644 --- a/src/views/datav/SceneInsp.vue +++ b/src/views/datav/SceneInsp.vue @@ -979,6 +979,7 @@ const getSupervisionNotifyMapData = async () => { res.superviseTempMapVoList, "totalPro" ); + console.log('mappedData',mappedData) const total = mappedData.reduce((sum, item) => sum + Number(item.value), 0); const avg = total / mappedData.length; // 计算平均值 const range30Percent = avg * 0.3; // 不用取整,小数也可以