Browse Source

修复判断车牌

XWookey 1 year ago
parent
commit
9dc00b0458
1 changed files with 5 additions and 1 deletions
  1. 5 1
      pages/scan_result/scan_result.js

+ 5 - 1
pages/scan_result/scan_result.js

@@ -274,6 +274,10 @@ Page({
     let userInfo = wx.getStorageSync('userInfo');
     let isLogin = wx.getStorageSync('isLogin');
     let that = this
+    if(!that.data.carParkingRate){
+      that.beginChargeInner(that);
+      return;
+    }
     // 读取默认车牌
 		wx.request({
 		  url: getApp().globalData.postHeadAgreement + '/restapi/wechat/carList?loginName=' + userInfo.loginName,
@@ -285,7 +289,7 @@ Page({
         let userCarList = res.data;
         userCarList = userCarList.filter(it=>it.defaultType==1);
         console.info(userCarList)
-        if(userCarList.length==0){
+        if(userCarList.length==0 ){
           wx.showModal({
             title: '提示',
             content: '当前充电站可减免停车费,是否绑定车牌信息?',