From 7f65dc2afe9377004ab5a0348dc1fddf764868db Mon Sep 17 00:00:00 2001
From: "3321822538@qq.com" <3321822538@qq.com>
Date: Tue, 10 Dec 2024 09:26:56 +0800
Subject: [PATCH] =?UTF-8?q?=E5=BC=80=E5=85=B3?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
page_user/mapditu/index.vue | 214 ++++++++++++++++++++++++++++++++----
1 file changed, 194 insertions(+), 20 deletions(-)
diff --git a/page_user/mapditu/index.vue b/page_user/mapditu/index.vue
index 1af546f..12d07d2 100644
--- a/page_user/mapditu/index.vue
+++ b/page_user/mapditu/index.vue
@@ -38,17 +38,62 @@
共享时间:{{listobj.businessTimeStart == undefined ? '--' : listobj.businessTimeStart}}-{{listobj.businessTimeEnd == undefined ? '--' : listobj.businessTimeEnd}} {{listobj.availableDeviceCount}}台可共享
+ class="bu">{{listobj.availableDeviceCount == undefined ? '--' : listobj.availableDeviceCount}}台可共享
-
+
+
+
+
+
+
+
+
+
+ {{item.deviceName}}
+
+
+
+
+ 维修中
+
+
+ 使用中
+
+
+ 空闲
+
+
+
+ S/N码:{{item.deviceNo}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 暂无更多设备...
+
+
+
@@ -88,6 +133,13 @@
mapScaleInterval: null,
listmap: [],
iconflag: false,
+ pagenum: 1,
+ wateringList: [],
+ pagesize: 10,
+ isLoading: false,
+ noMoreData: false,
+ total: 0,
+ showflag:false,
}
},
onLoad(option) {
@@ -97,6 +149,7 @@
this.falgb = true
}
this.getxq()
+ this.getlist()
},
onReady() {
this.mapContext = uni.createMapContext('map', this);
@@ -126,6 +179,40 @@
}
},
methods: {
+ getlist() {
+ this.$u.get(`/app/device/listByStore/${this.storeId}?pageNum=${this.pagenum}&pageSize=${this.pagesize}`)
+ .then((res) => {
+ if (res.code == 200) {
+ this.total = res.total
+ if (this.total > 0) {
+ this.showflag = false
+ } else {
+ this.showflag = true
+ }
+ if (res.rows.length > 0) {
+ // 有数据,追加到列表
+ this.wateringList = this.wateringList.concat(res.rows)
+ this.pagenum++
+ } else {
+ // 没有更多数据
+ this.noMoreData = true;
+ }
+ this.isLoading = false;
+ }
+ })
+ },
+ onReachBottom() {
+ let sum = this.total / this.pagesize
+ if (this.pagenum - 1 < sum) {
+ this.getlist(); // 上拉加载更多
+ } else {
+ uni.showToast({
+ title: '没有更多设备了',
+ icon: 'none',
+ duration: 1000
+ });
+ }
+ },
// 查询拖动到指定为止的店铺
regionchange(e) {
this.iconflag = true
@@ -326,7 +413,11 @@
},
})
},
-
+ btnxq(id) {
+ uni.navigateTo({
+ url: '/page_components/fuwu/index?id=' + id
+ })
+ },
getMyLocation() {
uni.getLocation({
type: 'wgs84',
@@ -442,7 +533,7 @@
}
page {
- background: linear-gradient(180deg, #D9D8FF 0%, rgba(255, 255, 255, 0) 100%);
+ background:#D9D8FF;
border-radius: 0rpx 0rpx 0rpx 0rpx;
}
@@ -451,20 +542,96 @@
position: fixed;
top: 0;
left: 0;
-
+ .swiper {
+ .swiper-item {
+ height: 100%;
+
+ .card_box {
+ margin-top: 34rpx;
+ display: flex;
+ flex-wrap: wrap;
+
+ .card {
+ display: flex;
+ margin-top: 20rpx;
+ width: 672rpx;
+ height: 250rpx;
+ background: #fff;
+ box-shadow: 0rpx 16rpx 40rpx 0rpx rgba(255, 255, 255, 0);
+ border-radius: 24rpx 24rpx 24rpx 24rpx;
+
+ .card_left {
+ width: 310rpx;
+ margin-top: 46rpx;
+ margin-left: 50rpx;
+
+ .card_left_tit {
+ font-size: 44rpx;
+ font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
+ font-weight: 500;
+ color: #8883F0;
+ }
+
+ .card_left_sta {
+
+ margin-top: 15rpx;
+ display: flex;
+ flex-wrap: nowrap;
+ align-items: center;
+
+ image {
+ width: 23.32rpx;
+ height: 36.47rpx;
+
+ }
+
+ .sta_txt {
+ margin-left: 15rpx;
+ color: #262B37;
+ font-size: 26rpx;
+ font-family: HarmonyOS Sans SC, HarmonyOS Sans SC;
+ font-weight: 400;
+ }
+ }
+
+ .card_left_no {
+ margin-top: 15rpx;
+ font-size: 26rpx;
+ font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
+ font-weight: 400;
+ color: #95989D;
+ }
+ }
+
+ .card_right {
+ margin-top: 30rpx;
+ margin-left: auto;
+ margin-right: 40rpx;
+
+ image {
+ width: 180rpx;
+ height: 180rpx;
+ border-radius: 20rpx;
+ }
+ }
+ }
+ }
+ }
+ }
.list_item {
position: fixed;
- bottom: 84rpx;
- left: 50%;
- transform: translateX(-50%);
- width: 706rpx;
- height: 420rpx;
- background: #FFFFFF;
- box-shadow: 0rpx 10rpx 64rpx 0rpx rgba(0, 0, 0, 0.08);
- border-radius: 20rpx;
- margin: auto;
- padding: 46rpx 40rpx;
- box-sizing: border-box;
+ top: 160rpx;
+ left: 50%;
+ -webkit-transform: translateX(-50%);
+ transform: translateX(-50%);
+ width: 100%;
+ height: 91vh;
+ background: #f8f8f8;
+ box-shadow: 0rpx 10rpx 64rpx 0rpx rgba(0, 0, 0, 0.08);
+ border-radius: 20rpx;
+ margin: auto;
+ padding: 46rpx 40rpx;
+ box-sizing: border-box;
.chakan {
display: flex;
@@ -486,8 +653,14 @@
.anniu {
display: flex;
- justify-content: space-between;
- margin-top: 20rpx;
+ justify-content: space-between;
+ margin-top: 20rpx;
+ position: fixed;
+ left: 50%;
+ transform: translateX(-50%);
+ width: 100%;
+ padding: 60rpx;
+ bottom: 20rpx;
view {
width: 300rpx;
@@ -506,7 +679,8 @@
.list {
display: flex;
padding-bottom: 16rpx;
-
+ justify-content: space-between;
+ align-items: center;
.pic {
width: 150rpx;
height: 150rpx;
@@ -523,7 +697,7 @@
.cen {
margin-left: 20rpx;
-
+ margin-top: 30rpx;
.cena {
font-weight: 500;
font-size: 30rpx;