Browse Source

水电费合并

程志平 4 years ago
parent
commit
efb17011e7
4 changed files with 15 additions and 5 deletions
  1. 2 1
      manifest.json
  2. 2 2
      pages.json
  3. 2 2
      pages/jiaofei/jiaofei.vue
  4. 9 0
      pages/show/show.vue

+ 2 - 1
manifest.json

@@ -74,7 +74,8 @@
             "scope.userLocation" : {
             "scope.userLocation" : {
                 "desc" : "您的位置信息将用于连接热水表蓝牙"
                 "desc" : "您的位置信息将用于连接热水表蓝牙"
             }
             }
-        }
+        },
+		"lazyCodeLoading": "requiredComponents"
     },
     },
     "mp-alipay" : {
     "mp-alipay" : {
         "usingComponents" : true
         "usingComponents" : true

+ 2 - 2
pages.json

@@ -31,7 +31,7 @@
 		{
 		{
 			"path": "pages/jiaofei/jiaofei",
 			"path": "pages/jiaofei/jiaofei",
 			"style": {
 			"style": {
-				"navigationBarTitleText": "电充值",
+				"navigationBarTitleText": "电充值",
 				"enablePullDownRefresh": false
 				"enablePullDownRefresh": false
 			}
 			}
 		},
 		},
@@ -53,7 +53,7 @@
 		{
 		{
 			"path": "pages/select/select",
 			"path": "pages/select/select",
 			"style": {
 			"style": {
-				"navigationBarTitleText": "缴电费",
+				"navigationBarTitleText": "缴电费",
 				"enablePullDownRefresh": false
 				"enablePullDownRefresh": false
 			}
 			}
 
 

+ 2 - 2
pages/jiaofei/jiaofei.vue

@@ -14,8 +14,8 @@
 			<view class="picker-item-logol">
 			<view class="picker-item-logol">
 				<image class="picker-item-logo-left" src="/static/image/elec.png"></image>
 				<image class="picker-item-logo-left" src="/static/image/elec.png"></image>
 			</view>
 			</view>
-			<view class="picker-item-label">剩余电量</view>
-			<view class="picker-item-content font-txt">{{remainElec}}</view>
+			<view class="picker-item-label">剩余额度</view>
+			<view class="picker-item-content font-txt">¥ {{remainElec}}</view>
 		</view>
 		</view>
 		<view class="show-item add-money">
 		<view class="show-item add-money">
 			<view class="add-money-show">
 			<view class="add-money-show">

+ 9 - 0
pages/show/show.vue

@@ -211,10 +211,19 @@
 						})
 						})
 
 
 						// console.log(res.data.data);
 						// console.log(res.data.data);
+						// console.log(res.data);
 						if (res.data.code != 200) {
 						if (res.data.code != 200) {
 							return
 							return
 						}
 						}
 
 
+						if (typeof res.data.data === 'undefined') {
+							uni.showToast({
+								title: '加载数据异常',
+								duration: 1500
+							})
+							return
+						}
+
 						let chrt_data = {
 						let chrt_data = {
 							categories: [],
 							categories: [],
 							series: [{
 							series: [{