ssfg 4 năm trước cách đây
mục cha
commit
096d430a06
3 tập tin đã thay đổi với 14 bổ sung5 xóa
  1. 2 1
      app.json
  2. 12 2
      pages/collectInfo/collectInfo.js
  3. 0 2
      pages/visitandinfo/visitandinfo.js

+ 2 - 1
app.json

@@ -1,7 +1,8 @@
 {
   "pages": [
-    "pages/collectInfo/collectInfo",
     "pages/index/index",
+    "pages/collectInfo/collectInfo",
+  
     "pages/visitandinfo/visitandinfo",
     "pages/finishInfo/finishInfo",
     "pages/idCard/idCard",

+ 12 - 2
pages/collectInfo/collectInfo.js

@@ -1808,6 +1808,16 @@ Page({
           checked: true
         })
       })
+    }else{
+      for (var i = 0; i < this.data.oldInfo[this.data.activeIndex].oldType.length; i++) {
+        if (this.data.oldInfo[this.data.activeIndex].oldType[i].name == '失能老人') {
+          this.data.oldInfo[this.data.activeIndex].oldType.splice(i, 1);
+        }
+        this.setData({
+          [Info]:this.data.oldInfo[this.data.activeIndex].oldType
+        })
+        console.log(this.data.oldInfo[this.data.activeIndex].oldType,'------------')
+      }
     }
     this.SubmitOldmanInfo({
       id: this.data.nameArr[this.data.activeIndex]._id,
@@ -2282,7 +2292,7 @@ Page({
     let revise2 = "oldInfo[" + this.data.activeIndex + "].oldType[1].disable";
     let revise3 = "oldInfo[" + this.data.activeIndex + "].oldType[2].disable";
     let revise4 = "oldInfo[" + this.data.activeIndex + "].oldType[3].disable";
-    // let revise5 = "oldInfo[" + this.data.activeIndex + "].oldType[4].checked";
+    let revise5 = "oldInfo[" + this.data.activeIndex + "].oldType[3].checked";
     this.SubmitOldmanInfo({
       id: this.data.nameArr[this.data.activeIndex]._id,
       oldType: JSON.stringify(e.detail.value)
@@ -2320,7 +2330,7 @@ Page({
         [revise2]: true,
         [revise3]: true,
         [revise4]: true,
-        // [revise5]: true
+        [revise5]: true
       })
       return false;
     } else if (index4 >= 0) {

+ 0 - 2
pages/visitandinfo/visitandinfo.js

@@ -103,7 +103,6 @@ Page({
     console.log(e.currentTarget.dataset.infos, "000");
     let photos = e.currentTarget.dataset.infos.visitPhoto.split(",");
     console.log(photos, "打印下锕");
-
     this.setData({
       show: true,
       infos: e.currentTarget.dataset.infos,
@@ -407,5 +406,4 @@ Page({
     }
     this.visitInfo();
   }
-
 })