修改基础的一些配置
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { ref, watch } from 'vue';
|
||||
import { ref } from 'vue';
|
||||
import type { XianHiddenDangerSpots } from '@/types/base/XianHiddenDangerSpots';
|
||||
import { HiddenPointType } from '@/types/common/DisasterType';
|
||||
import type { PaginationType } from '@/types/common/PaginationType';
|
||||
import { PointType } from '@/types/common/DisasterType';
|
||||
|
||||
/**
|
||||
* 暴雨灾害链影响点列表钩子函数
|
||||
@@ -13,17 +13,17 @@ export const useRainDisasterChain = () => {
|
||||
*/
|
||||
const conditions = ref({
|
||||
tableData: '',
|
||||
hiddenPoint: HiddenPointType.LANDSLIDE,
|
||||
hiddenPoint: PointType.LANDSLIDE,
|
||||
});
|
||||
|
||||
/**
|
||||
* 下拉选项
|
||||
*/
|
||||
const selectOptions = [
|
||||
{ value: HiddenPointType.LANDSLIDE, label: '滑坡' },
|
||||
{ value: HiddenPointType.DEBRIS_FLOW, label: '泥石流' },
|
||||
{ value: HiddenPointType.FLASH_FLOOD, label: '山洪' },
|
||||
{ value: HiddenPointType.WATERLOGGING, label: '内涝' },
|
||||
{ value: PointType.LANDSLIDE, label: '滑坡' },
|
||||
{ value: PointType.DEBRIS_FLOW, label: '泥石流' },
|
||||
{ value: PointType.FLASH_FLOOD, label: '山洪' },
|
||||
{ value: PointType.WATER_LOGGING, label: '内涝' },
|
||||
];
|
||||
|
||||
/**
|
||||
@@ -57,7 +57,7 @@ export const useRainDisasterChain = () => {
|
||||
*/
|
||||
function changeConditions(value: {
|
||||
tableData: string;
|
||||
hiddenPoint: HiddenPointType;
|
||||
hiddenPoint: PointType;
|
||||
}): void {
|
||||
conditions.value = value;
|
||||
}
|
||||
@@ -70,15 +70,6 @@ export const useRainDisasterChain = () => {
|
||||
paginationConfig.value.currentPage = value;
|
||||
}
|
||||
|
||||
// 监听条件变化
|
||||
watch(
|
||||
conditions,
|
||||
() => {
|
||||
console.log('条件改变');
|
||||
},
|
||||
{ deep: true }
|
||||
);
|
||||
|
||||
// 把所有需要用到的数据/方法 return 出去
|
||||
return {
|
||||
conditions,
|
||||
|
||||
Reference in New Issue
Block a user