罗广辉
2026-05-15 e3c2cd23253f3501be7d31e03955fbb6f4aa3556
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<template>
  <view class="task-details">
    <view>
      <web-view
        ref="sWebViewRef"
        :src='`${viewUrl}?token=${token}&wayLineJobInfoId=${active.id}`'
        @message="onPostMessage"
        @onPostMessage="onPostMessage"
      />
    </view>
    <view>
      <view>任务内容</view>
      <view>任务编号:{{taskData.job_info_num  }}</view>
      <view>任务名称:{{ taskData.name }}</view>
      <view>任务类型:{{ taskData.industry_type_str }}</view>
      <view>飞行事件:{{  }}</view>
      <view>所属单位:{{ taskData.dept_name }}</view>
      <view>所属机巢:{{ taskData.device_names }}</view>
      <view>任务时间:{{ taskData.cycle_time_value }}</view>
      <view>任务频次:{{  }}</view>
      <view>关联算法:{{  }}</view>
      <view>任务描述:{{ taskData.reason }}</view>
    </view>
  </view>
</template>
 
<script setup>
 
import {useUserStore} from "@/store/index.js";
const active = defineModel('active')
const sWebViewRef = ref(null)
const viewUrl = 'http://192.168.1.15:5173/drone-app-web-view/#/appTaskDetails'
const userStore = useUserStore()
const token = computed(() => userStore?.userInfo?.access_token)
 
import {onLoad} from "@dcloudio/uni-app";
 
function onPostMessage(event) {
  if (event.detail.data[0].type === 'back'){
    active.value = null
  }
}
// 获取传参
const taskData = ref({})
 
onLoad((options)=>{
  taskData.value = JSON.parse(decodeURIComponent(options.rowItem))
})
 
 
</script>
 
<style scoped lang="scss">
.task-details {
}
</style>