Compare commits
2 Commits
d6315f56be
...
940c839c79
| Author | SHA1 | Date | |
|---|---|---|---|
| 940c839c79 | |||
| 14f0f9d752 |
@ -10,7 +10,6 @@
|
|||||||
:is="dynamicComponent"
|
:is="dynamicComponent"
|
||||||
ref="dynamicComponentRef"
|
ref="dynamicComponentRef"
|
||||||
v-bind="componentProps"
|
v-bind="componentProps"
|
||||||
@vue:mounted="handleComponentMount"
|
|
||||||
/>
|
/>
|
||||||
<slot></slot>
|
<slot></slot>
|
||||||
<template #footer>
|
<template #footer>
|
||||||
|
|||||||
@ -11,7 +11,6 @@
|
|||||||
:is="dynamicComponent"
|
:is="dynamicComponent"
|
||||||
ref="dynamicComponentRef"
|
ref="dynamicComponentRef"
|
||||||
v-bind="componentProps"
|
v-bind="componentProps"
|
||||||
@vue:mounted="handleComponentMount"
|
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<template #footer>
|
<template #footer>
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
<el-card shadow="hover">
|
<el-card shadow="hover">
|
||||||
<el-row :gutter="20">
|
<el-row :gutter="20">
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-descriptions title="基础信息" column="1">
|
<el-descriptions title="基础信息" :column="1">
|
||||||
<el-descriptions-item label="物资名称: ">{{
|
<el-descriptions-item label="物资名称: ">{{
|
||||||
detailData.material?.wzmc
|
detailData.material?.wzmc
|
||||||
}}</el-descriptions-item>
|
}}</el-descriptions-item>
|
||||||
@ -38,7 +38,7 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-card shadow="hover">
|
<el-card shadow="hover">
|
||||||
<el-descriptions title="物资位置信息" column="3">
|
<el-descriptions title="物资位置信息" :column="3">
|
||||||
<el-descriptions-item label="区县名称: ">{{
|
<el-descriptions-item label="区县名称: ">{{
|
||||||
detailData.material?.qxmc
|
detailData.material?.qxmc
|
||||||
}}</el-descriptions-item>
|
}}</el-descriptions-item>
|
||||||
@ -51,7 +51,7 @@
|
|||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-card shadow="hover">
|
<el-card shadow="hover">
|
||||||
<el-descriptions title="物资管理情况" column="3">
|
<el-descriptions title="物资管理情况" :column="3">
|
||||||
<el-descriptions-item label="负责人: ">{{
|
<el-descriptions-item label="负责人: ">{{
|
||||||
detailData.material?.fzr
|
detailData.material?.fzr
|
||||||
}}</el-descriptions-item>
|
}}</el-descriptions-item>
|
||||||
|
|||||||
@ -1,52 +1,128 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="detail-container">
|
<div class="detail-container">
|
||||||
<el-form
|
<el-card shadow="hover">
|
||||||
label-position="right"
|
<el-descriptions title="基础信息" :column="3">
|
||||||
label-width="150px"
|
<el-descriptions-item label="发生时间: ">{{
|
||||||
style="max-height: 60vh; overflow-y: auto; padding-right: 50px"
|
detailData.event?.occurTime
|
||||||
>
|
}}</el-descriptions-item>
|
||||||
<el-row :gutter="20">
|
<el-descriptions-item label="发生地点: ">{{
|
||||||
<el-col :span="12">
|
detailData.event?.occurLocation
|
||||||
<el-form-item label="物资名称:">
|
}}</el-descriptions-item>
|
||||||
<el-input disabled v-model="detailData.wzmc" />
|
<el-descriptions-item label="线路编号: ">{{
|
||||||
</el-form-item>
|
detailData.event?.routeNo
|
||||||
<el-form-item label="余量:">
|
}}</el-descriptions-item>
|
||||||
<el-input disabled v-model="detailData.ye" />
|
<el-descriptions-item label="填报时间: ">{{
|
||||||
</el-form-item>
|
detailData.event?.reportTime
|
||||||
<el-form-item label="入库日期:">
|
}}</el-descriptions-item>
|
||||||
<el-input disabled v-model="detailData.rkrq" />
|
<el-descriptions-item label="填报人: ">{{
|
||||||
</el-form-item>
|
detailData.event?.reporterName
|
||||||
<el-form-item label="入库单位:">
|
}}</el-descriptions-item>
|
||||||
<el-input disabled v-model="detailData.rkdw" />
|
<el-descriptions-item label="所属区县: ">{{
|
||||||
</el-form-item>
|
detailData.event?.district
|
||||||
<el-row :gutter="20">
|
}}</el-descriptions-item>
|
||||||
<el-col :span="12">
|
<el-descriptions-item label="所属服务站: ">{{
|
||||||
<el-form-item label="数量:">
|
detailData.event?.stationName
|
||||||
<el-input disabled v-model="detailData.sl"/>
|
}}</el-descriptions-item>
|
||||||
</el-form-item>
|
</el-descriptions>
|
||||||
</el-col>
|
<el-row :gutter="20" class="custom-row">
|
||||||
<el-col :span="12">
|
<el-col :span="8">
|
||||||
<el-form-item label="单位:">
|
<div class="stake-item">
|
||||||
<el-input disabled v-model="detailData.dw" /> </el-form-item
|
<span class="label">起点桩号:</span>
|
||||||
></el-col>
|
<span class="value">{{ detailData.event?.startStakeNo }}</span>
|
||||||
</el-row>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
|
||||||
<el-form-item label="存放地点:">
|
<el-col :span="8">
|
||||||
<el-input disabled v-model="detailData.cfdd" />
|
<div class="middle-column">
|
||||||
</el-form-item>
|
<div class="disaster-mileage">
|
||||||
<el-form-item label="负责人:">
|
受灾里程: {{ detailData.event?.disasterMileage }}
|
||||||
<el-input disabled v-model="detailData.fzr" />
|
</div>
|
||||||
</el-form-item>
|
<div class="dash-line-container">
|
||||||
<el-form-item label="联系电话:">
|
<span class="dash-line"></span>
|
||||||
<el-input disabled v-model="detailData.lxdh" />
|
</div>
|
||||||
</el-form-item>
|
</div>
|
||||||
<el-form-item label="区县名称:">
|
</el-col>
|
||||||
<el-input disabled v-model="detailData.qxmc" />
|
<el-col :span="8">
|
||||||
</el-form-item>
|
<div class="stake-item">
|
||||||
|
<span class="label">止点桩号:</span>
|
||||||
|
<span class="value">{{ detailData.event?.endStakeNo }}</span>
|
||||||
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-form>
|
</el-card>
|
||||||
|
<el-card shadow="hover">
|
||||||
|
<el-descriptions title="处置情况" :column="3">
|
||||||
|
<el-descriptions-item label="处置措施: ">{{
|
||||||
|
detailData.event?.disposalMeasures
|
||||||
|
}}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="预计恢复时间: ">{{
|
||||||
|
detailData.event?.expectRecoverTime
|
||||||
|
}}</el-descriptions-item>
|
||||||
|
</el-descriptions>
|
||||||
|
</el-card>
|
||||||
|
<el-card shadow="hover">
|
||||||
|
<el-descriptions title="物资情况" :column="3">
|
||||||
|
<el-descriptions-item label="投入人力: ">{{
|
||||||
|
detailData.material?.inputManpower + "人次"
|
||||||
|
}}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="投入资金: ">{{
|
||||||
|
detailData.material?.inputFunds + "万元"
|
||||||
|
}}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="投入设备: ">{{
|
||||||
|
detailData.material?.inputEquipment + "台班"
|
||||||
|
}}</el-descriptions-item>
|
||||||
|
<el-descriptions-item
|
||||||
|
v-for="(item, index) in detailData.materialUsageList"
|
||||||
|
:key="index"
|
||||||
|
:label="item.materialName + ': '"
|
||||||
|
>{{ item.usageAmount + "" + item.materialUnit }}
|
||||||
|
</el-descriptions-item>
|
||||||
|
</el-descriptions>
|
||||||
|
<el-divider />
|
||||||
|
<el-descriptions title="通行情况" :column="3">
|
||||||
|
<el-descriptions-item label="当前通行情况: ">{{
|
||||||
|
{
|
||||||
|
1: "正常通行",
|
||||||
|
2: "限速通行",
|
||||||
|
3: "封闭交通",
|
||||||
|
}[detailData.traffic?.currentStatus] || "未知状态"
|
||||||
|
}}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="有无车辆滞留: ">{{
|
||||||
|
{
|
||||||
|
0: "无",
|
||||||
|
1: "有",
|
||||||
|
}[detailData.traffic?.hasStrandedVehicles] || "未知状态"
|
||||||
|
}}</el-descriptions-item>
|
||||||
|
<el-descriptions-item
|
||||||
|
v-if="detailData.traffic?.hasStrandedVehicles === 1"
|
||||||
|
label="滞留车辆数: "
|
||||||
|
>{{
|
||||||
|
detailData.traffic?.strandedVehicleCount + "辆"
|
||||||
|
}}</el-descriptions-item
|
||||||
|
>
|
||||||
|
<el-descriptions-item label="实际恢复时间: ">{{
|
||||||
|
detailData.traffic?.actualRecoverTime
|
||||||
|
}}</el-descriptions-item>
|
||||||
|
</el-descriptions>
|
||||||
|
<el-divider />
|
||||||
|
<el-descriptions title="现场情况" :column="3"> </el-descriptions>
|
||||||
|
<el-image
|
||||||
|
v-for="(item) in detailData.photos"
|
||||||
|
:key="item.id"
|
||||||
|
style="
|
||||||
|
width: 180px;
|
||||||
|
height: 180px;
|
||||||
|
margin: 10px;
|
||||||
|
"
|
||||||
|
:src="item.photoUrl"
|
||||||
|
:zoom-rate="1.2"
|
||||||
|
:max-scale="7"
|
||||||
|
:min-scale="0.2"
|
||||||
|
:preview-src-list="[item.photoUrl]"
|
||||||
|
show-progresss
|
||||||
|
fit="cover"
|
||||||
|
/>
|
||||||
|
</el-card>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -60,4 +136,56 @@ const props = defineProps({
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
.detail-container {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stake-item {
|
||||||
|
display: flex;
|
||||||
|
align-items: flex-end;
|
||||||
|
justify-content: center;
|
||||||
|
gap: 8px;
|
||||||
|
height: 100%;
|
||||||
|
padding-bottom: 8px;
|
||||||
|
}
|
||||||
|
.label {
|
||||||
|
color: #606266;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
.value {
|
||||||
|
color: #909399;
|
||||||
|
}
|
||||||
|
.custom-row {
|
||||||
|
margin-top: 30px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.middle-column {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: space-between;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
.disaster-mileage {
|
||||||
|
margin-bottom: 2px;
|
||||||
|
color: #606266;
|
||||||
|
}
|
||||||
|
.dash-line-container {
|
||||||
|
width: 100%;
|
||||||
|
position: relative;
|
||||||
|
margin-top: 4px;
|
||||||
|
}
|
||||||
|
.dash-line {
|
||||||
|
display: block;
|
||||||
|
width: 100%;
|
||||||
|
height: 1px;
|
||||||
|
background: repeating-linear-gradient(
|
||||||
|
to right,
|
||||||
|
#909399 0px,
|
||||||
|
#909399 2px,
|
||||||
|
transparent 2px,
|
||||||
|
transparent 4px
|
||||||
|
);
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
@ -44,6 +44,19 @@ const model = reactive({
|
|||||||
const dialogType = ref(''); // 弹窗类型
|
const dialogType = ref(''); // 弹窗类型
|
||||||
const dialogRef = ref(null); // 弹窗实例
|
const dialogRef = ref(null); // 弹窗实例
|
||||||
|
|
||||||
|
const drawerVisible = ref(false); // 抽屉显示状态
|
||||||
|
const drawer = reactive({
|
||||||
|
title: '',
|
||||||
|
content: null,
|
||||||
|
props: {},
|
||||||
|
onCancel: null,
|
||||||
|
onConfirm: null,
|
||||||
|
direction: 'rtl',
|
||||||
|
size: '50%'
|
||||||
|
}); // 抽屉内容
|
||||||
|
const drawerType = ref(''); // 抽屉类型
|
||||||
|
const drawerRef = ref(null); // 抽屉实例
|
||||||
|
|
||||||
const INIT_FORM = {
|
const INIT_FORM = {
|
||||||
rkrq: "",
|
rkrq: "",
|
||||||
rkdw: "",
|
rkdw: "",
|
||||||
@ -86,7 +99,7 @@ const filterNode = (value, node) => {
|
|||||||
const getTreeData = async () => {
|
const getTreeData = async () => {
|
||||||
try {
|
try {
|
||||||
const res = await request({
|
const res = await request({
|
||||||
url: '/snow-ops-platform/yhz/listAreaGroup',
|
url: '/snow-ops-platform/yhz/listAreaGroup?dataType=ICE_SNOW_EVENT',
|
||||||
method: 'GET'
|
method: 'GET'
|
||||||
})
|
})
|
||||||
if (res.code === '00000') {
|
if (res.code === '00000') {
|
||||||
@ -223,24 +236,24 @@ const columns = [
|
|||||||
type: "primary",
|
type: "primary",
|
||||||
link: true,
|
link: true,
|
||||||
onClick: async () => {
|
onClick: async () => {
|
||||||
dialogType.value = 'detail'
|
drawerType.value = 'detail'
|
||||||
await getDetailData(row);
|
await getDetailData(row);
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
() => "详情"
|
() => "详情"
|
||||||
),
|
),
|
||||||
h(
|
// h(
|
||||||
ElButton,
|
// ElButton,
|
||||||
{
|
// {
|
||||||
type: "primary",
|
// type: "primary",
|
||||||
link: true,
|
// link: true,
|
||||||
onClick: async () => {
|
// onClick: async () => {
|
||||||
dialogType.value = 'edit'
|
// dialogType.value = 'edit'
|
||||||
await getDetailData(row);
|
// await getDetailData(row);
|
||||||
},
|
// },
|
||||||
},
|
// },
|
||||||
() => "编辑"
|
// () => "编辑"
|
||||||
),
|
// ),
|
||||||
h(
|
h(
|
||||||
ElButton,
|
ElButton,
|
||||||
{
|
{
|
||||||
@ -248,16 +261,16 @@ const columns = [
|
|||||||
link: true,
|
link: true,
|
||||||
onClick: async () => {
|
onClick: async () => {
|
||||||
try {
|
try {
|
||||||
await ElMessageBox.confirm("确定要删除该设备吗?", "删除确认", {
|
await ElMessageBox.confirm("确定要删除该冰雪事件吗?", "删除确认", {
|
||||||
confirmButtonText: "确定",
|
confirmButtonText: "确定",
|
||||||
cancelButtonText: "取消",
|
cancelButtonText: "取消",
|
||||||
type: "warning",
|
type: "warning",
|
||||||
});
|
});
|
||||||
const res = await request({
|
const res = await request({
|
||||||
url: `/snow-ops-platform/yjwz/delete`,
|
url: `/snow-ops-platform/event/delete`,
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
data: {
|
data: {
|
||||||
rid: row.rid,
|
id: row.id,
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
if (res.code === '00000') {
|
if (res.code === '00000') {
|
||||||
@ -313,21 +326,21 @@ const getDetailData = async (row) => {
|
|||||||
throw new Error('获取事件详情失败')
|
throw new Error('获取事件详情失败')
|
||||||
}
|
}
|
||||||
if (res.code === '00000') {
|
if (res.code === '00000') {
|
||||||
if (dialogType.value === 'detail') {
|
if (drawerType.value === 'detail') {
|
||||||
model.title = `事件详情`;
|
drawer.title = `事件详情`;
|
||||||
model.content = DetailDialog;
|
drawer.content = DetailDialog;
|
||||||
model.props = {
|
drawer.props = {
|
||||||
detailData: res.data,
|
detailData: res.data,
|
||||||
};
|
};
|
||||||
model.onCancel = () => {
|
drawer.onCancel = () => {
|
||||||
dialogType.value = '';
|
drawerType.value = '';
|
||||||
modelVisible.value = false;
|
drawerVisible.value = false;
|
||||||
};
|
};
|
||||||
model.onConfirm = () => {
|
drawer.onConfirm = () => {
|
||||||
dialogType.value = '';
|
drawerType.value = '';
|
||||||
modelVisible.value = false;
|
drawerVisible.value = false;
|
||||||
};
|
};
|
||||||
modelVisible.value = true;
|
drawerVisible.value = true;
|
||||||
}
|
}
|
||||||
if (dialogType.value === 'edit') {
|
if (dialogType.value === 'edit') {
|
||||||
model.title = `编辑物资`;
|
model.title = `编辑物资`;
|
||||||
@ -433,5 +446,9 @@ export default () => {
|
|||||||
modelVisible,
|
modelVisible,
|
||||||
dialogRef,
|
dialogRef,
|
||||||
model,
|
model,
|
||||||
|
drawerVisible,
|
||||||
|
drawer,
|
||||||
|
drawerRef,
|
||||||
|
yhzid,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -65,6 +65,17 @@
|
|||||||
width="60%"
|
width="60%"
|
||||||
>
|
>
|
||||||
</MyDialog>
|
</MyDialog>
|
||||||
|
<MyDrawer
|
||||||
|
v-model="script.drawerVisible.value"
|
||||||
|
:title="script.drawer?.title"
|
||||||
|
:dynamicComponent="script.drawer?.content"
|
||||||
|
:component-props="script.drawer?.props"
|
||||||
|
:onConfirm="script.drawer?.onConfirm"
|
||||||
|
:onCancel="script.drawer?.onCancel"
|
||||||
|
ref="drawerRef"
|
||||||
|
:direction="script.drawer?.direction"
|
||||||
|
:size="script.drawer?.size"
|
||||||
|
></MyDrawer>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@ -73,6 +84,7 @@
|
|||||||
import scriptFn from "./index.js";
|
import scriptFn from "./index.js";
|
||||||
import DynamicTable from "../../component/DynamicTable";
|
import DynamicTable from "../../component/DynamicTable";
|
||||||
import MyDialog from "../../component/MyDialog";
|
import MyDialog from "../../component/MyDialog";
|
||||||
|
import MyDrawer from "../../component/MyDrawer";
|
||||||
|
|
||||||
const script = scriptFn();
|
const script = scriptFn();
|
||||||
const { treeRef, dialogRef } = script;
|
const { treeRef, dialogRef } = script;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user