xuqiang 4 سال پیش
والد
کامیت
f75b51aa19
4فایلهای تغییر یافته به همراه18 افزوده شده و 1 حذف شده
  1. 7 0
      project.config.json
  2. 7 0
      project.private.config.json
  3. 2 1
      src/pages/feeDetail.vue
  4. 2 0
      src/pages/personDetail.vue

+ 7 - 0
project.config.json

@@ -84,6 +84,13 @@
                     "query": "",
                     "query": "",
                     "scene": null
                     "scene": null
                 },
                 },
+                {
+                    "id": -1,
+                    "name": "房间余额",
+                    "pathName": "/pages/feeDetail",
+                    "query": "",
+                    "scene": null
+                },
                 {
                 {
                     "id": -1,
                     "id": -1,
                     "name": "入住须知",
                     "name": "入住须知",

+ 7 - 0
project.private.config.json

@@ -26,6 +26,13 @@
                     "query": "",
                     "query": "",
                     "scene": null
                     "scene": null
                 },
                 },
+                {
+                    "id": -1,
+                    "name": "房间余额",
+                    "pathName": "/pages/feeDetail",
+                    "query": "",
+                    "scene": null
+                },
                 {
                 {
                     "id": -1,
                     "id": -1,
                     "name": "入住须知",
                     "name": "入住须知",

+ 2 - 1
src/pages/feeDetail.vue

@@ -99,7 +99,6 @@ export default {
                 .get('/api/mp/roomFeeRecord', query)
                 .get('/api/mp/roomFeeRecord', query)
                 .then(res => {
                 .then(res => {
                     wx.hideLoading();
                     wx.hideLoading();
-                    console.log(res);
                     this.list = res.content;
                     this.list = res.content;
                     this.empty = res.empty;
                     this.empty = res.empty;
                     let countArr = this.list.filter(item => {
                     let countArr = this.list.filter(item => {
@@ -109,6 +108,8 @@ export default {
                         this.count = countArr.reduce((total, item) => {
                         this.count = countArr.reduce((total, item) => {
                             return total + item.money;
                             return total + item.money;
                         }, 0);
                         }, 0);
+                    } else {
+                        this.count = 0;
                     }
                     }
                 })
                 })
                 .catch(e => {
                 .catch(e => {

+ 2 - 0
src/pages/personDetail.vue

@@ -104,6 +104,8 @@ export default {
                         this.count = countArr.reduce((total, item) => {
                         this.count = countArr.reduce((total, item) => {
                             return total + item.amount;
                             return total + item.amount;
                         }, 0);
                         }, 0);
+                    } else {
+                        this.count = 0;
                     }
                     }
                     this.empty = res.empty;
                     this.empty = res.empty;
                 })
                 })