diff --git a/src/component/rain-earthquake/ControlShowDetailComponent.vue b/src/component/rain-earthquake/ControlShowDetailComponent.vue index 35f666f..57cab5c 100644 --- a/src/component/rain-earthquake/ControlShowDetailComponent.vue +++ b/src/component/rain-earthquake/ControlShowDetailComponent.vue @@ -46,6 +46,14 @@ useStatusStore().poiLayers.showPopulationGrid.loading " /> + + + diff --git a/src/component/rain-earthquake/PopulationGridComponent.vue b/src/component/rain-earthquake/PopulationGridComponent.vue index ddd861e..20d0538 100644 --- a/src/component/rain-earthquake/PopulationGridComponent.vue +++ b/src/component/rain-earthquake/PopulationGridComponent.vue @@ -17,7 +17,7 @@ let populationLayer: ImageryLayer | null = null; onMounted(() => { - // 监听显示隐藏风险点 + // 监听显示 watch( () => useStatusStore().poiLayers.showPopulationGrid.show, (newValue: boolean) => { diff --git a/src/component/rain-earthquake/WaterPipeComponent.vue b/src/component/rain-earthquake/WaterPipeComponent.vue new file mode 100644 index 0000000..6d34d4d --- /dev/null +++ b/src/component/rain-earthquake/WaterPipeComponent.vue @@ -0,0 +1,38 @@ + + + + + + diff --git a/src/hooks/earthquake/useEarthquakeDisasterChain.ts b/src/hooks/earthquake/useEarthquakeDisasterChain.ts index 9e7cd6d..7f97727 100644 --- a/src/hooks/earthquake/useEarthquakeDisasterChain.ts +++ b/src/hooks/earthquake/useEarthquakeDisasterChain.ts @@ -231,9 +231,7 @@ export const useEarthquakeDisasterChain = () => { name: '显示管网系统', statusStore: statusStore.infrastructureLayers, statusKey: 'showNetworkSystem' as const, - callback: (status: unknown) => { - console.log('显示管网系统', status); - }, + callback: layerControl.clickWaterPipe, }, { name: '显示交通道路', diff --git a/src/hooks/rainstorm/useRainDisasterChain.ts b/src/hooks/rainstorm/useRainDisasterChain.ts index 211258c..596e380 100644 --- a/src/hooks/rainstorm/useRainDisasterChain.ts +++ b/src/hooks/rainstorm/useRainDisasterChain.ts @@ -261,9 +261,7 @@ export const useRainDisasterChain = () => { name: '显示管网系统', statusStore: statusStore.infrastructureLayers, statusKey: 'showNetworkSystem' as const, - callback: (status: unknown) => { - console.log('显示管网系统', status); - }, + callback: layerControl.clickWaterPipe, }, { name: '显示交通道路', diff --git a/src/hooks/useLayerControl.ts b/src/hooks/useLayerControl.ts index dec08d3..81c039e 100644 --- a/src/hooks/useLayerControl.ts +++ b/src/hooks/useLayerControl.ts @@ -61,6 +61,13 @@ export const useLayerControl = () => { useStatusStore().poiLayers.showPopulationGrid.loading = true; }; + /** + * 显示管网 + */ + const clickWaterPipe = () => { + useStatusStore().infrastructureLayers.showNetworkSystem.loading = true; + }; + return { clickHiddenDangerPoint, clickHospital, @@ -69,5 +76,6 @@ export const useLayerControl = () => { clickFireStation, clickStorePoints, clickPopulationGrid, + clickWaterPipe, }; };