Merge remote-tracking branch 'origin/dev' into dev

This commit is contained in:
2023-10-27 11:17:15 +08:00
commit c75b85447c
3 changed files with 17 additions and 15 deletions

View File

@ -37,12 +37,12 @@ export function registerdata(data) {
})
}
// 获取当前注册居民
export function getCurrentUser(openid) {
export function getCurrentUser(openid, cityCode) {
return request({
url: `/applet/register/getList/${openid}`,
url: `/applet/register/getCurrentResident/${openid}/${cityCode}`,
method: 'GET',
header: {
// Authorization: 'Bearer' + ' ' + uni.getStorageSync('token')
Authorization: 'Bearer' + ' ' + uni.getStorageSync('token')
},
})
}

View File

@ -17,14 +17,14 @@
<span class="name" v-else>
请先登录!
</span>
<view class="" v-if="appPersonallist.patientName">
<view class="signing" v-if="appPersonallist.signNo">
<span class="" v-if="appPersonallist.patientName">
<span class="signing" v-if="appPersonallist.signNo">
已签约
</view>
<view class="signing" v-else>
</span>
<span class="signing" v-else>
未签约
</view>
</view>
</span>
</span>
</view>
<view class="phone" v-if="appPersonallist.phone">
{{appPersonallist.phone}}
@ -211,13 +211,12 @@
familyList: {}, //
userinfo: {}, //
valueopenid: '',
cityCode:'',
};
},
onShow() {
// this.bjimg = baseurl + '/profile/appletPicture/inviteFriendsOne.png'
let that = this
that.userinfo = uni.getStorageSync('userinfo')
@ -225,6 +224,7 @@
that.baseurl = baseurl
const value = uni.getStorageSync('patientId');
this.valueopenid = uni.getStorageSync('openid');
this.cityCode=uni.getStorageSync('region');
if (value) {
that.myInfo()
} else {
@ -268,7 +268,7 @@
},
//
getpersnoal() {
getCurrentUser(this.valueopenid).then(res => {
getCurrentUser(this.valueopenid,this.cityCode).then(res => {
console.log(res)
this.familyList = res.data
@ -538,4 +538,4 @@
<style lang="scss">
@import './myinformation.scss'
</style>
</style>

View File

@ -285,7 +285,7 @@
sex: '',
sexname: '',
birthDate: '',
cityCode: '1',
cityCode: '',
householdCardNo:'',
householdRelationship:'',
},
@ -374,6 +374,8 @@
console.log(this.query)
var that = this
that.query.openid = uni.getStorageSync('openid');
that.query.cityCode = uni.getStorageSync('region');
if (that.query.sexname == '男') {
that.query.sex = 'MALE';
} else if (that.query.sexname == '女') {
@ -407,7 +409,7 @@
} else {
registerdata(that.query).then(res => {
if (res.code == 200) {
getCurrentUser(that.query.openid, '1').then(res => {
getCurrentUser(that.query.openid,that.query.cityCode).then(res => {
uni.setStorageSync('patientId', res.data.id);
uni.setStorageSync('patientName', res.data.patientName);
uni.setStorageSync("userinfo", res.data)