Explorar el Código

map change

tags/v1.2.0
lixin hace 1 año
padre
commit
340b2bceb1
Se han modificado 4 ficheros con 8 adiciones y 16 borrados
  1. +1
    -2
      src/views/dashboard/components/FireAlarm.vue
  2. +3
    -6
      src/views/dashboard/components/OneMap.vue
  3. +3
    -6
      src/views/dashboard/components/Underlay.vue
  4. +1
    -2
      src/views/dashboard/components/WarningDrawer.vue

+ 1
- 2
src/views/dashboard/components/FireAlarm.vue Ver fichero

@@ -257,8 +257,8 @@ export default {

if (res.code === 0) {
getRecord(parseInt(data.warningInfo?.id))
handleExecute(parseInt(data.missionId))
}
handleExecute(parseInt(data.missionId))
}

// 忽略预警
@@ -285,7 +285,6 @@ export default {
}

const handleExecute = (id) => {
// console.log(id)
emit('start', id)
}


+ 3
- 6
src/views/dashboard/components/OneMap.vue Ver fichero

@@ -31,7 +31,7 @@

<fire-alarm ref="Warning" :data="warningDetail" :airport="airportsAll" @start="handleExecute" />

<WarningDrawer v-model:visible="drawerShow" />
<WarningDrawer :id="missionId" v-model:visible="drawerShow" />

</template>

@@ -677,11 +677,9 @@ export default {
monitorVideo.value?.disposeVideo()
}

let abc = ref()
const handleExecute = (id) => {
data.drawerShow = true
abc = id
provide('test', abc)
data.missionId = id
}

onMounted(() => {
@@ -712,8 +710,7 @@ export default {
hideProblemInfo,
getMaxZOverlay,
Warning,
handleExecute,
abc
handleExecute
}
}
}

+ 3
- 6
src/views/dashboard/components/Underlay.vue Ver fichero

@@ -4,7 +4,7 @@

<script>

import { reactive, toRefs, onMounted, computed, watch, onBeforeUnmount, inject, ref } from 'vue'
import { reactive, toRefs, onMounted, computed, watch, onBeforeUnmount } from 'vue'
import { Map, View, Feature } from 'ol'
import 'ol/ol.css'
import { Tile, Vector as VectorLayer } from 'ol/layer'
@@ -25,7 +25,7 @@ export default {
type: String,
default: 'underlay'
},
data: {
idd: {
type: Number,
default: 0
}
@@ -47,10 +47,7 @@ export default {
}
})

let abc = ref()
abc = inject('test')

watch(() => abc, (value) => {
watch(() => props.idd, (value) => {
if (value) {
console.log('hhh', value)
} else {

+ 1
- 2
src/views/dashboard/components/WarningDrawer.vue Ver fichero

@@ -55,7 +55,7 @@

</div>
<div ref="mapRef" class="warn__back">
<Underlay />
<Underlay :idd="missionId" />
</div>
<div ref="videoRef" class="inner">
111111111111
@@ -165,7 +165,6 @@ export default defineComponent({
watch(() => props.id, (id) => {
if (id) {
data.missionId = id
console.log(data.missionId)
}
})


Cargando…
Cancelar
Guardar