346 lines
7.5 KiB
Vue
346 lines
7.5 KiB
Vue
<template>
|
||
<view class="page">
|
||
<u-navbar title="门面收益" :border-bottom="false" :background="bgc" title-color='#000' title-size='36'
|
||
height='58'></u-navbar>
|
||
<view class="box">
|
||
<view class="top">
|
||
<u-search placeholder="搜索" input-align="center" v-model="keyword"></u-search>
|
||
</view>
|
||
<u-picker mode="time" v-model="show" :params="params" @confirm="confirm"></u-picker>
|
||
<view class="date">
|
||
<text @click="btnks(1)">{{selector}}</text> -- <text @click="btnks(2)">{{selectors}}</text>
|
||
</view>
|
||
<view class="jesx">
|
||
<view class="sx">金额筛选:</view><text
|
||
@click="btnaddid(1)">{{qishiprice == '起始金额' ? qishiprice : qishiprice + '元'}} </text>
|
||
--
|
||
<text @click="btnaddid(2)">{{jieshuprice == '结束金额' ? jieshuprice : jieshuprice + '元'}} </text>
|
||
<view class="cx">查询</view>
|
||
</view>
|
||
|
||
|
||
<!-- 店铺排行 -->
|
||
<view class="shoppm">
|
||
<view class="shopname">
|
||
<view class="one">店铺名称</view>
|
||
<view class="two">¥收益金额(元)
|
||
<image src="https://api.ccttiot.com/smartmeter/img/static/usFoZqC3MrePH4pqCJe7" mode="" style="display: inline-block;width: 46rpx;height: 46rpx;vertical-align: middle;"></image> </view>
|
||
</view>
|
||
<view class="listshop" v-for="(item,index) in 11" :key="index">
|
||
<view class="nikename">
|
||
<text :style="{
|
||
width: '38rpx',
|
||
height: '38rpx',
|
||
background: '#ccc',
|
||
display: 'inline-block',
|
||
borderRadius: '50%',
|
||
textAlign: 'center',
|
||
marginRight: '14rpx',
|
||
fontSize: '24rpx',
|
||
lineHeight: '38rpx',
|
||
color: getColorByIndex(index)}">
|
||
{{index + 1}}</text>
|
||
福鼎力创台球电玩
|
||
</view>
|
||
<view class="price">996</view>
|
||
</view>
|
||
</view>
|
||
|
||
</view>
|
||
|
||
|
||
|
||
|
||
|
||
|
||
<!-- 弹窗 -->
|
||
<view class="tanc" v-if="vipflag">
|
||
<view class="tit">{{textje}}</view>
|
||
<input type="text" v-model="jesum" />
|
||
<view class="xian"></view>
|
||
<view class="anniu">
|
||
<text @click="btnqx">取消</text> <text style="border-left: 1px solid #D8D8D8;color: #25CE88;"
|
||
@click="trueje">确定</text>
|
||
</view>
|
||
</view>
|
||
<view class="mask" v-if="vipflag"></view>
|
||
|
||
</view>
|
||
</template>
|
||
|
||
<script>
|
||
export default {
|
||
data() {
|
||
return {
|
||
params: {
|
||
year: true,
|
||
month: true,
|
||
day: true,
|
||
hour: false,
|
||
minute: false,
|
||
second: false
|
||
},
|
||
show: false,
|
||
selector: '2024-4-9',
|
||
selectors: '2024-4-9',
|
||
num: '',
|
||
vipflag: false,
|
||
textje: '请输入起始金额',
|
||
qishiprice: '起始金额',
|
||
jieshuprice: '结束金额',
|
||
jesum: 0,
|
||
jeflag: ''
|
||
}
|
||
},
|
||
methods: {
|
||
btnks(num) {
|
||
this.show = true
|
||
if (num == 1) {
|
||
this.num = 1
|
||
} else {
|
||
this.num = 2
|
||
}
|
||
},
|
||
confirm(e) {
|
||
if (this.num == 1) {
|
||
this.selector = e.year + '-' + e.month + '-' + e.day
|
||
} else {
|
||
this.selectors = e.year + '-' + e.month + '-' + e.day
|
||
}
|
||
},
|
||
btnaddid(num) {
|
||
this.vipflag = true
|
||
if (num == 1) {
|
||
this.textje = '请输入起始金额'
|
||
this.jeflag = true
|
||
} else {
|
||
this.textje = '请输入结束金额'
|
||
this.jeflag = false
|
||
}
|
||
},
|
||
btnqx() {
|
||
this.vipflag = false
|
||
},
|
||
trueje() {
|
||
this.vipflag = false
|
||
// 为true是起始金额 为false是结束金额
|
||
if (this.jeflag == true) {
|
||
this.qishiprice = this.jesum
|
||
this.jesum = 0
|
||
} else {
|
||
this.jieshuprice = this.jesum
|
||
this.jesum = 0
|
||
}
|
||
},
|
||
|
||
getColorByIndex(index) {
|
||
const colors = ['red', 'orange', 'green', 'black']; // 颜色数组
|
||
return index < colors.length ? colors[index] : colors[3]; // 如果index小于颜色数组长度,返回对应颜色;否则返回黑色
|
||
}
|
||
|
||
}
|
||
}
|
||
</script>
|
||
|
||
<style lang="scss">
|
||
/deep/ .u-title,
|
||
/deep/ .uicon-nav-back {
|
||
padding-bottom: 40rpx;
|
||
}
|
||
page {
|
||
background: linear-gradient(180deg, #25CE88 0%, rgba(255, 255, 255, 0) 100%);
|
||
}
|
||
|
||
.page {
|
||
width: 750rpx;
|
||
position: fixed;
|
||
top: 0;
|
||
left: 0;
|
||
|
||
.mask {
|
||
width: 750rpx;
|
||
height: 100vh;
|
||
background: #000000;
|
||
border-radius: 0rpx 0rpx 0rpx 0rpx;
|
||
opacity: 0.2;
|
||
z-index: 1;
|
||
position: fixed;
|
||
top: 0;
|
||
left: 0;
|
||
}
|
||
|
||
.box {
|
||
width: 750rpx;
|
||
height: 1440rpx;
|
||
background: #F4F5F7;
|
||
border-radius: 0rpx 0rpx 0rpx 0rpx;
|
||
|
||
.shoppm {
|
||
.listshop {
|
||
padding: 24rpx 48rpx;
|
||
box-sizing: border-box;
|
||
display: flex;
|
||
justify-content: space-between;
|
||
border-bottom: 1rpx solid #F0F0F0;
|
||
font-size: 28rpx;
|
||
color: #3D3D3D;
|
||
|
||
.nikename {}
|
||
}
|
||
|
||
.shopname {
|
||
display: flex;
|
||
justify-content: space-between;
|
||
padding: 0rpx 48rpx;
|
||
box-sizing: border-box;
|
||
margin-top: 60rpx;
|
||
border-bottom: 1rpx solid #F0F0F0;
|
||
padding-bottom: 24rpx;
|
||
|
||
.one {
|
||
font-size: 28rpx;
|
||
color: #808080;
|
||
}
|
||
|
||
.two {
|
||
font-weight: 600;
|
||
font-size: 28rpx;
|
||
color: #3D3D3D;
|
||
}
|
||
}
|
||
}
|
||
|
||
.jesx {
|
||
display: flex;
|
||
justify-content: space-between;
|
||
margin-top: 32rpx;
|
||
padding: 0 22rpx;
|
||
box-sizing: border-box;
|
||
|
||
text {
|
||
padding: 6rpx 18rpx;
|
||
box-sizing: border-box;
|
||
background: #eee;
|
||
border-radius: 10rpx 10rpx 10rpx 10rpx;
|
||
font-size: 24rpx;
|
||
color: #808080;
|
||
}
|
||
|
||
.sx {
|
||
font-size: 24rpx;
|
||
color: #3D3D3D;
|
||
width: 120rpx;
|
||
margin-top: 6rpx;
|
||
}
|
||
|
||
.cx {
|
||
width: 100rpx;
|
||
margin-right: 20rpx;
|
||
text-align: center;
|
||
font-size: 24rpx;
|
||
color: #FFFFFF;
|
||
height: 46rpx;
|
||
line-height: 46rpx;
|
||
background: #25CE88;
|
||
border-radius: 10rpx 10rpx 10rpx 10rpx;
|
||
}
|
||
}
|
||
|
||
.date {
|
||
padding-left: 80rpx;
|
||
padding-right: 80rpx;
|
||
box-sizing: border-box;
|
||
display: flex;
|
||
justify-content: space-between;
|
||
margin-top: 26rpx;
|
||
|
||
text {
|
||
padding: 6rpx 18rpx;
|
||
box-sizing: border-box;
|
||
background: #eee;
|
||
border-radius: 10rpx 10rpx 10rpx 10rpx;
|
||
font-size: 24rpx;
|
||
color: #808080;
|
||
}
|
||
}
|
||
|
||
.top {
|
||
padding: 28rpx 32rpx;
|
||
box-sizing: border-box;
|
||
|
||
/deep/ .u-content {
|
||
border: 1px solid #ccc;
|
||
border-radius: 50rpx 0 0 50rpx !important;
|
||
}
|
||
|
||
/deep/ .u-action {
|
||
border-radius: 0 50rpx 50rpx 0 !important;
|
||
width: 112rpx;
|
||
height: 65rpx;
|
||
line-height: 65rpx;
|
||
border: 2rpx solid #ccc;
|
||
margin-left: 0;
|
||
color: #3D3D3D;
|
||
background-color: #f2f2f2;
|
||
}
|
||
}
|
||
}
|
||
|
||
.tanc {
|
||
width: 610rpx;
|
||
height: 282rpx;
|
||
background: #FFFFFF;
|
||
border-radius: 30rpx 30rpx 30rpx 30rpx;
|
||
position: fixed;
|
||
top: 628rpx;
|
||
left: 50%;
|
||
transform: translateX(-50%);
|
||
z-index: 2;
|
||
|
||
.tit {
|
||
width: 100%;
|
||
text-align: center;
|
||
margin-top: 28rpx;
|
||
font-weight: 500;
|
||
font-size: 32rpx;
|
||
color: #3D3D3D;
|
||
}
|
||
|
||
input {
|
||
width: 504rpx;
|
||
height: 62rpx;
|
||
background: #EEEEEE;
|
||
border-radius: 6rpx 6rpx 6rpx 6rpx;
|
||
margin: auto;
|
||
margin-top: 22rpx;
|
||
padding-left: 20rpx;
|
||
}
|
||
|
||
.xian {
|
||
width: 610rpx;
|
||
height: 2rpx;
|
||
background: #D8D8D8;
|
||
border-radius: 0rpx 0rpx 0rpx 0rpx;
|
||
margin-top: 26rpx;
|
||
}
|
||
|
||
.anniu {
|
||
display: flex;
|
||
justify-content: space-between;
|
||
height: 98rpx;
|
||
|
||
text {
|
||
padding: 24rpx;
|
||
text-align: center;
|
||
box-sizing: border-box;
|
||
font-weight: 500;
|
||
font-size: 36rpx;
|
||
color: #3D3D3D;
|
||
display: inline-block;
|
||
width: 100%;
|
||
height: 100rpx;
|
||
}
|
||
}
|
||
}
|
||
}
|
||
</style> |