From 2800fa4f32f3900509cb4d6eefaf2bfaf54efdd7 Mon Sep 17 00:00:00 2001
From: 罗广辉 <guanghui.luo@foxmail.com>
Date: Mon, 21 Apr 2025 18:29:09 +0800
Subject: [PATCH] fix: 天气显示
---
src/views/SignMachineNest/MachineRight/MachineStatus/MachineTableDetails/MachineTableDetails.vue | 82 ++++++++++-------------------------------
1 files changed, 20 insertions(+), 62 deletions(-)
diff --git a/src/views/SignMachineNest/MachineRight/MachineStatus/MachineTableDetails/MachineTableDetails.vue b/src/views/SignMachineNest/MachineRight/MachineStatus/MachineTableDetails/MachineTableDetails.vue
index 2d2e393..884c8bc 100644
--- a/src/views/SignMachineNest/MachineRight/MachineStatus/MachineTableDetails/MachineTableDetails.vue
+++ b/src/views/SignMachineNest/MachineRight/MachineStatus/MachineTableDetails/MachineTableDetails.vue
@@ -1,12 +1,11 @@
<!-- 机巢列表详情 -->
<template>
<el-dialog
- class="machineTableDetails"
+ class="machineTableDetails ztzf-dialog"
v-model="isShowDetails"
:width="pxToRem(1500)"
:close-on-click-modal="false"
:destroy-on-close="true"
-
>
<template #header="{ titleId, titleClass }">
<div class="my-header">
@@ -18,25 +17,28 @@
<div class="machineTableDetailsTitle"><span>详情</span></div>
<div class="infoBox">
<div class="itemBox" v-for="(item, index) in infoList" :key="index">
- <div class="itemTitle">{{ item.name }} : </div>
+ <div class="itemTitle">{{ item.name }} :</div>
+ <div v-if="item.name == '任务成果'" class="missionOutcomes">
+ <span>{{item.value ? item.value :0}}</span>
+ 个
+ </div>
<div
+ v-if="item.name == '机巢状态'"
:class="{
active: item.value === 'WORKING',
freetime: item.value === 'LEISURE',
offine: item.value === 'OFFLINE',
}"
- v-if="item.name == '机巢状态'"
>
{{ item.value === 'OFFLINE' ? '离线中' : item.value === 'WORKING' ? '作业中' : '空闲中' }}
</div>
- <div class="itemValue" v-else> {{ item.value }}</div>
+ <div class="itemValue" v-else>{{ item.value }}</div>
</div>
</div>
</div>
<DeviceJob v-if="isShowDetails" />
<DeviceEvent v-if="isShowDetails" />
</el-dialog>
-
</template>
<script setup>
@@ -55,7 +57,7 @@
{ name: '机巢状态', value: '', field: 'status' },
])
const store = useStore()
-const singleTotal = computed(() => store.state.home.singleTotal)
+const singleTotal = inject('singleTotal')
watch(singleTotal, val => {
if (val?.device_info) {
infoList.value.forEach(item => {
@@ -68,83 +70,32 @@
<style lang="scss">
.machineTableDetails {
-width: 1270px;
- height: 856px;
- background: #0f1929;
- box-shadow: inset 0px -50px 50px 0px rgba(27, 148, 255, 0.13);
- border-radius: 20px 0px 0px 0px;
- border: 2px solid;
- padding: 0 !important;
- border-image: linear-gradient(
- 180deg,
- rgba(81, 168, 255, 0),
- rgba(48, 111, 202, 1),
- rgba(255, 255, 255, 1),
- rgba(27, 148, 255, 1)
- )
- 2 2;
.el-pagination {
text-align: left;
- padding: 20px 20px 0 20px;
+ padding: 10px 20px 5px 10px;
}
.my-header {
display: inline-block;
vertical-align: middle;
margin-left: 12px;
}
-
- /* 头部 */
- .el-dialog__header {
- width: 1270px;
- height: 47px;
- margin-bottom: 14px;
- background: url('/src/assets/images/home/homeLeft/inspection-vector.png') no-repeat center;
- background-size: 100% 100%;
- font-weight: bold;
- font-size: 16px;
- line-height: 47px;
- }
-
- .el-dialog .el-dialog__header {
- /* margin: 0px !important; */
- padding: 0px !important;
- padding-left: 0px !important;
- }
- /* 头部 */
- .el-dialog__title {
- width: 112px;
- height: 19px;
- font-family: Segoe UI, Segoe UI;
- font-weight: bold;
- font-size: 16px;
- line-height: 16px;
- text-shadow: 0px 0px 5px rgba(154, 218, 255, 0.6);
- text-align: left;
- font-style: normal;
- text-transform: none;
- background: linear-gradient(90deg, #fbfdff 0%, #86d4ff 100%);
- margin-left: 16px;
- -webkit-background-clip: text; /* 背景被裁剪成文字的前景色 */
- -webkit-text-fill-color: transparent; /* 文字填充颜色变透明 */
- }
}
</style>
<style lang="scss" scoped>
-
.infoBox {
display: flex;
justify-content: space-between;
align-items: center;
- margin-bottom: 14px;
+ margin-bottom: 10px;
font-size: 14px;
color: #ffffff;
.itemBox {
display: flex;
align-items: center;
.itemTitle {
- margin-right: 5px;
+ margin-right: 5px;
}
}
@@ -162,7 +113,7 @@
margin: 0 24px;
}
.machineTableDetailsTitle {
- margin-bottom: 16px;
+ margin-bottom: 10px;
background: url('/src/assets/images/signMachineNest/machineRight/detailtitle.png') no-repeat center;
background-size: 100% 100%;
span {
@@ -175,6 +126,13 @@
margin-bottom: 8px;
}
}
+.missionOutcomes {
+ span {
+ color: #ffa500;
+ font-size: 14px;
+ font-weight: bold;
+ }
+}
// 离线中
.offine {
width: 53px;
--
Gitblit v1.9.3