吉安感知网项目-前端
罗广辉
2026-01-26 beb95fb5fc166804056abafd70fc01ac27de7621
Merge remote-tracking branch 'origin/master'
4 files modified
53 ■■■■■ changed files
applications/mobile-web-view/src/appComponents/workMap/index.vue 7 ●●●●● patch | view | raw | blame | history
applications/mobile-web-view/src/appPages/work/workDetail/mapWork/index.vue 32 ●●●● patch | view | raw | blame | history
applications/task-work-order/src/api/zkxt/index.js 11 ●●●●● patch | view | raw | blame | history
uniapps/work-app/src/subPackages/workDetail/index.vue 3 ●●●● patch | view | raw | blame | history
applications/mobile-web-view/src/appComponents/workMap/index.vue
@@ -291,10 +291,11 @@
watch(
    () => mapCurrentDetail,
    newVal => {
const newDataMap=JSON.parse(newVal)
        // 只有 workNavigationShow 为 true 且有经纬度时才添加标记
        if (workNavigationShow && newVal?.longitude && newVal?.latitude) {
            addIncidentMarker(newVal)
            mapCurrentDetailData.value = newVal
        if (workNavigationShow && newDataMap?.longitude && newDataMap?.latitude) {
            addIncidentMarker(newDataMap)
            mapCurrentDetailData.value = newDataMap
        } else if (!workNavigationShow && incidentMarker) {
            // 当 workNavigationShow 变为 false 时,移除已添加的标记
            markersLayer.removeLayer(incidentMarker)
applications/mobile-web-view/src/appPages/work/workDetail/mapWork/index.vue
@@ -27,36 +27,12 @@
const route = useRoute()
const mapCurrentDetail = ref({})
const eventNum = ref('')
// 机巢数据
let machineData = ref([]);
// 机巢数据
const handleNodeClick = async data => {
  const droneList = await getDeviceRegion({ areaCode: userInfo.value.detail.areaCode });
  machineData.value = droneList?.data?.data;
};
const getDataList = async val => {
    const params = {
        current: 1,
        size: 9999,
        source: 1,
        event_name: val,
    }
    const res = await getList(params)
    const response = res.data.data.records
  const matchedMachine = machineData.value.find(m => m.device_sn === response[0].device_sn);
  const deviceNickname = matchedMachine?.nickname || ''
    mapCurrentDetail.value = {
        ...response[0],
        processingDetail: response[0].processing_details,
        update_photo_url: response[0].update_photo_url,
        aiType: response[0].ai_type_key_list?.join(',') || '',
    device_names:deviceNickname ? deviceNickname :''
    }
}
onMounted(async () => {
  // handleNodeClick()
    eventNum.value = route.query.currentItem
    // await getDataList(eventNum.value)
    mapCurrentDetail.value = eventNum.value
})
</script>
applications/task-work-order/src/api/zkxt/index.js
@@ -18,3 +18,14 @@
        data:{"size":100,"current":1},
    })
}
// 获取飞手信息
export const deviceFlyerApi = (data) => {
    return request({
        url: `/deviceFlyer/deviceFlyer/queryList`,
        method: 'post',
        data: data,
    })
}
uniapps/work-app/src/subPackages/workDetail/index.vue
@@ -146,8 +146,9 @@
})
// 跳转地图
const jumpMap = item => {
  const contactStr = encodeURIComponent(JSON.stringify(item))
  uni.navigateTo({
    url: `/subPackages/workDetail/mapWork/index?eventNum=${item.event_num}`,
    url: `/subPackages/workDetail/mapWork/index?eventNum=${contactStr}`,
  })
}
// 退回