2026-04-13 10:30:03 +08:00
|
|
|
<template>
|
|
|
|
|
<div>
|
2026-04-14 16:00:39 +08:00
|
|
|
<!-- 基础组件 -->
|
2026-04-13 10:30:03 +08:00
|
|
|
<BasicComponent
|
|
|
|
|
:disaster-type="DisasterType.EARTHQUAKE"
|
|
|
|
|
:key="route.fullPath"
|
|
|
|
|
/>
|
2026-04-14 08:08:01 +08:00
|
|
|
|
2026-04-16 09:42:21 +08:00
|
|
|
<!-- 断裂带 -->
|
|
|
|
|
<FaultComponent
|
|
|
|
|
v-if="
|
2026-06-12 10:42:54 +08:00
|
|
|
statusStore.appLoadingCompleted &&
|
|
|
|
|
statusStore.mapLayers.faultShow.loading
|
2026-04-16 09:42:21 +08:00
|
|
|
"
|
|
|
|
|
/>
|
|
|
|
|
|
2026-04-14 16:00:39 +08:00
|
|
|
<!-- 灾害链影响列表组件 -->
|
2026-04-14 08:08:01 +08:00
|
|
|
<DisasterChainPointComponent
|
2026-04-18 16:40:04 +08:00
|
|
|
v-if="
|
2026-06-12 10:42:54 +08:00
|
|
|
statusStore.appLoadingCompleted &&
|
|
|
|
|
statusStore.uiComponents.disasterChainPointShow.loading
|
2026-04-18 16:40:04 +08:00
|
|
|
"
|
2026-06-12 11:20:57 +08:00
|
|
|
:select-options="selectOptions"
|
|
|
|
|
:table-data-list="tableDatas"
|
|
|
|
|
:table-columns="tableColumns"
|
|
|
|
|
:page-option="paginationConfig"
|
|
|
|
|
@change-conditions="changeConditions"
|
|
|
|
|
@change-current-page="changeCurrentPage"
|
2026-04-14 08:08:01 +08:00
|
|
|
/>
|
|
|
|
|
|
2026-04-14 16:00:39 +08:00
|
|
|
<!-- 左侧按钮组件 -->
|
2026-04-18 16:40:04 +08:00
|
|
|
<LeftButtonComponent
|
|
|
|
|
v-if="
|
2026-05-07 13:11:15 +08:00
|
|
|
statusStore.appLoadingCompleted &&
|
|
|
|
|
statusStore.uiComponents.leftButton.loading
|
2026-04-18 16:40:04 +08:00
|
|
|
"
|
|
|
|
|
:button-list="leftButtonInfo"
|
|
|
|
|
/>
|
2026-04-15 22:41:06 +08:00
|
|
|
|
|
|
|
|
<!-- 右侧按钮组件 -->
|
2026-04-18 16:40:04 +08:00
|
|
|
<RightButtonComponent
|
|
|
|
|
v-if="
|
2026-05-07 13:11:15 +08:00
|
|
|
statusStore.appLoadingCompleted &&
|
|
|
|
|
statusStore.uiComponents.rightButton.loading
|
2026-04-18 16:40:04 +08:00
|
|
|
"
|
|
|
|
|
:button-list="rightButtonInfo"
|
|
|
|
|
/>
|
2026-04-15 22:41:06 +08:00
|
|
|
|
|
|
|
|
<!-- 控制显示组件 -->
|
|
|
|
|
<ControlShowComponent :constrol-show-list="controlPanel" />
|
2026-04-18 16:40:04 +08:00
|
|
|
|
|
|
|
|
<!-- 控制显示详情组件 -->
|
|
|
|
|
<ControlShowDetailComponent />
|
2026-04-13 10:30:03 +08:00
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script setup lang="ts">
|
2026-04-16 09:42:21 +08:00
|
|
|
import FaultComponent from '@/component/earthquake/FaultComponent.vue';
|
2026-04-13 10:30:03 +08:00
|
|
|
import BasicComponent from '@/component/rain-earthquake/BasicComponent.vue';
|
2026-04-15 22:41:06 +08:00
|
|
|
import ControlShowComponent from '@/component/rain-earthquake/ControlShowComponent.vue';
|
2026-04-18 16:40:04 +08:00
|
|
|
import ControlShowDetailComponent from '@/component/rain-earthquake/ControlShowDetailComponent.vue';
|
2026-04-14 08:08:01 +08:00
|
|
|
import DisasterChainPointComponent from '@/component/rain-earthquake/DisasterChainPointComponent.vue';
|
2026-04-14 16:00:39 +08:00
|
|
|
import LeftButtonComponent from '@/component/rain-earthquake/LeftButtonComponent.vue';
|
2026-04-15 22:41:06 +08:00
|
|
|
import RightButtonComponent from '@/component/rain-earthquake/RightButtonComponent.vue';
|
2026-04-14 08:08:01 +08:00
|
|
|
import { useEarthquakeDisasterChain } from '@/hooks/earthquake/useEarthquakeDisasterChain';
|
2026-06-12 11:20:57 +08:00
|
|
|
import {
|
|
|
|
|
useDisasterChainTable,
|
|
|
|
|
type SearchConditions,
|
|
|
|
|
} from '@/hooks/useDisasterChainTable';
|
2026-04-16 09:32:33 +08:00
|
|
|
import { useStatusStore } from '@/stores/useStatusStore';
|
2026-06-12 10:42:54 +08:00
|
|
|
import { DisasterType, PointType } from '@/types/common/DisasterType.ts';
|
|
|
|
|
import { onBeforeMount } from 'vue';
|
2026-04-13 10:30:03 +08:00
|
|
|
import { useRoute } from 'vue-router';
|
|
|
|
|
|
|
|
|
|
const route = useRoute();
|
2026-04-14 08:08:01 +08:00
|
|
|
|
2026-06-12 10:42:54 +08:00
|
|
|
const { leftButtonInfo, rightButtonInfo, controlPanel } =
|
|
|
|
|
useEarthquakeDisasterChain();
|
2026-04-14 08:08:01 +08:00
|
|
|
|
2026-05-07 13:11:15 +08:00
|
|
|
const statusStore = useStatusStore();
|
|
|
|
|
|
2026-06-12 11:20:57 +08:00
|
|
|
const {
|
|
|
|
|
selectOptions,
|
|
|
|
|
tableColumns,
|
|
|
|
|
tableDatas,
|
|
|
|
|
paginationConfig,
|
|
|
|
|
changeConditions,
|
|
|
|
|
setConditions,
|
|
|
|
|
changeCurrentPage,
|
|
|
|
|
setSelectOptions,
|
|
|
|
|
setTableColumns,
|
|
|
|
|
} = useDisasterChainTable();
|
2026-06-12 10:42:54 +08:00
|
|
|
|
|
|
|
|
onBeforeMount(() => {
|
2026-06-12 11:20:57 +08:00
|
|
|
// 设置下拉选项
|
|
|
|
|
setSelectOptions([
|
2026-06-12 10:42:54 +08:00
|
|
|
{ value: PointType.LANDSLIDE, label: '滑坡' },
|
|
|
|
|
{ value: PointType.DEBRIS_FLOW, label: '泥石流' },
|
|
|
|
|
{ value: PointType.RISK_AREA, label: '风险区' },
|
2026-06-12 11:20:57 +08:00
|
|
|
]);
|
2026-06-12 10:42:54 +08:00
|
|
|
|
2026-06-12 11:20:57 +08:00
|
|
|
// 设置表格列配置
|
|
|
|
|
setTableColumns([
|
2026-06-12 10:42:54 +08:00
|
|
|
{ title: '名称', key: 'disasterName' },
|
|
|
|
|
{ title: '位置', key: 'position' },
|
|
|
|
|
{ title: '规模等级', key: 'scaleGrade' },
|
|
|
|
|
{ title: '险情等级', key: 'riskGrade' },
|
2026-06-12 11:20:57 +08:00
|
|
|
]);
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 条件改变执行
|
|
|
|
|
* @param value
|
|
|
|
|
*/
|
|
|
|
|
changeConditions.value = (value: SearchConditions) => {
|
|
|
|
|
setConditions(value);
|
|
|
|
|
};
|
2026-06-12 10:42:54 +08:00
|
|
|
});
|
2026-04-13 10:30:03 +08:00
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style scoped></style>
|