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/Home/HomeLeft/MachineNestList.vue | 36 ++++++++++++++----------------------
1 files changed, 14 insertions(+), 22 deletions(-)
diff --git a/src/views/Home/HomeLeft/MachineNestList.vue b/src/views/Home/HomeLeft/MachineNestList.vue
index 5b12d6e..19fa753 100644
--- a/src/views/Home/HomeLeft/MachineNestList.vue
+++ b/src/views/Home/HomeLeft/MachineNestList.vue
@@ -5,13 +5,17 @@
<div class="machine-nest-list">
<MachineNestTotal @searchNickName="handleSearch" />
<div class="content-wrapper">
- <div
+ <!-- <div
class="table-list"
v-if="tableList.length > 0"
infinite-scroll-distance="6"
v-infinite-scroll="loadMore"
:infinite-scroll-disabled="busy"
infinite-scroll-immediate="true"
+ > -->
+ <div
+ class="table-list"
+ v-if="tableList.length > 0"
>
<div
:class="[index % 2 === 1 ? 'table-itemeven' : 'table-item']"
@@ -73,7 +77,7 @@
// 分页参数
const pageParams = ref({
current: 1,
- size: 8,
+ size: 99,
total: 0,
})
@@ -83,14 +87,15 @@
const getTableList = () => {
const params = {
nickname: searchText.value,
- current: pageParams.value.current,
+ current: 1,
size: pageParams.value.size,
}
selectDevicePage(params).then(res => {
if (res.data.code !== 0) return
if (res.data.data.records.length === 0) return (isMore.value = false)
- pageParams.value.current += 1
- tableList.value = [...tableList.value, ...res.data.data.records]
+ // pageParams.value.current += 1
+ // pageParams.value.size += 8
+ tableList.value = res.data.data.records;// [...tableList.value, ...res.data.data.records]
busy.value = false
})
}
@@ -105,18 +110,6 @@
searchText.value = name
pageParams.value.current = 1
tableList.value = []
- getTableList()
-}
-
-// 分页方法
-const handleSizeChange = val => {
- pageParams.value.size = val
- pageParams.value.current = 1
- getTableList()
-}
-
-const handleCurrentChange = val => {
- pageParams.value.current = val
getTableList()
}
@@ -184,7 +177,7 @@
padding-top: 6px;
margin-top: 10px;
- height: 120px;
+ height: 100px;
}
img {
width: 45px;
@@ -220,13 +213,12 @@
}
// 空闲中
.freetime {
- color: #ffa768;
+ color: #04f020;
}
// 作业中
.atcive {
- color: #04f020;
- background: linear-gradient(90deg, rgba(12, 45, 92, 1) 0%, #154671 50%, rgba(12, 45, 92, 1) 100%),
- linear-gradient(90deg, rgba(12, 45, 92, 1) 0%, rgba(12, 45, 92, 1) 50%, rgba(12, 45, 92, 1) 100%);
+ color: #ffa768;
+
}
.numbering {
font-size: 12px;
--
Gitblit v1.9.3