|
|
@@ -12,31 +12,39 @@
|
|
|
</config>
|
|
|
<template>
|
|
|
<div class="list">
|
|
|
- <van-empty
|
|
|
- v-if="empty"
|
|
|
- image="https://ticket-exchange.oss-cn-hangzhou.aliyuncs.com/wechat/kong_png_wodeguanzhu.png"
|
|
|
- description="暂无收益记录哦"
|
|
|
- >
|
|
|
- </van-empty>
|
|
|
- <van-sticky :offset-top="0">
|
|
|
+ <!-- <van-sticky :offset-top="0">
|
|
|
<div class="time-box">
|
|
|
<van-dropdown-menu>
|
|
|
<van-dropdown-item @change="record" :value="time" :options="option1" />
|
|
|
</van-dropdown-menu>
|
|
|
</div>
|
|
|
- </van-sticky>
|
|
|
+ </van-sticky> -->
|
|
|
<template>
|
|
|
- <div v-for="(item, index) in recordList" :key="index">
|
|
|
- <bill-info :Info="item" v-if="item.type == 'SOLD'"></bill-info>
|
|
|
+ <div class="content" v-if="ammeterInfo">
|
|
|
+ <div class="con1">
|
|
|
+ <img class="con-img" src="../native/icon-shuifei@3x (2).png" alt="" />
|
|
|
+ <div>
|
|
|
+ <div class="text1">电费</div>
|
|
|
+ <div class="text2" v-if="roomInfo.ammeterType && roomInfo.ammeterId">
|
|
|
+ 剩余电量{{ ammeterInfo.rest }}度
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="money">{{ ammeterInfo.amount > 0 ? '+' : '' }}{{ ammeterInfo.amount }}</div>
|
|
|
</div>
|
|
|
+ <van-empty
|
|
|
+ v-else
|
|
|
+ image="https://ticket-exchange.oss-cn-hangzhou.aliyuncs.com/wechat/kong_png_wodeguanzhu.png"
|
|
|
+ description="暂无记录哦"
|
|
|
+ >
|
|
|
+ </van-empty>
|
|
|
</template>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import BillInfo from '../components/BillInfo.vue';
|
|
|
+import { mapState } from 'vuex';
|
|
|
export default {
|
|
|
- components: { BillInfo },
|
|
|
name: 'Wallet',
|
|
|
data() {
|
|
|
return {
|
|
|
@@ -57,18 +65,18 @@ export default {
|
|
|
{ text: '2021-11', value: 6 },
|
|
|
{ text: '2021-12', value: 7 }
|
|
|
],
|
|
|
- empty: false,
|
|
|
- recordList: {},
|
|
|
- count: 0,
|
|
|
- TXCount: 0
|
|
|
+ empty: false
|
|
|
};
|
|
|
},
|
|
|
computed: {
|
|
|
canSubmit() {
|
|
|
return this.flag;
|
|
|
- }
|
|
|
+ },
|
|
|
+ ...mapState(['roomInfo', 'ammeterInfo'])
|
|
|
+ },
|
|
|
+ created() {
|
|
|
+ console.log(this.roomInfo, this.ammeterInfo);
|
|
|
},
|
|
|
- created() {},
|
|
|
methods: {}
|
|
|
};
|
|
|
</script>
|
|
|
@@ -100,7 +108,42 @@ export default {
|
|
|
align-self: flex-end;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
+.content {
|
|
|
+ width: 100%;
|
|
|
+ .flex();
|
|
|
+ justify-content: space-between;
|
|
|
+ padding: 16px 20px;
|
|
|
+ border-bottom: 1px solid #f5f7fa;
|
|
|
+ .con1 {
|
|
|
+ .flex();
|
|
|
+ .con-img {
|
|
|
+ width: 36px;
|
|
|
+ height: 36px;
|
|
|
+ margin-right: 10px;
|
|
|
+ }
|
|
|
+ .text1 {
|
|
|
+ font-size: 14px;
|
|
|
+ font-family: PingFangSC-Regular, PingFang SC;
|
|
|
+ font-weight: normal;
|
|
|
+ color: #000000;
|
|
|
+ line-height: 20px;
|
|
|
+ }
|
|
|
+ .text2 {
|
|
|
+ font-size: 13px;
|
|
|
+ font-family: PingFangSC-Regular, PingFang SC;
|
|
|
+ font-weight: normal;
|
|
|
+ color: #aaacad;
|
|
|
+ line-height: 18px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .money {
|
|
|
+ font-size: 16px;
|
|
|
+ font-family: PingFangSC-Semibold, PingFang SC;
|
|
|
+ font-weight: bold;
|
|
|
+ color: #000000;
|
|
|
+ line-height: 24px;
|
|
|
+ }
|
|
|
+}
|
|
|
.time-box {
|
|
|
.flex();
|
|
|
background-color: @bg;
|