From 4bb904fc27caf0576ed7dbf46d5909a7b1f778c0 Mon Sep 17 00:00:00 2001
From: chenyao <1219716595@qq.com>
Date: Mon, 14 Jul 2025 09:52:28 +0800
Subject: [PATCH] Merge branch 'test' of http://139.196.74.78:10010/r/drone/drone-web-manage into test
---
src/views/device/airport.vue | 96 +++++++++++++++++++++++++++++++++++++++++++-----
1 files changed, 86 insertions(+), 10 deletions(-)
diff --git a/src/views/device/airport.vue b/src/views/device/airport.vue
index 7083e01..5d2415f 100644
--- a/src/views/device/airport.vue
+++ b/src/views/device/airport.vue
@@ -1,5 +1,5 @@
<template>
- <basic-container>
+ <basic-main-content>
<avue-crud
:option="option"
:table-loading="loading"
@@ -185,6 +185,7 @@
</el-dialog>
<el-drawer
+ class="ztzf-drawer-body-basic-container"
title="机场授权管理"
size="60%"
append-to-body
@@ -202,7 +203,7 @@
>
</DockControlPanel>
</el-drawer>
- </basic-container>
+ </basic-main-content>
</template>
<script>
@@ -270,8 +271,7 @@
option: {
lazy: true,
tree: true,
- height: '460',
- calcHeight: 32,
+
dialogWidth: 1050,
tip: false,
searchShow: true,
@@ -284,6 +284,10 @@
addBtn: false,
dialogClickModal: false,
grid: false,
+
+ height: 'auto',
+ calcHeight: 180,
+
column: [
{
label: '设备型号',
@@ -428,10 +432,20 @@
},
{
label: '行政区划',
+ prop: 'area_name',
+ hide: true,
+ editDisplay: false, //编辑显示
+ viewDisplay: true, //查看显示
+ labelWidth: 130,
+ },
+ {
+ label: '行政区划',
prop: 'area_code',
type: 'cascader',
labelWidth: 130,
hide: true,
+ editDisplay: true,
+ viewDisplay: false,
props: {
label: 'title',
value: 'value',
@@ -494,6 +508,26 @@
}
},
},
+
+ {
+ hide: true,
+ label: '保险有效期',
+ prop: 'duration_of_insurance',
+ labelWidth: 130,
+ type: 'daterange',
+ format: 'YYYY-MM-DD',
+ valueFormat: 'YYYY-MM-DD HH:mm:ss',
+ startPlaceholder: '保险开始日期',
+ endPlaceholder: '保险结束日期',
+ rules: [
+ {
+ required: true,
+ message: '请选择保险有效期',
+ trigger: 'blur',
+ },
+ ],
+ },
+
{
label: '在线时间',
prop: 'login_time',
@@ -513,14 +547,25 @@
},
],
},
+ {
+ label: '在线状态',
+ prop: 'cnstatus',
+ hide: true,
+ addDisplay: false,
+ editDisplay: false,
+ viewDisplay: true,
+ labelWidth: 130,
+ },
{
label: '在线状态',
prop: 'status',
addDisplay: false,
editDisplay: false,
+ viewDisplay: false,
labelWidth: 130,
slot: true,
width: 100,
+
rules: [
{
required: true,
@@ -531,12 +576,24 @@
},
{
label: '机场状态',
- prop: 'mode_code',
+ prop: 'cnmode_code',
+ hide: true,
addDisplay: false,
editDisplay: false,
+ viewDisplay: true,
+ labelWidth: 130,
+ },
+ {
+ label: '机场状态',
+ prop: 'mode_code',
+
+ addDisplay: false,
+ editDisplay: false,
+ viewDisplay: false,
labelWidth: 130,
slot: true,
width: 100,
+
rules: [
{
required: true,
@@ -566,10 +623,10 @@
...mapGetters(['permission']),
permissionList() {
return {
- addBtn: this.validData(this.permission.airport_add, true),
- viewBtn: this.validData(this.permission.airport_view, true),
- delBtn: this.validData(this.permission.airport_delete, true),
- editBtn: this.validData(this.permission.airport_edit, true),
+ addBtn: this.validData(this.permission.air_add, true),
+ viewBtn: this.validData(this.permission.air_view, true),
+ delBtn: this.validData(this.permission.air_delete, true),
+ editBtn: this.validData(this.permission.air_edit, true),
};
},
ids() {
@@ -967,7 +1024,11 @@
const submitData = {
...row,
area_code: row.area_code.split(',').pop(),
+ insure_start_time: row.duration_of_insurance[0],
+ insure_expired_time: row.duration_of_insurance[1],
};
+
+ delete submitData.duration_of_insurance;
update(submitData).then(
() => {
@@ -1065,10 +1126,16 @@
this.form = {
...data,
area_code: this.getFullAreaCode(data.area_code),
+ area_name: this.form.area_name,
+ cnmode_code: this.getDockModeText(this.form.mode_code),
+ cnstatus:this.form.status === false ? '离线':'在线',
+ duration_of_insurance: [data?.insure_start_time || '', data?.insure_expired_time || ''],
};
+ console.log('this.form', this.form);
+
+ done();
});
}
- done();
},
currentChange(currentPage) {
this.page.currentPage = currentPage;
@@ -1129,40 +1196,48 @@
color: #40cb8b;
font-size: 13px;
}
+
.status1 {
float: right;
color: #8492a6;
font-size: 13px;
}
+
.online {
margin-left: 5px;
}
+
.onlineStatus1 {
display: flex;
flex-direction: column;
align-items: center;
}
+
.onlineStatus {
display: flex;
flex-direction: row;
align-items: center;
}
+
.onlineStatus-dot {
width: 15px;
height: 15px;
background-color: #40cb8b;
border-radius: 50%;
}
+
.onlineStatus-dot1 {
width: 15px;
height: 15px;
background-color: #de5e5e;
border-radius: 50%;
}
+
.firmware_status {
background-color: aqua;
border-radius: 4px;
}
+
.firmware_status:hover {
cursor: pointer;
/* color: aqua; */
@@ -1170,6 +1245,7 @@
.active-element {
cursor: pointer;
+
&:hover {
background-color: #409eff;
border-color: #409eff;
--
Gitblit v1.9.3