过滤器小程序
This commit is contained in:
@@ -0,0 +1,277 @@
|
||||
<template>
|
||||
<view>
|
||||
<tui-sticky :scrollTop="scrollTop" stickyHeight="104rpx" container v-for="(item,index) in position_record" :key="index">
|
||||
<template v-slot:header>
|
||||
<view class="sticky-item">
|
||||
<view class="date">{{item.month}}</view>
|
||||
<view class="amount">
|
||||
<view>录入点位次数: <text style="color:#ff0000;font-size: 36rpx;font-weight: 600;"> {{item.count}}</text></view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</template>
|
||||
<template v-slot:content>
|
||||
<!--内容 start-->
|
||||
<view class="list-view" v-for="(it,ind) in item.details" :key="ind">
|
||||
<view class="tui-list-item" hover-class="tui-hover" :hover-stay-time="150">
|
||||
<view class="content-box">
|
||||
<image :src="apiHost+'/miniapp/static/release.png'" class="logo"></image>
|
||||
<view class="des-box">
|
||||
<view class="tit">{{it.courtyard}}</view>
|
||||
<view class="time">{{it.building}}({{it.layer}})</view>
|
||||
<view class="time">安装位置:{{it.scription}}</view>
|
||||
<view class="time">安装时间:{{it.created_at}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="money add" >{{it.hospital}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
</tui-sticky>
|
||||
<tui-loadmore style="position:relative;top:-20rpx" v-if="showloadmore"></tui-loadmore>
|
||||
<tui-nomore style="position:relative;top:-20rpx" v-if="shownomore"></tui-nomore>
|
||||
<tui-tabbar :current="tabbarCurrent" backdropFilter :backgroundColor="tabbarBackgroundColor" :tabBar="tabBar" color="#777" selectedColor="#AC9157" @click="tabbarSwitch"></tui-tabbar>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import myapp from '@/common/js/myapp.js'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
apiHost: myapp.apiHost,
|
||||
scrollTop: 0,
|
||||
showloadmore: false,
|
||||
shownomore: false,
|
||||
opts: {
|
||||
legend:{
|
||||
show: false
|
||||
},
|
||||
extra: {
|
||||
column:{
|
||||
width: 10
|
||||
}
|
||||
}
|
||||
},
|
||||
position_record: {},
|
||||
tabBar: myapp.tabBar,
|
||||
tabbarCurrent: 1,
|
||||
tabbarBackgroundColor: '#FFF'
|
||||
}
|
||||
},
|
||||
onLoad: function() {
|
||||
let user = myapp.checkLogin()
|
||||
uni.setStorageSync('lastPagePath', '/packagePage/pages/record/record')
|
||||
|
||||
let that = this;
|
||||
// 点位统计
|
||||
myapp.request('/?c=position&a=getPositionIndexList',function(res) {
|
||||
that.position_record = res.data.data
|
||||
},{token:user.token})
|
||||
},
|
||||
methods: {
|
||||
tabbarSwitch: myapp.tabbarSwitch,
|
||||
showDetail: function() {
|
||||
},
|
||||
//页面滚动执行方式
|
||||
onPageScroll(e) {
|
||||
this.scrollTop = e.scrollTop
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
@import '../../../static/style/thorui.css';
|
||||
|
||||
page {
|
||||
background-color: #F5F6FA;
|
||||
}
|
||||
|
||||
.container {
|
||||
padding-bottom: env(safe-area-inset-bottom);
|
||||
}
|
||||
|
||||
.tui-flex-box {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
flex-direction: row-reverse;
|
||||
justify-content: flex-start;
|
||||
align-items: flex-start;
|
||||
position: relative;
|
||||
top:-80rpx;
|
||||
}
|
||||
|
||||
.charts-box {
|
||||
width: 100%;
|
||||
height: 200px;
|
||||
background-color: #FFF;
|
||||
}
|
||||
|
||||
.tips {
|
||||
background: #fff;
|
||||
padding: 30rpx 14rpx;
|
||||
color: #555;
|
||||
font-size: 24rpx;
|
||||
line-height: 42rpx;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.tips::before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
border-top: 1rpx solid #eaeef1;
|
||||
-webkit-transform: scaleY(0.5);
|
||||
transform: scaleY(0.5);
|
||||
top: 0;
|
||||
right: 0;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
/* sticky 容器 start */
|
||||
.sticky-item {
|
||||
width: 100%;
|
||||
height: 104rpx;
|
||||
padding: 20rpx 30rpx;
|
||||
background-color: #fafafa;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
/* sticky 容器 end */
|
||||
|
||||
.date {
|
||||
height: 54rpx;
|
||||
font-size: 28rpx;
|
||||
background-color: #fff;
|
||||
padding: 0 28rpx;
|
||||
border-radius: 25rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: relative;
|
||||
/* box-shadow: 0 0 1rpx #7A7A7A; */
|
||||
}
|
||||
|
||||
.date::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
height: 200%;
|
||||
width: 200%;
|
||||
border: 1rpx solid #eaeef1;
|
||||
border-radius: 60rpx;
|
||||
-webkit-transform-origin: 0 0;
|
||||
transform-origin: 0 0;
|
||||
-webkit-transform: scale(0.5);
|
||||
transform: scale(0.5);
|
||||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.amount {
|
||||
text-align: right;
|
||||
color: #686868;
|
||||
font-size: 26rpx;
|
||||
}
|
||||
|
||||
.list-view {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.list-view::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
border-top: 1rpx solid #eaeef1;
|
||||
-webkit-transform: scaleY(0.5);
|
||||
transform: scaleY(0.5);
|
||||
top: 0;
|
||||
right: 0;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.tui-list-item {
|
||||
width: 100%;
|
||||
padding: 30rpx 28rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: #fff;
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.tui-list-item::after {
|
||||
left: 120rpx
|
||||
}
|
||||
|
||||
.item-last::after {
|
||||
left: 0 !important
|
||||
}
|
||||
|
||||
.content-box {
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.logo {
|
||||
width: 60rpx;
|
||||
height: 60rpx;
|
||||
flex-grow: 1
|
||||
}
|
||||
|
||||
.des-box {
|
||||
min-height: 130rpx;
|
||||
padding-left: 28rpx;
|
||||
box-sizing: border-box;
|
||||
vertical-align: top;
|
||||
color: #333;
|
||||
font-size: 24rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.tit {
|
||||
font-size: 28rpx;
|
||||
max-width: 420rpx;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.source {
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
.time {
|
||||
font-size: 24rpx;
|
||||
margin-top: 10rpx;
|
||||
}
|
||||
|
||||
.money {
|
||||
font-size: 30rpx;
|
||||
font-weight: 600;
|
||||
color: #000;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
padding-left: 20rpx;
|
||||
}
|
||||
|
||||
.add {
|
||||
color: #5677FC !important;
|
||||
}
|
||||
|
||||
.add1 {
|
||||
color: #ff0000 !important;
|
||||
}
|
||||
|
||||
.tui-color-primary {
|
||||
color: #5677fc;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user