feat(location):为位置节点添加坐标信息

- 在 EmsLocationServiceImpl 中设置节点的 X 和 Y 坐标
- 更新 LocationTreeNodeVo 类以支持存储 X 和 Y 坐标
- 优化设备列表的包引用路径
This commit is contained in:
2025-10-15 11:13:46 +08:00
parent 4a2e0c37f3
commit b843776a7f
2 changed files with 6 additions and 2 deletions

View File

@@ -13,5 +13,7 @@ public class LocationTreeNodeVo {
private Long parentId;
private String path;
private List<LocationTreeNodeVo> children;
private List<com.klp.ems.domain.vo.EmsAlarmDeviceVo> devices;
}
private List<EmsAlarmDeviceVo> devices;
private Integer x;
private Integer y;
}

View File

@@ -143,6 +143,8 @@ public class EmsLocationServiceImpl implements IEmsLocationService {
node.setName(vo.getName());
node.setParentId(vo.getParentId());
node.setPath(path);
node.setX(vo.getX());
node.setY(vo.getY());
List<EmsLocationVo> children = parent2children.get(vo.getLocationId());
if (children == null || children.isEmpty()) {