From f7cf50c8ea5d3df651e2bdedc47b8e577c7a6adb Mon Sep 17 00:00:00 2001 From: wuxw <928255095@qq.com> Date: Thu, 12 Sep 2024 23:11:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/my/my-person.vue | 14 ++++++------- pages/family/family.vue | 40 ++++++++++++++++--------------------- pages/family/familyList.vue | 6 +++--- 3 files changed, 26 insertions(+), 34 deletions(-) diff --git a/components/my/my-person.vue b/components/my/my-person.vue index 1e81fdb..f8a0e27 100644 --- a/components/my/my-person.vue +++ b/components/my/my-person.vue @@ -118,12 +118,10 @@ }, loadOwenrInfo: function() { let _that = this; - context.getOwner(function(_ownerInfo) { - if (_ownerInfo) { - _that.ownerFlag = true; - } else { - _that.ownerFlag = false; - } + hasAuthOwner(this).then(_owner => { + _that.ownerFlag = true; + },()=>{ + _that.ownerFlag = false; }); }, /** @@ -137,8 +135,8 @@ communityId:getCommunityId() }).then(_data=>{ //console.log(_data); - if(_data.url){ - _that.headerImg = _data.url; + if(_data.faceUrl){ + _that.headerImg = _data.faceUrl; }else{ _that.headerImg =conf.imgUrl+'/h5/images/serve/head.png'; } diff --git a/pages/family/family.vue b/pages/family/family.vue index e2b4a7e..9e3d432 100644 --- a/pages/family/family.vue +++ b/pages/family/family.vue @@ -18,11 +18,7 @@ - 年龄 - - - - 人员类型 + 人员角色 {{typeCds[typeCdIndex].name}} @@ -30,8 +26,8 @@ - 家庭住址 - + 地址 + 联系信息 @@ -39,11 +35,6 @@ 手机号 - 相关图片 @@ -81,22 +72,26 @@ "userId": "", "typeCds": [ { - value: '1002', + value: '3', name: '家庭成员' }, { - value: '1003', + value: '2', name: '租客' }, { - value: '1005', + value: '4', + name: '公司员工' + }, + { + value: '99', name: '其他' } ], "typeCdIndex": 0, + "personRole":'3', "ownerTypeCd": "1002", "idCard": "", - "age": "", "memberId": "-1", "communityId": "", "second": 60, @@ -104,7 +99,7 @@ "btnValue": "验证码", "msgCode":'', "address": "", - photos:[], + photos:'', uploadImage: { maxPhotoNum: 1, imgTitle: '图片上传', @@ -134,7 +129,7 @@ onPullDownRefresh: function() {}, methods: { sendImagesData: function(e){ - this.photos = e[0].fileId + this.photos = e[0].url; }, submitOwnerMember: function(e) { let obj = { @@ -149,9 +144,10 @@ "memberId": this.memberId, "communityId": this.communityId, "idCard": this.idCard, - //"msgCode":this.msgCode, + "personRole":this.personRole, + "personType":'P', "address": this.address, - "ownerPhoto": this.photos + "ownerPhotoUrl": this.photos } let msg = ""; @@ -159,8 +155,6 @@ msg = "请填写业主"; } else if (obj.name == "") { msg = "请填写姓名"; - }else if (obj.age == "") { - msg = "请填写年龄"; } else if (obj.link == "") { msg = "请填写手机号"; } else if (!checkPhoneNumber(obj.link)){ @@ -212,7 +206,7 @@ }, _changeTypeCd: function(e){ this.typeCdIndex = e.detail.value; - this.ownerTypeCd = this.typeCds[this.typeCdIndex].value; + this.personRole = this.typeCds[this.typeCdIndex].value; }, idCardChange: function(){ let idCard = this.idCard; diff --git a/pages/family/familyList.vue b/pages/family/familyList.vue index 0a58dba..6539fbd 100644 --- a/pages/family/familyList.vue +++ b/pages/family/familyList.vue @@ -118,9 +118,9 @@ method: "GET", data: _paramIn, success: function(res) { - if (res.statusCode == 200) { - let _owners = res.data.owners; - that.owners = _owners; + let _json = res.data; + if (_json.code == 0) { + that.owners = _json.data; that.loading = false; } },