系統監控 : 模型改用main_id來當spriteDbId 、 2D定位點預設顏色改成#009100

This commit is contained in:
koko 2024-12-02 09:32:07 +08:00
parent 4ab4aeb7f0
commit 4063c6a92d
2 changed files with 4 additions and 4 deletions

View File

@ -63,11 +63,11 @@ const getData = async () => {
...dev,
forge_dbid: parseInt(dev.forge_dbid),
room_dbid: parseInt(dev.room_dbid),
device_coordinate_3d: JSON.parse(dev.device_coordinate_3d),
device_coordinate_3d: dev.device_coordinate_3d ? JSON.parse(dev.device_coordinate_3d) : "",
alarmMsg: "",
is_show: true,
currentColor: dev.device_normal_point_color,
spriteDbId: 10 + index,
spriteDbId: 10 + dev.main_id,
sensorTypes: dev.points.map(({ points }) => points),
floor_guid: d.floor_guid,
is2DActive: false

View File

@ -36,7 +36,7 @@ const defaultOption = (map, data = []) => {
...sameOption,
symbolSize: 10,
itemStyle: {
color: data?.[0]?.[3]?.device_normal_color || "#b02a02",
color: data?.[0]?.[3]?.device_normal_color || "#009100",
},
data,
},
@ -44,7 +44,7 @@ const defaultOption = (map, data = []) => {
...sameOption,
symbolSize: 20,
itemStyle: {
color: data?.[0]?.[3]?.device_normal_color || "#b02a02",
color: data?.[0]?.[3]?.device_normal_color || "#009100",
},
data: [],
}