Compare commits
No commits in common. "68660700ed1b85b26c902946afc45a7294e35faf" and "e33df64a8ace9766fc87a6863e413ec8dee15918" have entirely different histories.
68660700ed
...
e33df64a8a
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="AI预警处理结果"
|
title="AI预警处理结果"
|
||||||
:table-data="[]"
|
:table-data="[]"
|
||||||
:table-columns="[]"
|
:table-columns="[]"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="管控情况"
|
title="管控情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="管控情况"
|
title="管控情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="调度区县情况"
|
title="调度区县情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
@ -133,6 +133,7 @@ const handleCurrentChange = (val) => {
|
|||||||
|
|
||||||
// 获取数据
|
// 获取数据
|
||||||
const fetchData = async () => {
|
const fetchData = async () => {
|
||||||
|
try {
|
||||||
const res = await request({
|
const res = await request({
|
||||||
url: '/snow-ops-platform/weather-warning/scheduling-county-record',
|
url: '/snow-ops-platform/weather-warning/scheduling-county-record',
|
||||||
method: 'GET',
|
method: 'GET',
|
||||||
@ -149,22 +150,13 @@ const fetchData = async () => {
|
|||||||
const data = res.data
|
const data = res.data
|
||||||
tableData.value = data.map((item, index) => {
|
tableData.value = data.map((item, index) => {
|
||||||
// 解析 command 字段中的 JSON 数据
|
// 解析 command 字段中的 JSON 数据
|
||||||
let commandData = {
|
let commandData = {}
|
||||||
userName: '',
|
|
||||||
userPhone: '',
|
|
||||||
type: '',
|
|
||||||
role: '',
|
|
||||||
}
|
|
||||||
if (item.command) {
|
|
||||||
// 判断是否为JSON字符串
|
|
||||||
try {
|
try {
|
||||||
const parsed = JSON.parse(item.command)
|
if (item.command) {
|
||||||
if (typeof parsed === 'object' && parsed !== null) {
|
commandData = JSON.parse(item.command)
|
||||||
commandData = parsed
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
console.error('解析 command 字段失败:', error)
|
|
||||||
}
|
}
|
||||||
|
} catch (e) {
|
||||||
|
console.error('解析 command 字段失败:', e)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 根据 type 映射类型和角色
|
// 根据 type 映射类型和角色
|
||||||
@ -190,6 +182,9 @@ const fetchData = async () => {
|
|||||||
tableData.value = []
|
tableData.value = []
|
||||||
total.value = 0
|
total.value = 0
|
||||||
}
|
}
|
||||||
|
} catch (error) {
|
||||||
|
console.error('获取调度区县详情数据失败:', error)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 监听visible变化
|
// 监听visible变化
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="调度区县情况"
|
title="调度区县情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="详情"
|
title="详情"
|
||||||
:table-data="[]"
|
:table-data="[]"
|
||||||
:table-columns="[]"
|
:table-columns="[]"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
:title="props.title"
|
:title="props.title"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="抽查人次"
|
title="抽查人次"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
@ -8,10 +8,9 @@
|
|||||||
:total="total"
|
:total="total"
|
||||||
:current-page="currentPage"
|
:current-page="currentPage"
|
||||||
:page-size="pageSize"
|
:page-size="pageSize"
|
||||||
:max-width="800"
|
max-width="800px"
|
||||||
@size-change="handleSizeChange"
|
@size-change="handleSizeChange"
|
||||||
@current-change="handleCurrentChange"
|
@current-change="handleCurrentChange"
|
||||||
@update:visible="handleClose"
|
|
||||||
@close="handleClose"
|
@close="handleClose"
|
||||||
>
|
>
|
||||||
<!-- 筛选区域 -->
|
<!-- 筛选区域 -->
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="影响点详情"
|
title="影响点详情"
|
||||||
:table-data="[]"
|
:table-data="[]"
|
||||||
:table-columns="[]"
|
:table-columns="[]"
|
||||||
@ -102,13 +102,17 @@
|
|||||||
<div class="detail-row">
|
<div class="detail-row">
|
||||||
<span class="detail-label">现场情况描述:</span>
|
<span class="detail-label">现场情况描述:</span>
|
||||||
<span class="detail-value">{{ record.description }}</span>
|
<span class="detail-value">{{ record.description }}</span>
|
||||||
<div v-if="record.image" class="detail-image" v-for="(img, index) in record.image" :key="index" @click="previewImage(img)">
|
<!-- <div
|
||||||
<img :src="img" alt="" />
|
v-if="record.image"
|
||||||
</div>
|
class="detail-image"
|
||||||
|
@click="previewImage(record.image)"
|
||||||
|
>
|
||||||
|
<img :src="record.image" alt="" />
|
||||||
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
<div class="detail-row">
|
<div class="detail-row">
|
||||||
<span class="detail-label">是否发现问题:</span>
|
<span class="detail-label">是否发现问题:</span>
|
||||||
<span class="detail-value" :class="!record.hasProblem ? 'status-yes' : 'status-no'">
|
<span class="detail-value" :class="record.hasProblem ? 'status-yes' : 'status-no'">
|
||||||
{{ record.hasProblem ? '是' : '否' }}
|
{{ record.hasProblem ? '是' : '否' }}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
@ -137,7 +141,7 @@ import { ref, watch } from 'vue'
|
|||||||
import { Close } from '@element-plus/icons-vue'
|
import { Close } from '@element-plus/icons-vue'
|
||||||
import baseDialog from '../component/baseDialog.vue'
|
import baseDialog from '../component/baseDialog.vue'
|
||||||
import { request } from '@/utils/request'
|
import { request } from '@/utils/request'
|
||||||
import { getImageUrlList, formatDateTime } from '../component/index.js'
|
import { getImageUrlList } from '../component/index.js'
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
visible: {
|
visible: {
|
||||||
@ -233,55 +237,6 @@ const leveltext = (level) => {
|
|||||||
if (level.includes('9')) return '未评定'
|
if (level.includes('9')) return '未评定'
|
||||||
return '未评定'
|
return '未评定'
|
||||||
}
|
}
|
||||||
// 获取巡查记录
|
|
||||||
const getPatrolRecord = async (riskPointId) => {
|
|
||||||
if (!riskPointId) {
|
|
||||||
console.warn('未提供风险点ID')
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
const res = await request({
|
|
||||||
url: '/snow-ops-platform/risk-point/patrol-record',
|
|
||||||
method: 'GET',
|
|
||||||
params: {
|
|
||||||
riskPointId,
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
console.log('巡查记录数据:', res)
|
|
||||||
if (res.data) {
|
|
||||||
// 这里处理巡查记录数据,更新到 dynamicRecords 中
|
|
||||||
// 根据实际返回的数据结构进行处理
|
|
||||||
if (Array.isArray(res.data)) {
|
|
||||||
let arr = []
|
|
||||||
res.data.forEach((item) => {
|
|
||||||
let image = item.images ? JSON.parse(item.images) : []
|
|
||||||
let imageArr = []
|
|
||||||
if (image.length > 0) {
|
|
||||||
image.forEach((img) => {
|
|
||||||
imageArr.push(img.url.split('fileId=')[1])
|
|
||||||
})
|
|
||||||
imageArr = imageArr.join(',')
|
|
||||||
}
|
|
||||||
|
|
||||||
console.log('image:', getImageUrlList(imageArr))
|
|
||||||
arr.push({
|
|
||||||
// type: 'patrol',
|
|
||||||
typeName: '巡查记录',
|
|
||||||
patrolPerson: item.worker || '',
|
|
||||||
patrolTime: formatDateTime(item.updatedAt) || '',
|
|
||||||
description: item.conclusion || '',
|
|
||||||
hasProblem: item.hasProblem || false,
|
|
||||||
image: imageArr.length > 0 ? getImageUrlList(imageArr) : [],
|
|
||||||
})
|
|
||||||
})
|
|
||||||
dynamicRecords.value = arr.reverse()
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
dynamicRecords.value = []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 点击遮罩关闭已由base-dialog组件处理
|
// 点击遮罩关闭已由base-dialog组件处理
|
||||||
// 处理影响点类型数据
|
// 处理影响点类型数据
|
||||||
const getAffectedObjectTypeId = (data) => {
|
const getAffectedObjectTypeId = (data) => {
|
||||||
@ -418,13 +373,6 @@ const getAffectedObjectTypeId = (data) => {
|
|||||||
photoList.value = photos.length > 0 ? photos : []
|
photoList.value = photos.length > 0 ? photos : []
|
||||||
|
|
||||||
console.log('照片列表:', photos)
|
console.log('照片列表:', photos)
|
||||||
|
|
||||||
// 获取巡查记录
|
|
||||||
const riskPointId = data.item?.RISK_POINT?.GL1_ID
|
|
||||||
if (riskPointId) {
|
|
||||||
getPatrolRecord(riskPointId)
|
|
||||||
}
|
|
||||||
|
|
||||||
// 更新动态记录 - 路段信息展示
|
// 更新动态记录 - 路段信息展示
|
||||||
// dynamicRecords.value = [
|
// dynamicRecords.value = [
|
||||||
// {
|
// {
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="影响点情况"
|
title="影响点情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
@ -8,7 +8,7 @@
|
|||||||
:total="total"
|
:total="total"
|
||||||
:current-page="currentPage"
|
:current-page="currentPage"
|
||||||
:page-size="pageSize"
|
:page-size="pageSize"
|
||||||
:showFilter="true"
|
showFilter="true"
|
||||||
:z-index="2000"
|
:z-index="2000"
|
||||||
:max-width="1200"
|
:max-width="1200"
|
||||||
@size-change="handleSizeChange"
|
@size-change="handleSizeChange"
|
||||||
@ -819,7 +819,6 @@ watch(
|
|||||||
total.value = 0
|
total.value = 0
|
||||||
tableData.value = []
|
tableData.value = []
|
||||||
cardType.value = '0'
|
cardType.value = '0'
|
||||||
cardTypeVal.value = '路段'
|
|
||||||
console.log('影响点情况=========newVal:', newVal)
|
console.log('影响点情况=========newVal:', newVal)
|
||||||
if (newVal) {
|
if (newVal) {
|
||||||
filterForm.value.region = newVal.countyName
|
filterForm.value.region = newVal.countyName
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="线下帮扶"
|
title="线下帮扶"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="巡查情况"
|
title="巡查情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<!-- 响应点详情对话框 标题是影响点详情 -->
|
<!-- 响应点详情对话框 标题是影响点详情 -->
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="影响点详情"
|
title="影响点详情"
|
||||||
:table-data="[]"
|
:table-data="[]"
|
||||||
:table-columns="[]"
|
:table-columns="[]"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="响应点详情"
|
title="响应点详情"
|
||||||
:table-data="[]"
|
:table-data="[]"
|
||||||
:table-columns="[]"
|
:table-columns="[]"
|
||||||
|
|||||||
@ -1,8 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<!-- :title="props.allCountyData.name + '三级路长明细'" -->
|
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="农村公路调度"
|
:title="props.allCountyData.name + '三级路长明细'"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
:table-height="300"
|
:table-height="300"
|
||||||
@ -16,8 +15,8 @@
|
|||||||
@close="handleClose"
|
@close="handleClose"
|
||||||
>
|
>
|
||||||
<!-- 标题栏下方自定义插槽 -->
|
<!-- 标题栏下方自定义插槽 -->
|
||||||
|
<template #header>
|
||||||
<!-- 统计数据卡片 -->
|
<!-- 统计数据卡片 -->
|
||||||
<!-- <template #header>
|
|
||||||
<div class="stats-cards">
|
<div class="stats-cards">
|
||||||
<div class="stat-card">
|
<div class="stat-card">
|
||||||
<div class="card-icon">
|
<div class="card-icon">
|
||||||
@ -56,7 +55,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template> -->
|
</template>
|
||||||
|
|
||||||
<!-- 操作列插槽 -->
|
<!-- 操作列插槽 -->
|
||||||
<template #operation="{ row }">
|
<template #operation="{ row }">
|
||||||
@ -76,11 +75,19 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { ref, computed, watch } from 'vue'
|
import { ref, computed, watch } from 'vue';
|
||||||
import { Close, VideoCamera, Microphone, Phone, ArrowLeft, ArrowRight, User, OfficeBuilding, MapLocation } from '@element-plus/icons-vue'
|
import {
|
||||||
import baseDialog from '../component/baseDialog.vue'
|
Close,
|
||||||
import { request } from '@/utils/request'
|
VideoCamera,
|
||||||
import { formatDateTime, openVideoConference, openVoiceConference } from '../component/index.js'
|
Microphone,
|
||||||
|
Phone,
|
||||||
|
ArrowLeft,
|
||||||
|
ArrowRight,
|
||||||
|
User,
|
||||||
|
OfficeBuilding,
|
||||||
|
MapLocation,
|
||||||
|
} from '@element-plus/icons-vue';
|
||||||
|
import baseDialog from '../component/baseDialog.vue';
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
visible: {
|
visible: {
|
||||||
@ -93,136 +100,179 @@ const props = defineProps({
|
|||||||
name: '',
|
name: '',
|
||||||
}),
|
}),
|
||||||
},
|
},
|
||||||
getdateRange: {
|
});
|
||||||
type: Array,
|
|
||||||
default: () => [],
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
const emit = defineEmits(['update:visible', 'close', 'call'])
|
const emit = defineEmits(['update:visible', 'close']);
|
||||||
|
|
||||||
// 统计数据
|
// 统计数据
|
||||||
const stats = ref({
|
const stats = ref({
|
||||||
total: 1127,
|
total: 1127,
|
||||||
county: 216,
|
county: 216,
|
||||||
village: 1099,
|
village: 1099,
|
||||||
})
|
});
|
||||||
|
|
||||||
// 表格列配置
|
// 表格列配置
|
||||||
const tableColumns = ref([
|
const tableColumns = ref([
|
||||||
{ prop: 'id', label: '序号', width: '' },
|
{ prop: 'id', label: '序号', width: '' },
|
||||||
{ prop: 'countyName', label: '区县/镇街', width: '' },
|
{ prop: 'district', label: '区县/镇街', width: '' },
|
||||||
{ prop: 'name', label: '姓名', width: '' },
|
{ prop: 'name', label: '姓名', width: '' },
|
||||||
{ prop: 'phone', label: '电话', width: '' },
|
{ prop: 'phone', label: '电话', width: '' },
|
||||||
{ prop: 'schedulingCount', label: '调度数', width: '' },
|
{ prop: 'role', label: '角色', width: '' },
|
||||||
{ prop: 'schedulingLastTime', label: '最后调度时间', width: '' },
|
{ prop: 'position', label: '职务', width: '' },
|
||||||
{ prop: 'operation', label: '操作', width: '120px', slot: 'operation' },
|
{ prop: 'operation', label: '操作', width: '120px', slot: 'operation' },
|
||||||
])
|
]);
|
||||||
|
|
||||||
// 表格数据
|
// 表格数据
|
||||||
const tableData = ref([])
|
const tableData = ref([
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
district: '万州区柏梓镇',
|
||||||
|
name: '赵海浪',
|
||||||
|
phone: '1862352068',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 2,
|
||||||
|
district: '万州区柏梓镇',
|
||||||
|
name: '赵海浪',
|
||||||
|
phone: '1862352068',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 3,
|
||||||
|
district: '万州区柏梓镇',
|
||||||
|
name: '赵海浪',
|
||||||
|
phone: '1862352068',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 4,
|
||||||
|
district: '万州区柏梓镇',
|
||||||
|
name: '赵海浪',
|
||||||
|
phone: '1862352068',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 5,
|
||||||
|
district: '万州区李河镇',
|
||||||
|
name: '王建国',
|
||||||
|
phone: '1398324567',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 6,
|
||||||
|
district: '万州区李河镇',
|
||||||
|
name: '王建国',
|
||||||
|
phone: '1398324567',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 7,
|
||||||
|
district: '万州区李河镇',
|
||||||
|
name: '王建国',
|
||||||
|
phone: '1398324567',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 8,
|
||||||
|
district: '万州区李河镇',
|
||||||
|
name: '王建国',
|
||||||
|
phone: '1398324567',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 9,
|
||||||
|
district: '万州区分水镇',
|
||||||
|
name: '刘志强',
|
||||||
|
phone: '1387654321',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 10,
|
||||||
|
district: '万州区分水镇',
|
||||||
|
name: '刘志强',
|
||||||
|
phone: '1387654321',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 11,
|
||||||
|
district: '万州区分水镇',
|
||||||
|
name: '刘志强',
|
||||||
|
phone: '1387654321',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 12,
|
||||||
|
district: '万州区分水镇',
|
||||||
|
name: '刘志强',
|
||||||
|
phone: '1387654321',
|
||||||
|
role: '一般人员(路长履职)',
|
||||||
|
position: '其他',
|
||||||
|
},
|
||||||
|
]);
|
||||||
|
|
||||||
// 分页
|
// 分页
|
||||||
const currentPage = ref(1)
|
const currentPage = ref(1);
|
||||||
const pageSize = ref(10)
|
const pageSize = ref(10);
|
||||||
const total = ref(36)
|
const total = ref(36);
|
||||||
|
|
||||||
// 关闭对话框
|
// 关闭对话框
|
||||||
const handleClose = () => {
|
const handleClose = () => {
|
||||||
emit('update:visible', false)
|
emit('update:visible', false);
|
||||||
emit('close')
|
emit('close');
|
||||||
}
|
};
|
||||||
|
|
||||||
// 分页操作
|
// 分页操作
|
||||||
const handleSizeChange = (val) => {
|
const handleSizeChange = val => {
|
||||||
pageSize.value = val
|
pageSize.value = val;
|
||||||
fetchData()
|
fetchData();
|
||||||
}
|
};
|
||||||
|
|
||||||
const handleCurrentChange = (val) => {
|
const handleCurrentChange = val => {
|
||||||
currentPage.value = val
|
currentPage.value = val;
|
||||||
fetchData()
|
fetchData();
|
||||||
}
|
};
|
||||||
|
|
||||||
// 获取数据
|
// 获取数据
|
||||||
const fetchData = async () => {
|
const fetchData = () => {
|
||||||
try {
|
console.log('获取第', currentPage.value, '页数据');
|
||||||
const res = await request({
|
// 实际项目中调用API获取数据
|
||||||
url: '/snow-ops-platform/weather-warning/affected-road-captain',
|
};
|
||||||
method: 'GET',
|
|
||||||
params: {
|
|
||||||
offset: (currentPage.value - 1) * pageSize.value,
|
|
||||||
limit: pageSize.value,
|
|
||||||
start: formatDateTime(props.getdateRange?.[0]),
|
|
||||||
end: formatDateTime(props.getdateRange?.[1]),
|
|
||||||
},
|
|
||||||
})
|
|
||||||
console.log('路长数据:', res)
|
|
||||||
|
|
||||||
if (res.total > 0 && res.data) {
|
|
||||||
const data = res.data
|
|
||||||
tableData.value = data.map((item, index) => ({
|
|
||||||
id: currentPage.value * pageSize.value - (pageSize.value - index - 1),
|
|
||||||
countyName: item.countyName || '-',
|
|
||||||
name: item.name || '-',
|
|
||||||
phone: item.phone || '-',
|
|
||||||
schedulingCount: item.schedulingCount || '-',
|
|
||||||
schedulingLastTime: item.schedulingLastTime || '-',
|
|
||||||
}))
|
|
||||||
total.value = res.total
|
|
||||||
} else {
|
|
||||||
tableData.value = []
|
|
||||||
total.value = 0
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
console.error('获取路长数据失败:', error)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 操作按钮
|
// 操作按钮
|
||||||
const handleView = (item) => {
|
const handleView = item => {
|
||||||
console.log('查看视频:', item)
|
console.log('查看视频:', item);
|
||||||
openVideoConference({
|
};
|
||||||
...item,
|
|
||||||
id: item.id || '',
|
|
||||||
type: '护路员',
|
|
||||||
role: '路长',
|
|
||||||
text: '拨打视频电话',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
const handleVoice = (item) => {
|
const handleVoice = item => {
|
||||||
console.log('语音通话:', item)
|
console.log('语音通话:', item);
|
||||||
openVoiceConference({
|
};
|
||||||
...item,
|
|
||||||
id: item.id || '',
|
|
||||||
type: '',
|
|
||||||
role: '路长',
|
|
||||||
text: '拨打语音电话',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
const handleCall = (item) => {
|
const handleCall = item => {
|
||||||
console.log('拨打电话:', item)
|
console.log('拨打电话:', item);
|
||||||
emit('call', {
|
};
|
||||||
...item,
|
|
||||||
id: item.id || '',
|
|
||||||
type: '护路员',
|
|
||||||
role: '路长',
|
|
||||||
text: '拨打电话',
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
// 监听visible变化
|
// 监听visible变化
|
||||||
watch(
|
watch(
|
||||||
() => props.visible,
|
() => props.visible,
|
||||||
(newVal) => {
|
newVal => {
|
||||||
if (newVal) {
|
if (newVal) {
|
||||||
currentPage.value = 1
|
currentPage.value = 1;
|
||||||
fetchData()
|
fetchData();
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
)
|
);
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="响应情况"
|
title="响应情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
@ -208,40 +208,22 @@ const statsCardsData = ref([
|
|||||||
{ type: '驻地', label: '影响驻地', value: 0, icon: Icon3 },
|
{ type: '驻地', label: '影响驻地', value: 0, icon: Icon3 },
|
||||||
])
|
])
|
||||||
|
|
||||||
// 统一的表格列配置(桥梁、边坡、隧道、路段使用)
|
// 表格列配置
|
||||||
const unifiedColumns = [
|
const tableColumns = ref([
|
||||||
{ prop: 'id', label: '序号', width: '' },
|
{ prop: 'id', label: '序号', width: '' },
|
||||||
{ prop: 'pointType', label: '影响点类型', width: '' },
|
{ prop: 'pointType', label: '影响点类型', width: '' },
|
||||||
{ prop: 'pointLocation', label: '影响点位置', width: '' },
|
{ prop: 'pointLocation', label: '影响点位置', width: '' },
|
||||||
{ prop: 'pointLevel', label: '影响点等级', width: '', slot: 'pointLevel' },
|
{ prop: 'pointLevel', label: '影响点等级', width: '', slot: 'pointLevel' },
|
||||||
{ prop: 'checkCount', label: '巡查次数', width: '' },
|
{ prop: 'checkCount', label: '巡查次数', width: '' },
|
||||||
{ prop: 'trafficDept', label: '交通主管部门负责人', width: '', slot: 'trafficDept' },
|
{ prop: 'trafficDept', label: '交通主管部门负责人', width: '100px', slot: 'trafficDept' },
|
||||||
{ prop: 'roadOrg', label: '公路机构责任人', width: '', slot: 'roadOrg' },
|
{ prop: 'roadOrg', label: '公路机构责任人', width: '100px', slot: 'roadOrg' },
|
||||||
{ prop: 'maintenance', label: '养护站负责人', width: '', slot: 'maintenance' },
|
{ prop: 'maintenance', label: '养护站负责人', width: '100px', slot: 'maintenance' },
|
||||||
{ prop: 'roadKeeper', label: '护路员', width: '', slot: 'roadKeeper' },
|
{ prop: 'roadKeeper', label: '护路员', width: '100px', slot: 'roadKeeper' },
|
||||||
{ prop: 'generalStaff', label: '一般人员(路长履职)', width: '', slot: 'generalStaff' },
|
|
||||||
|
{ prop: 'generalStaff', label: '一般人员(路长履职)', width: '100px', slot: 'generalStaff' },
|
||||||
{ prop: 'urgeTime', label: '最新催告时间', width: '', slot: 'urgeTime' },
|
{ prop: 'urgeTime', label: '最新催告时间', width: '', slot: 'urgeTime' },
|
||||||
{ prop: 'operation', label: '操作', width: '', slot: 'operation' },
|
{ prop: 'operation', label: '操作', width: '', slot: 'operation' },
|
||||||
]
|
])
|
||||||
|
|
||||||
// 项目类型专用表格列配置
|
|
||||||
const projectColumns = [
|
|
||||||
{ prop: 'id', label: '序号', width: '60' },
|
|
||||||
{ prop: 'region', label: '影响区域', width: '' },
|
|
||||||
{ prop: 'pointType', label: '影响点类型', width: '' },
|
|
||||||
{ prop: 'siteName', label: '驻地名称', width: '' },
|
|
||||||
{ prop: 'whistleblower', label: '吹哨人', width: '', slot: 'whistleblower' },
|
|
||||||
{ prop: 'constructionUnit', label: '建设单位包保责任人', width: '', slot: 'constructionUnit' },
|
|
||||||
{ prop: 'constructionDept', label: '施工单位包保责任人', width: '', slot: 'constructionDept' },
|
|
||||||
{ prop: 'siteResponsible', label: '驻地包保责任人', width: '', slot: 'siteResponsible' },
|
|
||||||
{ prop: 'countyResponsible', label: '区县级包保责任人', width: '', slot: 'countyResponsible' },
|
|
||||||
{ prop: 'cityResponsible', label: '市级包保责任人', width: '', slot: 'cityResponsible' },
|
|
||||||
// { prop: 'urgeTime', label: '最新催告时间', width: '', slot: 'urgeTime' },
|
|
||||||
// { prop: 'operation', label: '操作', width: '', slot: 'operation' },
|
|
||||||
]
|
|
||||||
|
|
||||||
// 动态表格列配置
|
|
||||||
const tableColumns = ref(unifiedColumns)
|
|
||||||
|
|
||||||
// 表格数据
|
// 表格数据
|
||||||
const tableData = ref([])
|
const tableData = ref([])
|
||||||
@ -472,11 +454,6 @@ watch(
|
|||||||
currentPage.value = 1
|
currentPage.value = 1
|
||||||
fetchData()
|
fetchData()
|
||||||
loadBarChartData()
|
loadBarChartData()
|
||||||
if (newVal == '驻地') {
|
|
||||||
tableColumns.value = projectColumns
|
|
||||||
} else {
|
|
||||||
tableColumns.value = unifiedColumns
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="影响点详情"
|
title="影响点详情"
|
||||||
:table-data="[]"
|
:table-data="[]"
|
||||||
:table-columns="[]"
|
:table-columns="[]"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
:title="props.allCountyData.name + '基本信息表'"
|
:title="props.allCountyData.name + '基本信息表'"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
:title="`${props.allCountyData.name}建设项目责任人详情`"
|
:title="`${props.allCountyData.name}建设项目责任人详情`"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
:title="props.allCountyData.name + '建设项目责任人明细'"
|
:title="props.allCountyData.name + '建设项目责任人明细'"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
:title="props.allCountyData.name + '护路团队成员明细'"
|
:title="props.allCountyData.name + '护路团队成员明细'"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
:title="rescueTeamData.title"
|
:title="rescueTeamData.title"
|
||||||
:table-data="[]"
|
:table-data="[]"
|
||||||
:table-columns="[]"
|
:table-columns="[]"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="响应情况"
|
title="响应情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
@ -105,7 +105,7 @@ const props = defineProps({
|
|||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
const emit = defineEmits(['update:visible', 'close', 'openImpactPoint', 'responseStatus', 'getResponseStatusrowFn'])
|
const emit = defineEmits(['update:visible', 'close', 'openImpactPoint', 'getResponseStatusrowFn'])
|
||||||
|
|
||||||
// 筛选表单
|
// 筛选表单
|
||||||
const filterForm = ref({
|
const filterForm = ref({
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:visible="props.visible"
|
v-model:visible="props.visible"
|
||||||
title="预警情况"
|
title="预警情况"
|
||||||
:table-data="tableData"
|
:table-data="tableData"
|
||||||
:table-columns="tableColumns"
|
:table-columns="tableColumns"
|
||||||
|
|||||||
@ -1650,28 +1650,28 @@ const initMap = async () => {
|
|||||||
两江: [29.723, 106.583],
|
两江: [29.723, 106.583],
|
||||||
}
|
}
|
||||||
|
|
||||||
// 根据统计数据添加区县标签(已在loadDistrictGeoJson中添加,此处注释避免重复)
|
// 根据统计数据添加区县标签
|
||||||
// if (affectedCountyData.value && affectedCountyData.value.byName) {
|
if (affectedCountyData.value && affectedCountyData.value.byName) {
|
||||||
// Object.entries(affectedCountyData.value.byName).forEach(([districtName, data]) => {
|
Object.entries(affectedCountyData.value.byName).forEach(([districtName, data]) => {
|
||||||
// const center = districtCenters[districtName]
|
const center = districtCenters[districtName]
|
||||||
// if (center) {
|
if (center) {
|
||||||
// const displayName = districtName
|
const displayName = districtName
|
||||||
// const label = window.L.divIcon({
|
const label = window.L.divIcon({
|
||||||
// className: 'district-label',
|
className: 'district-label',
|
||||||
// html: `<div class="label-content">${displayName}</div>`,
|
html: `<div class="label-content">${displayName}</div>`,
|
||||||
// iconSize: [80, 30],
|
iconSize: [80, 30],
|
||||||
// iconAnchor: [40, 15],
|
iconAnchor: [40, 15],
|
||||||
// })
|
})
|
||||||
|
|
||||||
// const marker = window.L.marker(center, {
|
const marker = window.L.marker(center, {
|
||||||
// icon: label,
|
icon: label,
|
||||||
// interactive: false,
|
interactive: false,
|
||||||
// zIndexOffset: 500,
|
zIndexOffset: 500,
|
||||||
// })
|
})
|
||||||
// marker.addTo(mapInstance)
|
marker.addTo(mapInstance)
|
||||||
// }
|
}
|
||||||
// })
|
})
|
||||||
// }
|
}
|
||||||
|
|
||||||
// 调整视图以适应重庆边界
|
// 调整视图以适应重庆边界
|
||||||
const chongqingBounds = [
|
const chongqingBounds = [
|
||||||
|
|||||||
@ -182,11 +182,11 @@ export const logUserOperation = async (type, command) => {
|
|||||||
data: data,
|
data: data,
|
||||||
})
|
})
|
||||||
console.log('日志请求完成:', res)
|
console.log('日志请求完成:', res)
|
||||||
// if (res.code === '00000') {
|
if (res.code === '00000') {
|
||||||
// ElMessage.success('操作日志记录成功')
|
ElMessage.success('操作日志记录成功')
|
||||||
// } else {
|
} else {
|
||||||
// ElMessage.error(res.message || '操作日志记录失败')
|
ElMessage.error(res.message || '操作日志记录失败')
|
||||||
// }
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 打开视频会议
|
// 打开视频会议
|
||||||
@ -331,7 +331,6 @@ const getTokenFromStorage = () => {
|
|||||||
const BASE_API_URL = 'http://58.144.223.132:30008/'
|
const BASE_API_URL = 'http://58.144.223.132:30008/'
|
||||||
// 获取图片地址数组
|
// 获取图片地址数组
|
||||||
export const getImageUrlList = (fileIdStr) => {
|
export const getImageUrlList = (fileIdStr) => {
|
||||||
console.log('fileIdStr:', fileIdStr)
|
|
||||||
if (!fileIdStr || typeof fileIdStr !== 'string') {
|
if (!fileIdStr || typeof fileIdStr !== 'string') {
|
||||||
console.warn('fileIdStr 为空或不是字符串')
|
console.warn('fileIdStr 为空或不是字符串')
|
||||||
return []
|
return []
|
||||||
|
|||||||
@ -92,11 +92,9 @@
|
|||||||
<div>
|
<div>
|
||||||
<!-- 农村公路对话框 -->
|
<!-- 农村公路对话框 -->
|
||||||
<responseSituationDiaLog
|
<responseSituationDiaLog
|
||||||
:getdateRange="getdateRange"
|
|
||||||
v-model:visible="dialogVisible.responseSituation"
|
v-model:visible="dialogVisible.responseSituation"
|
||||||
:allCountyData="allCountyData"
|
:allCountyData="allCountyData"
|
||||||
@close="closeDialog('responseSituation')"
|
@close="closeDialog('responseSituation')"
|
||||||
@call="handleCallClick"
|
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<!-- 预警信息对话框 -->
|
<!-- 预警信息对话框 -->
|
||||||
@ -587,7 +585,7 @@ const handleDistrictClick = (item) => {
|
|||||||
allCountyData.value = item
|
allCountyData.value = item
|
||||||
if (item.data.roadType == 'national') {
|
if (item.data.roadType == 'national') {
|
||||||
// 国省道
|
// 国省道
|
||||||
openDialog('tongnanopenDialogTeam')
|
openDialog('tongnanTeam')
|
||||||
} else if (item.data.roadType == 'rural') {
|
} else if (item.data.roadType == 'rural') {
|
||||||
openDialog('responseSituation')
|
openDialog('responseSituation')
|
||||||
} else if (item.data.type == 'project' && item.data.roadType == '-') {
|
} else if (item.data.type == 'project' && item.data.roadType == '-') {
|
||||||
@ -606,7 +604,7 @@ const handleCenterCardClick = (item) => {
|
|||||||
title: getCardTitleByType(item.type),
|
title: getCardTitleByType(item.type),
|
||||||
dataList: item.data,
|
dataList: item.data,
|
||||||
}
|
}
|
||||||
// if (item.type == 'second') return
|
if (item.type == 'second') return
|
||||||
chongqingMapRef.value.openCenterCard(cardData)
|
chongqingMapRef.value.openCenterCard(cardData)
|
||||||
|
|
||||||
// 如果数据中包含区县信息,定位到第一个区县
|
// 如果数据中包含区县信息,定位到第一个区县
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user