From a0a1c206612de9a3e9d64f3d45564c0ff03f93f6 Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期四, 02 一月 2025 15:22:13 +0800
Subject: [PATCH] 环境
---
h5/pages/operation/record.vue | 38 ++++++++++++++++++++++++++++----------
1 files changed, 28 insertions(+), 10 deletions(-)
diff --git a/h5/pages/operation/record.vue b/h5/pages/operation/record.vue
index aaa32ae..21af5f5 100644
--- a/h5/pages/operation/record.vue
+++ b/h5/pages/operation/record.vue
@@ -3,11 +3,11 @@
<view class="head_wrap">
<view class="search_wrap">
<image class="mr12 search" src="@/static/home/ic_search@2x.png" mode="widthFix"></image>
- <input v-model="param.keyword" @confirm="getList()" type="text" placeholder="鎼滅储璁惧鍚嶇О/缂栧彿"
+ <input v-model="param.deviceName" @confirm="queryList" type="text" placeholder="鎼滅储璁惧鍚嶇О/缂栧彿"
placeholder-class="placeholder9" />
</view>
<view class="name_wrap" @click="handleMem">
- <view class="name">{{ param.realname ? param.realname : '杩愮淮浜�' }}</view>
+ <view class="name">{{ param.userName ? param.userName : '杩愮淮浜�' }}</view>
<u-icon :name="showModal ? 'arrow-right' : 'arrow-down'" color="#999999" size="12"></u-icon>
</view>
</view>
@@ -57,16 +57,32 @@
this.getpeo()
this.getList()
+ },
+ onReachBottom() {
+ const {total,list} = this
+ if (list.length < total) {
+ this.page = this.page + 1
+ this.getList()
+ } else {
+ this.showToast('鏆傛棤鏇村鏁版嵁')
+ }
},
mounted() {
this.$eventBus.$on('memberSel', (option) => {
- this.$set(this.param, 'realname', option.realname)
- this.$set(this.param, 'memberId', option.id)
+ this.$set(this.param, 'userName', option.realname)
+ this.$set(this.param, 'userId', option.id)
+ this.list = []
+ this.page = 1
this.getList()
})
},
- methods: {
+ methods: {
+ queryList() {
+ this.page = 1
+ this.list = []
+ this.getList()
+ },
getList() {
const {
page,
@@ -79,7 +95,7 @@
capacity: 10,
model: param
}).then(res => {
- this.list = res.data.records || []
+ this.list = [...this.list, ...res.data.records]
this.total = res.data.total
})
},
@@ -90,11 +106,13 @@
},
getpeo() {
findInternalList().then(res => {
- this.columns = [res.data]
+ this.columns = [...res.data]
})
},
- confirm() {
- this.showModal = false
+ confirm(e) {
+ console.log(e);
+ // this.showModal = false
+ // this.$set(this.param, 'userName', )
},
itemClick(item) {
uni.navigateTo({
@@ -107,7 +125,7 @@
<style lang="scss" scoped>
.main_app {
- padding: 0 30rpx;
+ padding: 30rpx;
}
.head_wrap {
--
Gitblit v1.9.3