From d88c4122607e1919d373937ab896152c7114c48f Mon Sep 17 00:00:00 2001 From: huangchenhao <123673748@qq.com> Date: Fri, 8 May 2026 17:19:54 +0800 Subject: [PATCH 1/5] =?UTF-8?q?feat:=20=E4=BF=AE=E6=94=B9=E6=B3=95?= =?UTF-8?q?=E8=A7=84=E5=A4=84=E5=88=97=E8=A1=A8=20=E9=A2=84=E8=AD=A6?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../screen/src/views/RiskWarning/component/ChongqingMap.vue | 2 +- packages/screen/src/views/WarningManagement/law/index.js | 5 +---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/packages/screen/src/views/RiskWarning/component/ChongqingMap.vue b/packages/screen/src/views/RiskWarning/component/ChongqingMap.vue index fb3922e..9dc8986 100644 --- a/packages/screen/src/views/RiskWarning/component/ChongqingMap.vue +++ b/packages/screen/src/views/RiskWarning/component/ChongqingMap.vue @@ -51,7 +51,7 @@ import tunnelLineIcon from '../../../assets/MaMap_img/线路icon定位@2x.png' import mapInfoDialog from '../Dialog/mapInfoDialog.vue' import centerInfoCard from '../Dialog/centerInfoCard.vue' import hazardPointSituationDialog from '../Dialog/hazardPointSituationDialog.vue' -import I from '../../../../dist/cesium/Workers/upsampleVerticesFromCesium3DTilesTerrain' +// import I from '../../../../dist/cesium/Workers/upsampleVerticesFromCesium3DTilesTerrain' const mapContainer = ref(null) const loading = ref(false) diff --git a/packages/screen/src/views/WarningManagement/law/index.js b/packages/screen/src/views/WarningManagement/law/index.js index 43825c6..42b688d 100644 --- a/packages/screen/src/views/WarningManagement/law/index.js +++ b/packages/screen/src/views/WarningManagement/law/index.js @@ -54,11 +54,8 @@ const columns = [ label: "预警标题", }, { - // prop: "xxx", + prop: "weatherWarningType", label: "预警类型", - formatter: (row) => { - return h(ElText, { style: {} }, '大雾预警'); - } }, { prop: "createTime", From 3cbf071838ba4c0547b8ef7acf020308fd972d9a Mon Sep 17 00:00:00 2001 From: huangchenhao <123673748@qq.com> Date: Sat, 9 May 2026 15:25:44 +0800 Subject: [PATCH 2/5] =?UTF-8?q?feat:=20PC=E6=B3=95=E8=A7=84=E5=A4=84?= =?UTF-8?q?=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../WarningManagement/law/detailDrawer.vue | 888 +++++++++++++++--- .../src/views/WarningManagement/law/index.js | 17 +- 2 files changed, 770 insertions(+), 135 deletions(-) diff --git a/packages/screen/src/views/WarningManagement/law/detailDrawer.vue b/packages/screen/src/views/WarningManagement/law/detailDrawer.vue index 8b7c938..54e1d57 100644 --- a/packages/screen/src/views/WarningManagement/law/detailDrawer.vue +++ b/packages/screen/src/views/WarningManagement/law/detailDrawer.vue @@ -1,159 +1,779 @@ - - \ No newline at end of file + +.table { + display: flex; + flex-direction: column; + gap: 10px; +} + +// 统计卡片 +.stats-cards { + display: flex; + gap: 12px; + background-color: #16334e; + padding: 5px; + + .stat-card { + display: flex; + align-items: center; + gap: 8px; + padding: 8px 16px; + transition: all 0.3s; + cursor: pointer; + flex: 1; + + &:hover { + background: rgba(30, 70, 120, 0.9); + border-color: rgba(64, 169, 255, 0.6); + box-shadow: 0 0 15px rgba(64, 169, 255, 0.3); + } + + .stat-icon { + font-size: 18px; + color: #40a9ff; + width: 34px; + height: 34px; + display: flex; + align-items: center; + justify-content: center; + img { + width: 100%; + height: 100%; + } + } + + .stat-content { + display: flex; + align-items: center; + gap: 6px; + + .stat-label { + font-size: 14px; + color: #fff; + font-weight: 500; + } + + .stat-value { + font-size: 14px; + font-weight: bold; + color: #40a9ff; + } + } + } +} + +.search-form { + display: flex; + flex-direction: row; + align-items: center; + flex-wrap: wrap; + gap: 12px; + .search-item { + width: 150px; + } +} + diff --git a/packages/screen/src/views/WarningManagement/law/index.js b/packages/screen/src/views/WarningManagement/law/index.js index 42b688d..ea584e9 100644 --- a/packages/screen/src/views/WarningManagement/law/index.js +++ b/packages/screen/src/views/WarningManagement/law/index.js @@ -5,6 +5,19 @@ import AddDialog from "./addDialog.vue"; import ScheduleDiaog from "../law/dutyManagement/addDialog.vue" import DetailDrawer from "./detailDrawer.vue"; +// 格式化时间函数 +const formatDateTime = (dateStr) => { + if (!dateStr) return '-'; + const date = new Date(dateStr); + const year = date.getFullYear(); + const month = String(date.getMonth() + 1).padStart(2, '0'); + const day = String(date.getDate()).padStart(2, '0'); + const hours = String(date.getHours()).padStart(2, '0'); + const minutes = String(date.getMinutes()).padStart(2, '0'); + const seconds = String(date.getSeconds()).padStart(2, '0'); + return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`; +}; + const tableData = ref([]); // 表格数据 const modelVisible = ref(false); // 弹窗状态 const drawerVisible = ref(false); // 抽屉状态 @@ -64,6 +77,7 @@ const columns = [ { prop: "onset", label: "生效时间", + render: (row) => () => h('span', formatDateTime(row.onset)) }, { prop: "receiveTime", @@ -76,6 +90,7 @@ const columns = [ { prop: "expires", label: "预警结束时间", + render: (row) => () => h('span', formatDateTime(row.expires)) }, { prop: "affectedRoadSectionCount", @@ -255,7 +270,7 @@ const publishWarning = async (data) => { const openDetailDrawer = (row) => { drawer.title = '预警详情'; drawer.props = { - id: row.id, + row: row }; drawer.content = DetailDrawer; drawerVisible.value = true; From 16d7c75c12e82665a53df6126201a6ab1d8cda28 Mon Sep 17 00:00:00 2001 From: huangchenhao <123673748@qq.com> Date: Sat, 9 May 2026 15:31:06 +0800 Subject: [PATCH 3/5] =?UTF-8?q?feat:=20PC=E6=B3=95=E8=A7=84=E5=A4=84?= =?UTF-8?q?=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/WarningManagement/law/detailDrawer.vue | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/packages/screen/src/views/WarningManagement/law/detailDrawer.vue b/packages/screen/src/views/WarningManagement/law/detailDrawer.vue index 54e1d57..722392b 100644 --- a/packages/screen/src/views/WarningManagement/law/detailDrawer.vue +++ b/packages/screen/src/views/WarningManagement/law/detailDrawer.vue @@ -447,8 +447,15 @@ const getAffectedSites = async () => { })) pagination.total = res.total || 0 } + } else if (cardTypeVal.value == '桥梁') { + if (res.data) { + tableData.value = res.data.map((item, index) => ({ + ...processDataByType(item, cardType.value), + id: index + 1, + })) + pagination.total = res.total || 0 + } } else { - console.log('@@@执行到这里了',) if (res.code === '00000' && res.data) { // 处理返回数据 const allData = res.data @@ -686,9 +693,6 @@ const getColumnsByType = (type) => { return typeMap[type] || unifiedColumns } - - - onMounted(async () => { await loadBarChartData() await fetchDistrictOptions() From e614b5baef938a8bba38ffe8aa58cb99b73360e9 Mon Sep 17 00:00:00 2001 From: huangchenhao <123673748@qq.com> Date: Sat, 9 May 2026 15:35:53 +0800 Subject: [PATCH 4/5] =?UTF-8?q?bugfix:=20=E8=BE=B9=E5=9D=A1=E5=88=86?= =?UTF-8?q?=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../screen/src/views/WarningManagement/law/detailDrawer.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/screen/src/views/WarningManagement/law/detailDrawer.vue b/packages/screen/src/views/WarningManagement/law/detailDrawer.vue index 722392b..02c2a30 100644 --- a/packages/screen/src/views/WarningManagement/law/detailDrawer.vue +++ b/packages/screen/src/views/WarningManagement/law/detailDrawer.vue @@ -462,8 +462,8 @@ const getAffectedSites = async () => { pagination.total = allData.length || 0 // 客户端分页:计算当前页的数据范围 - const startIndex = (currentPage.value - 1) * pageSize.value - const endIndex = startIndex + pageSize.value + const startIndex = (pagination.current - 1) * pagination.pageSize + const endIndex = startIndex + pagination.pageSize const currentPageData = allData.slice(startIndex, endIndex) tableData.value = currentPageData.map((item, index) => ({ From e33df64a8ace9766fc87a6863e413ec8dee15918 Mon Sep 17 00:00:00 2001 From: huangchenhao <123673748@qq.com> Date: Sat, 9 May 2026 15:55:32 +0800 Subject: [PATCH 5/5] =?UTF-8?q?feat:=20PC=E6=B3=95=E8=A7=84=E5=A4=84?= =?UTF-8?q?=E5=88=97=E8=A1=A8=20=E7=B1=BB=E5=9E=8B=E6=8C=89=E9=92=AE?= =?UTF-8?q?=E5=88=87=E6=8D=A2=E4=B8=BA=E5=8E=9F=E7=94=9Fel-radio?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../WarningManagement/law/detailDrawer.vue | 114 ++++-------------- 1 file changed, 23 insertions(+), 91 deletions(-) diff --git a/packages/screen/src/views/WarningManagement/law/detailDrawer.vue b/packages/screen/src/views/WarningManagement/law/detailDrawer.vue index 02c2a30..7a23ff9 100644 --- a/packages/screen/src/views/WarningManagement/law/detailDrawer.vue +++ b/packages/screen/src/views/WarningManagement/law/detailDrawer.vue @@ -26,23 +26,15 @@
-
-
-
- {{ item.name }} - {{ item.count }} -
-
+ + + {{ item.name }} ({{ item.count }}) + +
{ // 根据类型处理数据(统一格式) const processDataByType = (item, type) => { - return processUnifiedData(item, type) + return processUnifiedData(item, cardTypeVal.value) } // 处理数据为统一格式 @@ -203,7 +187,7 @@ const processUnifiedData = (item, type) => { // 影响区域 region: item.GL1_QXMC || item.COUNTY || item.county || item.region || item.ADMINISTRATIVE_REGION || item.COUNTY_NAME || '-', // 影响点类型 - pointType: impactData.value[type].type || '-', + pointType: cardTypeVal.value || '-', // 影响点位置(根据类型取不同字段) pointLocation: item.GL1_QLMC || item.NAME || item.GL1_SDMC || item.PROJECT_NAME || item.GL1_LXBH || item.name || '-', // 影响点等级 @@ -434,7 +418,7 @@ const getAffectedSites = async () => { if (cardTypeVal.value == '路段') { if (res.data) { tableData.value = res.data.map((item, index) => ({ - ...processDataByType(item, cardType.value), + ...processDataByType(item), id: index + 1, })) pagination.total = res.total || 0 @@ -442,7 +426,7 @@ const getAffectedSites = async () => { } else if (cardTypeVal.value == '驻地') { if (res.data) { tableData.value = res.data.map((item, index) => ({ - ...processDataByType(item, cardType.value), + ...processDataByType(item), id: index + 1, })) pagination.total = res.total || 0 @@ -450,7 +434,7 @@ const getAffectedSites = async () => { } else if (cardTypeVal.value == '桥梁') { if (res.data) { tableData.value = res.data.map((item, index) => ({ - ...processDataByType(item, cardType.value), + ...processDataByType(item), id: index + 1, })) pagination.total = res.total || 0 @@ -467,7 +451,7 @@ const getAffectedSites = async () => { const currentPageData = allData.slice(startIndex, endIndex) tableData.value = currentPageData.map((item, index) => ({ - ...processDataByType(item, cardType.value), + ...processDataByType(item), id: startIndex + index + 1, })) } else { @@ -530,11 +514,11 @@ const handleFilterChange = () => { // 影响点数据 const impactData = ref([ - { name: '影响路段', count: 0, icon: Icon4, type: '路段' }, - { name: '影响桥梁', count: 0, icon: Icon0, type: '桥梁' }, - { name: '影响隧道', count: 0, icon: Icon2, type: '隧道' }, - { name: '影响边坡', count: 0, icon: Icon1, type: '边坡' }, - { name: '影响驻地', count: 0, icon: Icon3, type: '驻地' }, + { name: '影响路段', count: 0, type: '路段' }, + { name: '影响桥梁', count: 0, type: '桥梁' }, + { name: '影响隧道', count: 0, type: '隧道' }, + { name: '影响边坡', count: 0, type: '边坡' }, + { name: '影响驻地', count: 0, type: '驻地' }, ]) // 顶部卡片数据 @@ -589,9 +573,9 @@ const loadBarChartData = async () => { } // 点击卡片切换 -const handleClick = (index, item) => { +const handleTypeChange = (index) => { + const item = impactData.value[index] tableData.value = [] - cardType.value = index + '' cardTypeVal.value = item.type columns.value = getColumnsByType(item.type) @@ -716,58 +700,6 @@ onMounted(async () => { // 统计卡片 .stats-cards { - display: flex; - gap: 12px; - background-color: #16334e; - padding: 5px; - - .stat-card { - display: flex; - align-items: center; - gap: 8px; - padding: 8px 16px; - transition: all 0.3s; - cursor: pointer; - flex: 1; - - &:hover { - background: rgba(30, 70, 120, 0.9); - border-color: rgba(64, 169, 255, 0.6); - box-shadow: 0 0 15px rgba(64, 169, 255, 0.3); - } - - .stat-icon { - font-size: 18px; - color: #40a9ff; - width: 34px; - height: 34px; - display: flex; - align-items: center; - justify-content: center; - img { - width: 100%; - height: 100%; - } - } - - .stat-content { - display: flex; - align-items: center; - gap: 6px; - - .stat-label { - font-size: 14px; - color: #fff; - font-weight: 500; - } - - .stat-value { - font-size: 14px; - font-weight: bold; - color: #40a9ff; - } - } - } } .search-form {