点击开始展示云查询

dianlixunjian
Zhufu 2024-08-01 10:05:03 +08:00
parent a275ddaae4
commit 20f0f9a048
4 changed files with 31 additions and 3 deletions

View File

@ -2,7 +2,9 @@ import { defHttp } from '@/utils/http/axios';
enum Api {
// 添加云查询任务
AddDroneTask = '/api/DroneCloudQuery/AddDroneTask'
AddDroneTask = '/api/DroneCloudQuery/AddDroneTask',
// 根据云查询ID获取查询结果
LoadCloudQueryById = '/api/DroneCloudQuery/LoadCloudQueryById'
}
export function AddDroneTask(params: { geomid: string }) {
@ -10,4 +12,10 @@ export function AddDroneTask(params: { geomid: string }) {
url: Api.AddDroneTask,
params,
});
}
export function LoadCloudQueryById(params: { id: string }) {
return defHttp.get({
url: Api.LoadCloudQueryById,
params,
});
}

View File

@ -1243,6 +1243,7 @@
}else{
let geomidStr = props.geomsList.map(item => item.key).join(',')
AddDroneTask({geomid:geomidStr}).then(res => {
message.success('成功提交云查询')
useCloudQuery.setIdentification(true);
})
}

View File

@ -106,6 +106,7 @@
import CloudQueryModal from '@/views/dashboard/test/SearchMenu/CloudQueryModal/index.vue';
import Icon from '@/components/Icon/Icon.vue';
import { useCloudQueryStore } from '@/store/modules/cloudquery';
import { LoadCloudQueryById } from '@/api/demo/cloudQuery.ts'
const flowWfDataStore = flowStore();
const useCloudQuery = useCloudQueryStore();
@ -246,8 +247,12 @@
}
//
function handCloudQuery() {
open.value = true;
closeCloudQuery();
let id = useCloudQuery.getCloudQueryInfo.id
LoadCloudQueryById({id}).then(res => {
useCloudQuery.setCloudQueryModalInfo(res)
open.value = true;
closeCloudQuery();
})
}
function closeCloudQuery() {
cloudQueryVisible.value = false;

View File

@ -7,6 +7,14 @@ export const useCloudQueryStore = defineStore({
identification: false,
// 云查询信息
cloudqueryInfo: {},
// 云查询结果展示
cloudQueryModalInfo: {
basicQuery:{
landClassify:{},
plowLandOccupy:{},
},
timeImages:{},
},
}),
getters: {
getCloudQueryInfo: (state) => {
@ -15,6 +23,9 @@ export const useCloudQueryStore = defineStore({
getIdentification: (state) => {
return state.identification;
},
getCloudQueryModalInfo: (state) => {
return state.cloudQueryModalInfo;
}
},
actions: {
setCloudQueryInfo(info: any) {
@ -23,5 +34,8 @@ export const useCloudQueryStore = defineStore({
setIdentification(state: boolean) {
this.identification = state;
},
setCloudQueryModalInfo(data: any){
this.cloudQueryModalInfo = data;
}
},
});