feat: 整理 HCesiumViewerCls 相关

This commit is contained in:
严浩
2025-03-31 20:43:13 +08:00
parent 4636f9fde4
commit 2c6a4287d2
3 changed files with 15 additions and 43 deletions

View File

@@ -15,12 +15,11 @@ const groundStations = ref<GroundStationOptions[]>([
// 添加一个随机站点
const addRandomStation = () => {
const randomId = `gs-random-${Math.random().toString(36).slice(7)}`; // 使用 slice 替换 substring
const randomId = `gs-random-${Math.random().toString(36).slice(7)}`;
const randomLon = Math.random() * 360 - 180; // -180 to 180
const randomLat = Math.random() * 180 - 90; // -90 to 90
const randomHeight = Math.random() * 1000; // 0 to 1000 meters
groundStations.value.push({
// 调整属性顺序
height: randomHeight,
id: randomId,
latitude: randomLat,