| | |
| | | :loading="loading" |
| | | @search="onSearch" |
| | | ></SatelliteSearchBar> |
| | | |
| | | <!-- <el-row class="m-b-8"> |
| | | <el-button |
| | | type="primary" |
| | | class="el-button-custom" |
| | | size="small" |
| | | @click="handleRankClick" |
| | | > |
| | | {{ rankVisible ? '隐藏排名' : '显示排名' }} |
| | | </el-button> |
| | | <el-button |
| | | type="primary" |
| | | class="el-button-custom" |
| | | size="small" |
| | | @click="handleDataClick" |
| | | > |
| | | {{ dataVisible ? '隐藏数据' : '显示数据' }} |
| | | </el-button> |
| | | <el-button |
| | | type="primary" |
| | | class="el-button-custom" |
| | | size="small" |
| | | @click="handleColorClick" |
| | | > |
| | | {{ isStandardColor ? '绘制对比色' : '绘制标准色' }} |
| | | </el-button> |
| | | <el-button |
| | | type="primary" |
| | | class="el-button-custom" |
| | | size="small" |
| | | @click="handleOpacityClick" |
| | | > |
| | | {{ !isOpacity ? '透明化' : '取消透明化' }} |
| | | </el-button> |
| | | </el-row> --> |
| | | <el-table |
| | | :data="gridDataList" |
| | | table-layout="fixed" |
| | |
| | | align="center" |
| | | width="50" |
| | | /> |
| | | <!-- <el-table-column type="expand"> |
| | | <template #default="props"> |
| | | |
| | | </template> |
| | | </el-table-column> --> |
| | | <el-table-column |
| | | prop="dataTime" |
| | | label="时间" |
| | |
| | | import { ref } from 'vue'; |
| | | import moment from 'moment'; |
| | | import SatelliteSearchBar from './SatelliteSearchBar.vue'; |
| | | import { useFetchData } from '@/composables/fetchData'; |
| | | import gridApi from '@/api/gridApi'; |
| | | import SatelliteProxy from '../SatelliteProxy'; |
| | | // import { useFetchData } from '@/composables/fetchData'; |
| | | // import gridApi from '@/api/gridApi'; |
| | | |
| | | // eslint-disable-next-line no-unused-vars |
| | | function timeFormatter(row, col, cellValue, index) { |
| | |
| | | } |
| | | }); |
| | | |
| | | const emits = defineEmits(['search', 'rowClick']); |
| | | // const rankVisible = ref(false); |
| | | // const dataVisible = ref(false); |
| | | // const isStandardColor = ref(true); |
| | | // const isOpacity = ref(false); |
| | | |
| | | // const { loading, fetchData } = useFetchData(10000); |
| | | // // 网格信息 |
| | | // let gridInfo = []; |
| | | // // 网格数据组 |
| | | // const gridDataList = ref([]); |
| | | // // 网格数据详情 |
| | | // const gridDataDetailMap = new Map(); |
| | | // // 地图网格相关对象 |
| | | // let mapViews; |
| | | const emits = defineEmits([ |
| | | 'search', |
| | | 'rowClick', |
| | | 'showRank', |
| | | 'showData', |
| | | 'changeColor' |
| | | ]); |
| | | |
| | | // 查询网格信息和遥感数据组 |
| | | function onSearch(options) { |
| | | emits('search', options); |
| | | } |
| | | |
| | | // // 获取网格信息 |
| | | // function fetchGridCell(groupId) { |
| | | // return fetchData(() => { |
| | | // return gridApi.fetchGridCell(groupId).then((res) => { |
| | | // gridInfo = res.data; |
| | | // drawGrid(gridInfo); |
| | | // }); |
| | | // }); |
| | | // function handleRankClick() { |
| | | // rankVisible.value = !rankVisible.value; |
| | | // emits('showRank', rankVisible.value); |
| | | // } |
| | | |
| | | // // 获取遥感数据组 |
| | | // function fetchGridData(groupId) { |
| | | // return gridApi.fetchGridData(groupId).then((res) => { |
| | | // gridDataList.value = res.data; |
| | | // }); |
| | | // function handleDataClick() { |
| | | // dataVisible.value = !dataVisible.value; |
| | | // emits('showData', dataVisible.value); |
| | | // } |
| | | |
| | | // function drawGrid(gridInfo) { |
| | | // SatelliteProxy.clearAll(mapViews); |
| | | // mapViews = SatelliteProxy.drawPolyline(gridInfo); |
| | | // function handleColorClick() { |
| | | // isStandardColor.value = !isStandardColor.value; |
| | | // emits('changeColor', isStandardColor.value); |
| | | // } |
| | | |
| | | // // 绘制网格遥感数据值和网格颜色 |
| | | // function drawTextAndColor(gridData) { |
| | | // // SatelliteProxy.clearText(mapViews); |
| | | // // 文本标记 |
| | | // mapViews.textViews = SatelliteProxy.drawDataText( |
| | | // mapViews.points, |
| | | // gridData, |
| | | // mapViews.textViews |
| | | // ); |
| | | // SatelliteProxy.drawColor(mapViews.gridViews, gridData); |
| | | // function handleOpacityClick() { |
| | | // isOpacity.value = !isOpacity.value; |
| | | // emits('changeOpacity', isOpacity.value); |
| | | // } |
| | | |
| | | function handleRowClick(row, col, event) { |