巡查添加点击事件交互
parent
2a5e9e48b0
commit
0e4f422275
|
|
@ -1,5 +1,5 @@
|
|||
<template>
|
||||
<div class="go-title-xuncha">
|
||||
<div class="go-title-xuncha" @click="clickBtn">
|
||||
<img class="img" src="@/assets/images/chart/xunchaguiji/back.png" />
|
||||
<span class="span">返回</span>
|
||||
</div>
|
||||
|
|
@ -8,7 +8,10 @@
|
|||
<script setup lang="ts">
|
||||
import { PropType, toRefs } from 'vue'
|
||||
import { CreateComponentType } from '@/packages/index.d'
|
||||
import { useChartEditStore } from '@/store/modules/chartEditStore/chartEditStore';
|
||||
import { eventHandlerHook } from '@/hooks/eventHandler.hook';
|
||||
|
||||
const chartEditStore = useChartEditStore();
|
||||
const props = defineProps({
|
||||
chartConfig: {
|
||||
type: Object as PropType<CreateComponentType>,
|
||||
|
|
@ -21,6 +24,14 @@ const {
|
|||
textColor,
|
||||
textSize,
|
||||
} = toRefs(props.chartConfig.option)
|
||||
// 单击交互
|
||||
const clickBtn = () => {
|
||||
eventHandlerHook(
|
||||
chartEditStore.getComponentList,
|
||||
props.chartConfig.events.interactConfigEvents,
|
||||
'click'
|
||||
);
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
|
|
|||
|
|
@ -1,16 +1,6 @@
|
|||
<template>
|
||||
<div class="go-title-xuncha">
|
||||
<div class="selbox">
|
||||
<!-- <n-tree-select
|
||||
v-model:value="areaValue"
|
||||
:options="areaOptions"
|
||||
label-field="name"
|
||||
key-field="id"
|
||||
children-field="children"
|
||||
placeholder="请选择行政区划"
|
||||
clearable
|
||||
style="width: 240px"
|
||||
/> -->
|
||||
<el-tree-select
|
||||
v-model="areaValue"
|
||||
:data="areaOptions"
|
||||
|
|
@ -78,8 +68,12 @@ import { EventBus } from '@/utils/eventBus'
|
|||
import axios from 'axios'
|
||||
import * as mars3d from "mars3d";
|
||||
import { getAppEnvConfig } from '@/utils/env'
|
||||
var { VITE_GLOB_API_URL } = getAppEnvConfig();
|
||||
import { useChartEditStore } from '@/store/modules/chartEditStore/chartEditStore';
|
||||
import { eventHandlerHook } from '@/hooks/eventHandler.hook';
|
||||
|
||||
const chartEditStore = useChartEditStore();
|
||||
|
||||
var { VITE_GLOB_API_URL } = getAppEnvConfig();
|
||||
const props = defineProps({
|
||||
chartConfig: {
|
||||
type: Object as PropType<CreateComponentType>,
|
||||
|
|
@ -150,6 +144,11 @@ const getAreaListData=(id)=>{
|
|||
})
|
||||
}
|
||||
const lisClick=(e)=>{
|
||||
eventHandlerHook(
|
||||
chartEditStore.getComponentList,
|
||||
props.chartConfig.events.interactConfigEvents,
|
||||
'click'
|
||||
);
|
||||
EventBus.emit('clockinlistsenddata' , e);
|
||||
if(entityArr.value.length>0){
|
||||
entityArr.value.forEach(item =>{
|
||||
|
|
|
|||
Loading…
Reference in New Issue