From 7a2a586d6737847c8cba6f551a38fedc34af6fa0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=93=E6=B4=81?= <209192278@qq.com> Date: Fri, 29 Dec 2023 21:54:56 +0800 Subject: [PATCH] =?UTF-8?q?=E9=82=93=E6=B4=81:=20=E4=BF=AE=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/content/airInfo/AirInfo.vue | 21 ++++++++--------- src/router/index.js | 2 +- src/views/edit/edit.vue | 4 ++-- src/views/login/index.vue | 4 ++-- src/views/site/index.vue | 6 ++++- src/views/tunnel/index.vue | 26 ++++++++++------------ src/views/user/index.vue | 13 ++++++----- 7 files changed, 40 insertions(+), 36 deletions(-) diff --git a/src/components/content/airInfo/AirInfo.vue b/src/components/content/airInfo/AirInfo.vue index af1d516..fad3f92 100644 --- a/src/components/content/airInfo/AirInfo.vue +++ b/src/components/content/airInfo/AirInfo.vue @@ -6,15 +6,16 @@
风速{{ windSpeed }}m/s
- + +
@@ -87,7 +88,7 @@ watch(() => props.list, (now) => { }) }, {deep: true}); watch(() => props.airData, (now) => { - if(now.sensorList===null){ + if(now.sensorList.length===0){ airList.value=[] }else { getAirInfo(now.sensorList) diff --git a/src/router/index.js b/src/router/index.js index 94a2513..83a28a1 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -60,7 +60,7 @@ const routes = [ } }, { - path: '/tunnel/:siteId/:type/:userId', + path: '/tunnel/:siteId(\\d+)/:type/:userId(\\d+)', name: 'tunnel', component: () => import('@/views/tunnel-manage/index.vue'), meta: { diff --git a/src/views/edit/edit.vue b/src/views/edit/edit.vue index e5438f2..8b1c9f5 100644 --- a/src/views/edit/edit.vue +++ b/src/views/edit/edit.vue @@ -93,8 +93,8 @@ const handleSave = async () => { tunnelName: form.value.tunnelName, serialNumber: form.value.serialNumber, remarks: form.value.remarks, - // constructionLength:form.value.constructionLength, - constructionLength: 500, + constructionLength:form.value.constructionLength, + // constructionLength: 500, tunnelLength: form.value.totalLength, isDefault: form.value.isDefault, modelEquipmentList: await store.getEquipmentList(), diff --git a/src/views/login/index.vue b/src/views/login/index.vue index aeb283f..3c5eb24 100644 --- a/src/views/login/index.vue +++ b/src/views/login/index.vue @@ -46,8 +46,8 @@ const router = useRouter(); const authStore = useAuthStore(); const loginForm = reactive({ // username: "admin", - password: "", - username: "", + password: "123456", + username: "admin", // password: "", code: "", uuid: "", diff --git a/src/views/site/index.vue b/src/views/site/index.vue index 3f7b6b3..997db05 100644 --- a/src/views/site/index.vue +++ b/src/views/site/index.vue @@ -169,7 +169,11 @@ const getList = () => { ...pageInfo }).then((res) => { total.value = res.data.total; - showAddIcon.value = total.value % 6!==0; + if(total.value==0){ + + }else { + showAddIcon.value = total.value % 6!==0; + } showFirst.value = total.value / pageInfo.pageSize > 1; res.data.rows.map(item => { if (item.tunnelList === null || item.tunnelList.length === 0) { diff --git a/src/views/tunnel/index.vue b/src/views/tunnel/index.vue index 08b0161..9735023 100644 --- a/src/views/tunnel/index.vue +++ b/src/views/tunnel/index.vue @@ -1,14 +1,12 @@