This commit is contained in:
qqGroup0 2023-06-06 14:51:53 +08:00
commit 1b9d9a5197
1 changed files with 8 additions and 3 deletions

View File

@ -121,7 +121,9 @@ import { ref, reactive, watch, defineExpose, onMounted,defineEmits } from 'vue';
import { rs, submit ,rs2 } from '/@/api/crawl/index'; import { rs, submit ,rs2 } from '/@/api/crawl/index';
import { useUserInfo } from '/@/stores/userInfo'; import { useUserInfo } from '/@/stores/userInfo';
import { ElMessage, ElMessageBox } from "element-plus"; import { ElMessage, ElMessageBox } from "element-plus";
import { useVariableStore } from '/@/stores/index.ts';
import { getList as BizDict } from "/@/api/system/dictbiz.js"; import { getList as BizDict } from "/@/api/system/dictbiz.js";
const variableStore = useVariableStore();
const userInfo = useUserInfo(); const userInfo = useUserInfo();
const emit = defineEmits(['response']); const emit = defineEmits(['response']);
const disabledDate = (time) => { const disabledDate = (time) => {
@ -219,7 +221,6 @@ const onMapClick = (e) => {
Lat: state.lat, Lat: state.lat,
Lng: state.lon Lng: state.lon
}) })
// changeLatLon(e)
} }
const changeLatLon = (e) => { const changeLatLon = (e) => {
@ -318,13 +319,17 @@ const startCrawl = () => {
ElMessage.error("Please select the search end time") ElMessage.error("Please select the search end time")
return; return;
} }
if (state.coordinateList.length == 0 || !state.coordinateList[0].Lat || !state.coordinateList[0].Lng || !state.coordinateList[1].Lat || !state.coordinateList[1].Lng) { if ((state.coordinateList.length == 0 || !state.coordinateList[0].Lat || !state.coordinateList[0].Lng || !state.coordinateList[1].Lat || !state.coordinateList[1].Lng)&&state.switch) {
ElMessage.error("Please draw the area on the map")
return;
}
if(!state.switch&&variableStore.layerGroupPoly==null){
ElMessage.error("Please draw the area on the map") ElMessage.error("Please draw the area on the map")
return; return;
} }
var ranges = state.coordinateList[0].Lat + ' ' + state.coordinateList[0].Lng + ',' + state.coordinateList[1].Lat + ' ' + state.coordinateList[1].Lng var ranges =state.switch? state.coordinateList[0].Lat + ' ' + state.coordinateList[0].Lng + ',' + state.coordinateList[1].Lat + ' ' + state.coordinateList[1].Lng:variableStore.layerGroupPoly;
var param = [] var param = []
state.satelliteSelected.forEach(data=>{ state.satelliteSelected.forEach(data=>{