19 changed files with 542 additions and 153 deletions
@ -0,0 +1,85 @@ |
|||
const app = getApp() |
|||
import { getCheckLogList } from "../../../../utils/api" |
|||
Page({ |
|||
|
|||
/** |
|||
* 页面的初始数据 |
|||
*/ |
|||
data: { |
|||
statusHeight: '', |
|||
navigationHeight: '', |
|||
tableData: [], |
|||
lowerThreshold: '10', |
|||
loadMoreVisible: false, |
|||
nodata: false, |
|||
loadMoreType: 'more', |
|||
resiId: '', |
|||
pageSize: 10, |
|||
pageNo: 1 |
|||
}, |
|||
|
|||
/** |
|||
* 生命周期函数--监听页面加载 |
|||
*/ |
|||
onLoad(options) { |
|||
this.setData({ |
|||
statusHeight: app.globalData.deviceInfo.statusHeight, |
|||
navigationHeight: app.globalData.deviceInfo.navigationHeight, |
|||
resiId: options.resiId |
|||
}) |
|||
this.getTable() |
|||
}, |
|||
/** |
|||
* 用户点击右上角分享 |
|||
*/ |
|||
onShareAppMessage() { |
|||
|
|||
}, |
|||
onScrollToLower(e) { |
|||
if (this.data.loadMoreType === 'more') { |
|||
this.setData({ |
|||
loadMoreVisible: true, |
|||
}) |
|||
this.data.pageNo += 1 |
|||
this.getTable() |
|||
} |
|||
}, |
|||
getTable() { |
|||
this.setData({ |
|||
loadMoreVisible: true, |
|||
nodata: false, |
|||
loadMoreType: "more", |
|||
}) |
|||
let parm = { |
|||
resiId: this.data.resiId, |
|||
pageSize: this.data.pageSize, |
|||
pageNo: this.data.pageNo |
|||
} |
|||
getCheckLogList(parm).then(res => { |
|||
console.log(res, 'rrr') |
|||
if (res.data) { |
|||
this.setData({ |
|||
loadMoreType: res.data.list.length === this.data.pageSize ? 'more' : 'none', |
|||
tableData: this.data.tableData.concat(res.data.list), |
|||
}) |
|||
if (this.data.tableData.length == 0) { |
|||
this.setData({ |
|||
loadMoreVisible: false, |
|||
loadMoreType: '', |
|||
nodata: true |
|||
}) |
|||
} |
|||
} else { |
|||
this.setData({ |
|||
loadMoreType: '', |
|||
nodata: true |
|||
}) |
|||
} |
|||
}).catch(err => { |
|||
console.log(err); |
|||
}) |
|||
}, |
|||
back() { |
|||
wx.navigateBack() |
|||
}, |
|||
}) |
@ -0,0 +1,7 @@ |
|||
{ |
|||
"navigationStyle": "custom", |
|||
"usingComponents": { |
|||
"load-more": "../../../../components/loadMore/loadMore", |
|||
"no-data": "../../../../components/noData/nodata" |
|||
} |
|||
} |
@ -0,0 +1,24 @@ |
|||
<!--subpages/searchResult/pages/searchResult/searchResult.wxml--> |
|||
<view class="header"> |
|||
<image src="../../../../images/back.png" class="back" style=" top: {{statusHeight}}px;width: 50rpx;height: 50rpx;" bindtap="back" mode="" /> |
|||
<view class="navigation" style="height: {{navigationHeight}}px; top: {{statusHeight}}px;"> |
|||
打卡记录 |
|||
</view> |
|||
</view> |
|||
<view class="content"> |
|||
|
|||
<scroll-view class="scroll" scroll-y="{{true}}" lower-threshold="{{ lowerThreshold }}" bindscrolltolower="onScrollToLower"> |
|||
<view class="card"> |
|||
<view class="list_card" wx:for="{{tableData}}" wx:key="index"> |
|||
<view class="left"> |
|||
<view class="name">打卡人:{{item.name}}</view> |
|||
<view class="time">打卡时间:{{item.clockInTime}}</view> |
|||
<view class="address">打卡地址: {{item.clockInAddress}}</view> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
<load-more loadVisible="{{loadMoreVisible}}" loadType="{{loadMoreType}}"></load-more> |
|||
<no-data isShow="{{nodata}}" wx:if="{{nodata}}"></no-data> |
|||
</scroll-view> |
|||
|
|||
</view> |
@ -0,0 +1,107 @@ |
|||
/* subpages/searchResult/pages/searchResult/searchResult.wxss */ |
|||
page { |
|||
width: 100%; |
|||
min-height: 100vh; |
|||
overflow: hidden; |
|||
background-color: #f7f7f7; |
|||
} |
|||
.header { |
|||
width: 100%; |
|||
height: 532rpx; |
|||
background: linear-gradient(180deg, #7DB5FF 0%, #E8F2FF 66%, #F7F7F7 100%); |
|||
} |
|||
|
|||
.header .header-bg { |
|||
width: 100%; |
|||
height: 100%; |
|||
/* position: absolute; |
|||
z-index: 10; |
|||
left: 0; |
|||
top: 0; */ |
|||
position: absolute; |
|||
height: 100%; |
|||
z-index: -999; |
|||
} |
|||
|
|||
.header .navigation { |
|||
width: 100%; |
|||
display: flex; |
|||
align-items: center; |
|||
justify-content: center; |
|||
font-size: 32rpx; |
|||
position: relative; |
|||
z-index: 1; |
|||
} |
|||
.back { |
|||
width: 30rpx; |
|||
height: 30rpx; |
|||
margin-left: 20rpx; |
|||
position: absolute; |
|||
margin-top: 20rpx; |
|||
border-radius: 0rpx; |
|||
z-index: 2; |
|||
} |
|||
|
|||
|
|||
.content{ |
|||
height: auto; |
|||
width: 100%; |
|||
overflow: hidden; |
|||
position: relative; |
|||
top: -350rpx; |
|||
padding: 0 20rpx; |
|||
box-sizing: border-box; |
|||
} |
|||
.content .scroll { |
|||
height: calc(100vh - 150rpx); |
|||
overflow-y: scroll; |
|||
} |
|||
.content .scroll .card{ |
|||
background-color: #fff; |
|||
border-radius: 20rpx; |
|||
padding: 0 30rpx; |
|||
box-sizing: border-box; |
|||
} |
|||
.content .card .list_card{ |
|||
display: flex; |
|||
justify-content: space-around; |
|||
padding: 30rpx 0; |
|||
align-items: center; |
|||
color: #333333; |
|||
border-top: 1px solid #EAEAEA; |
|||
} |
|||
.content .card .list_card .left{ |
|||
flex: 1; |
|||
height: 100%; |
|||
display: flex; |
|||
flex-direction: column; |
|||
justify-content: space-between; |
|||
font-size: 28rpx; |
|||
font-family: PingFang SC; |
|||
font-weight: 500; |
|||
overflow: hidden; |
|||
text-overflow: ellipsis; |
|||
white-space: nowrap; |
|||
} |
|||
|
|||
.content .card .list_card .left .address{ |
|||
/* font-size: 28rpx; */ |
|||
font-family: PingFang SC; |
|||
font-weight: 500; |
|||
color: #999999; |
|||
} |
|||
|
|||
.flex-sb { |
|||
display: flex; |
|||
justify-content: space-between; |
|||
} |
|||
.time { |
|||
color: #999; |
|||
margin: 10rpx 0; |
|||
/* font-size: 28rpx; */ |
|||
} |
|||
|
|||
.name { |
|||
font-size: 32rpx; |
|||
/* font-size: 28rpx; */ |
|||
} |
@ -1,20 +1,20 @@ |
|||
<view class="user-info"> |
|||
<view class="name">{{name}} {{mobile}}</view> |
|||
<view class="address">{{agencyName}}</view> |
|||
<view class="address">{{agencyName&&agencyName!=='null'?agencyName:''}}</view> |
|||
</view> |
|||
<view class="qz-container"> |
|||
<view class="list"> |
|||
<view class="item" wx:for="{{list}}" wx:key="{{index}}"> |
|||
<view class="title"> |
|||
<view class="blue">{{item.categoryName}}</view> |
|||
<view class="time">{{item.happenTime}}</view> |
|||
<view class="blue">{{item.categoryName?item.categoryName:''}}</view> |
|||
<view class="time">{{item.happenTime?item.happenTime:''}}</view> |
|||
</view> |
|||
<view class="content"> |
|||
{{item.eventContent}} |
|||
</view> |
|||
<view class="status"> |
|||
<text>{{item.latestProcessingTime}}</text> |
|||
<text>{{item.latestProcessingStatus}}</text> |
|||
<text>{{item.latestProcessingTime?item.latestProcessingTime:''}}</text> |
|||
<text>{{item.latestProcessingStatus?item.latestProcessingStatus:''}}</text> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
|
Loading…
Reference in new issue