|
@@ -48,7 +48,7 @@
|
|
|
预计充电时长
|
|
|
</view>
|
|
|
<view class="item-content">
|
|
|
- {{detail.estimateMinutes}}分钟
|
|
|
+ {{getPercent(detail.estimateMinutes)}}
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -185,16 +185,30 @@
|
|
|
//扫码进入的
|
|
|
}
|
|
|
if (op.deviceNo) {
|
|
|
- this.stationId= op.stationId;
|
|
|
- this.deviceNo = op.deviceNo;
|
|
|
- this.channelNo = op.gun;
|
|
|
- this.carNumber = op.carNumber;
|
|
|
-
|
|
|
+
|
|
|
}
|
|
|
this.id= op.id;
|
|
|
this.getInfo()
|
|
|
},
|
|
|
methods:{
|
|
|
+ getPercent(estimateMinute) {
|
|
|
+ var value="";
|
|
|
+
|
|
|
+ var ms =estimateMinute
|
|
|
+ if (ms > 0) {
|
|
|
+ var Hour = parseInt(Math.floor(ms / 60 ));
|
|
|
+ var Fen = parseInt(Math.floor(ms % 60 ));
|
|
|
+ if(Hour>0){
|
|
|
+ value+=Hour + "小时"
|
|
|
+ }
|
|
|
+ if(Fen>0){
|
|
|
+ value+=Fen + "分钟"
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ return value;
|
|
|
+ },
|
|
|
charge(){
|
|
|
uni.navigateTo({
|
|
|
url:'/pages/searchPile/chargeProcess/charge?stationId='+this.stationId+'&deviceNo='+this.deviceNo+"&gun="+this.channelNo+"&carNumber="+(this.carNumber?this.carNumber:'')
|
|
@@ -256,6 +270,13 @@
|
|
|
this.chargingDevice=res.data.chargingDevice;
|
|
|
this.price=res.data.price;
|
|
|
|
|
|
+
|
|
|
+ this.stationId= this.chargingDevice.stationId;
|
|
|
+ this.deviceNo = this.chargingDevice.deviceNo;
|
|
|
+ this.channelNo = res.data.channelNo;
|
|
|
+ this.carNumber = res.data.carNumber;
|
|
|
+
|
|
|
+
|
|
|
if(this.detail.status=="0"){
|
|
|
//this.description= '等待桩主确认预约单,剩余时间'
|
|
|
var data=new Date(this.detail.createTime).getTime()
|