|
@@ -90,32 +90,46 @@
|
|
|
<view class="info-text" style="color: red;" >
|
|
|
{{chargingRecord.remark}}
|
|
|
</view>
|
|
|
- </view>
|
|
|
-
|
|
|
-
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="info" >
|
|
|
+ <view class="info-name">
|
|
|
+ 优惠券
|
|
|
+ </view>
|
|
|
+ <view class="info-text" style="color:red">
|
|
|
+ {{couponObj&&couponObj.status=='1'?couponObj.text:'未使用'}}
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
|
|
|
+ <view class="info-min" v-if="userCardBool" >
|
|
|
+ <view class="info-name">
|
|
|
+ 会员活动
|
|
|
+ </view>
|
|
|
+ <view class="info-text" v-if="userCard.classify==1">
|
|
|
+ 折扣卡
|
|
|
+ </view>
|
|
|
+ <view class="info-text" v-if="userCard.classify==2">
|
|
|
+ 充电服务费6折卡
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view class="info-min" v-if="userCardBool&&userCard.classify==2" >
|
|
|
+ <view class="info-name">
|
|
|
+
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="info-text-min" >
|
|
|
+ 剩余时长{{thisdaysDistance(userCard.endTime)}}天 | 剩余优惠电量{{(userCard.chargeDegreeLimit-userCard.chargedDegree).toFixed(0)}}度
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
|
|
|
-
|
|
|
+ <view class="bottom">
|
|
|
+ <u-button size="default"
|
|
|
+ shape="circle" @click="gotoMain(0)" >返回首页</u-button>
|
|
|
+ <u-button
|
|
|
+ size="default" shape="circle" @click="gotoMain(1)">查看订单详情</u-button>
|
|
|
+ </view>
|
|
|
|
|
|
- <!--
|
|
|
- <view
|
|
|
|
|
|
- style="
|
|
|
- margin-top: 20px;
|
|
|
- text-align: center;
|
|
|
- padding: 0 45px;
|
|
|
- padding-bottom: 40px;
|
|
|
- color:#9e9e9e;
|
|
|
- ">
|
|
|
- <span style="color: red;">*</span>实际充电金额与所选金额会略有出入,最终结算金额将以实际充入电量为准。
|
|
|
- </view> -->
|
|
|
-
|
|
|
- <view class="bottom">
|
|
|
- <u-button size="default" style="background-color:#53b56b"
|
|
|
- shape="circle" @click="gotoMain(0)" >返回首页</u-button>
|
|
|
- <u-button style="background-color:#53b56b"
|
|
|
- size="default" shape="circle" @click="gotoMain(1)">查看订单详情</u-button>
|
|
|
- </view>
|
|
|
<u-line color="#E6E6E6 100%" length="81%" margin="auto"/>
|
|
|
<!-- 反馈 -->
|
|
|
<view class="feedback">
|
|
@@ -128,24 +142,9 @@
|
|
|
<textarea value="" v-model="message" placeholder="请填写反馈内容" />
|
|
|
<u-button class="submit" type="success" @click="submitMessage()">提交</u-button>
|
|
|
</view>
|
|
|
- <u-line color="#E6E6E6 100%" length="81%" margin="auto"/>
|
|
|
+ <!-- <u-line color="#E6E6E6 100%" length="81%" margin="auto"/>
|
|
|
+ -->
|
|
|
|
|
|
- <view class="info" >
|
|
|
- <view class="info-name">
|
|
|
- 优惠券
|
|
|
- </view>
|
|
|
- <view class="info-text" style="color:red">
|
|
|
- {{couponObj&&couponObj.status=='1'?couponObj.text:'未使用'}}
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="info" v-if="userCardBool" >
|
|
|
- <view class="info-name">
|
|
|
- 会员活动
|
|
|
- </view>
|
|
|
- <view class="info-text">
|
|
|
- 折扣卡
|
|
|
- </view>
|
|
|
- </view>
|
|
|
<u-divider color="#B6BDC3" style="margin-bottom:20px;" bg-color="#ffffff">已经到底了</u-divider>
|
|
|
|
|
|
|
|
@@ -506,8 +505,11 @@
|
|
|
<view class="title">
|
|
|
会员活动
|
|
|
</view>
|
|
|
- <view class="detail">
|
|
|
- 折扣卡
|
|
|
+ <view class="info-text" v-if="userCard.classify==1">
|
|
|
+ 折扣卡
|
|
|
+ </view>
|
|
|
+ <view class="info-text" v-if="userCard.classify==2">
|
|
|
+ 充电服务费6折卡
|
|
|
</view>
|
|
|
|
|
|
</view>
|
|
@@ -622,7 +624,7 @@
|
|
|
import {
|
|
|
newDate,
|
|
|
secondsDistance,
|
|
|
- hourDistanceArr
|
|
|
+ hourDistanceArr,daysDistance
|
|
|
} from '@/utils'
|
|
|
export default {
|
|
|
data() {
|
|
@@ -744,6 +746,13 @@
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
+ thisdaysDistance(endTime){
|
|
|
+
|
|
|
+ var date=new Date()
|
|
|
+ var date2=newDate(endTime);
|
|
|
+ return daysDistance(date,date2)
|
|
|
+
|
|
|
+ },
|
|
|
change(index) {
|
|
|
this.current = index;
|
|
|
this.newsType = this.tabList[index].type;
|
|
@@ -1064,7 +1073,12 @@
|
|
|
setTimeout(()=>{
|
|
|
this.getInfo();
|
|
|
},time)
|
|
|
- }
|
|
|
+ }
|
|
|
+
|
|
|
+ if(this.chargingRecord.status==2&&this.userCardBool){
|
|
|
+ this.getHomePage()
|
|
|
+ }
|
|
|
+
|
|
|
uni.hideLoading()
|
|
|
|
|
|
}).catch(error => {
|
|
@@ -1072,6 +1086,29 @@
|
|
|
title: error
|
|
|
})
|
|
|
})
|
|
|
+ },
|
|
|
+ getHomePage() {
|
|
|
+ uni.showLoading({
|
|
|
+ title: "加载中",
|
|
|
+ mask: true,
|
|
|
+ })
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ API.userCard({
|
|
|
+ stationId:this.chargingGun.stationId
|
|
|
+ }).then((res) => {
|
|
|
+
|
|
|
+ uni.hideLoading()
|
|
|
+ this.userCard=res.data.regUserCard
|
|
|
+ //this.canUse=res.data.canUse
|
|
|
+ //this.user = res.data
|
|
|
+
|
|
|
+ }).catch(error => {
|
|
|
+ uni.showToast({
|
|
|
+ title: error
|
|
|
+ })
|
|
|
+ })
|
|
|
},
|
|
|
submit() {
|
|
|
if(this.chargingRecord.status==0||this.chargingRecord.status==1||this.chargingRecord.status==4){
|
|
@@ -1384,10 +1421,10 @@
|
|
|
justify-content: space-between;
|
|
|
margin: 0 80rpx;
|
|
|
// height: 48px;
|
|
|
- line-height: 88rpx;
|
|
|
+ line-height: 68rpx;
|
|
|
background-color: rgba(255, 255, 255, 100);
|
|
|
color: rgba(16, 16, 16, 100);
|
|
|
- border-bottom: 1px solid #ededed;
|
|
|
+ //border-bottom: 1px solid #ededed;
|
|
|
align-items: center;
|
|
|
.info-text {
|
|
|
|
|
@@ -1396,6 +1433,33 @@
|
|
|
//width: 200px;
|
|
|
text-align: right;
|
|
|
}
|
|
|
+ }
|
|
|
+ .info-min {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ margin: 0 80rpx;
|
|
|
+ // height: 48px;
|
|
|
+ //line-height: 88rpx;
|
|
|
+ background-color: rgba(255, 255, 255, 100);
|
|
|
+ color: rgba(16, 16, 16, 100);
|
|
|
+ //border-bottom: 1px solid #ededed;
|
|
|
+ align-items: center;
|
|
|
+ .info-text {
|
|
|
+
|
|
|
+ line-height: 48rpx;
|
|
|
+ padding: 4rpx 0 4rpx;
|
|
|
+ //width: 200px;
|
|
|
+ text-align: right;
|
|
|
+ }
|
|
|
+ .info-text-min {
|
|
|
+ color: rgba(119, 119, 119, 1);
|
|
|
+ font-size: 24rpx;
|
|
|
+
|
|
|
+ //line-height: 48rpx;
|
|
|
+ padding: 4rpx 0 4rpx;
|
|
|
+ //width: 200px;
|
|
|
+ text-align: right;
|
|
|
+ }
|
|
|
}
|
|
|
.charge-infos{
|
|
|
padding: 20px 36px;
|
|
@@ -1717,7 +1781,7 @@
|
|
|
// 底部按钮
|
|
|
.bottom{
|
|
|
background:white ;
|
|
|
- position: fixed;
|
|
|
+ //position: fixed;
|
|
|
bottom: 0;
|
|
|
left: 0;
|
|
|
right: 0;
|
|
@@ -1740,8 +1804,11 @@
|
|
|
button{
|
|
|
|
|
|
width: 45.8%;
|
|
|
- background-color: black;
|
|
|
- color: #fff;
|
|
|
+ // background-color: black;
|
|
|
+ // color: #fff;
|
|
|
+ background-color: rgba(255, 255, 255, 1);
|
|
|
+ color: rgba(0, 185, 98, 1);
|
|
|
+
|
|
|
height: 80rpx;
|
|
|
border-radius: 50px;
|
|
|
font-size: 32rpx;
|