修改
This commit is contained in:
parent
caeaa309c6
commit
63905fba41
@ -248,7 +248,7 @@
|
||||
}, {
|
||||
value: '3',
|
||||
label: '高血脂'
|
||||
},],
|
||||
}, ],
|
||||
arealist: [], //区街道list
|
||||
list: [{
|
||||
id: "",
|
||||
@ -362,10 +362,7 @@
|
||||
console.log(e, '打印e')
|
||||
},
|
||||
submit() {
|
||||
|
||||
var that = this
|
||||
// console.log(that.query)
|
||||
// console.log(that.query.diseaseList.length,'000')
|
||||
that.query.openid = uni.getStorageSync('openid');
|
||||
that.query.cityCode = uni.getStorageSync('region');
|
||||
if (that.query.sexname == '男') {
|
||||
@ -373,59 +370,54 @@
|
||||
} else if (that.query.sexname == '女') {
|
||||
that.query.sex = 'FEMALE';
|
||||
}
|
||||
if (that.selected == 1) {
|
||||
that.$refs.uToast.show({
|
||||
title: '请审核并同意用户协议',
|
||||
type: 'error'
|
||||
})
|
||||
return
|
||||
} else if (that.query.sex == "") {
|
||||
that.$refs.uToast.show({
|
||||
title: '请选择性别',
|
||||
type: 'error'
|
||||
})
|
||||
return
|
||||
} else if (!that.query.locationName) {
|
||||
that.$refs.uToast.show({
|
||||
title: '请选择所在位置',
|
||||
type: 'error'
|
||||
})
|
||||
return
|
||||
} else if (!that.query.birthDate) {
|
||||
that.$refs.uToast.show({
|
||||
title: '请选择出生日期',
|
||||
type: 'error'
|
||||
})
|
||||
return
|
||||
}
|
||||
that.$refs.uForm.validate(valid => {
|
||||
if (valid) {
|
||||
|
||||
if (that.selected == 1) {
|
||||
that.$refs.uToast.show({
|
||||
title: '请审核并同意用户协议',
|
||||
type: 'error'
|
||||
})
|
||||
} else if (that.query.sex == "") {
|
||||
that.$refs.uToast.show({
|
||||
title: '请选择性别',
|
||||
type: 'error'
|
||||
})
|
||||
} else if (!that.query.locationName) {
|
||||
that.$refs.uToast.show({
|
||||
title: '请选择所在位置',
|
||||
type: 'error'
|
||||
})
|
||||
} else if (!that.query.birthDate) {
|
||||
that.$refs.uToast.show({
|
||||
title: '请选择出生日期',
|
||||
type: 'error'
|
||||
})
|
||||
}
|
||||
// else if (that.query.diseaseList.length == 0) {
|
||||
// that.$refs.uToast.show({
|
||||
// title: '请选择基础疾病',
|
||||
// type: 'error'
|
||||
// })
|
||||
// }
|
||||
else {
|
||||
registerdata(that.query).then(res => {
|
||||
if (res.code == 200) {
|
||||
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)
|
||||
that.$refs.uToast.show({
|
||||
title: '注册成功',
|
||||
type: 'success',
|
||||
duration: '1000',
|
||||
back: 1,
|
||||
})
|
||||
})
|
||||
} else {
|
||||
registerdata(that.query).then(res => {
|
||||
if (res.code == 200) {
|
||||
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)
|
||||
that.$refs.uToast.show({
|
||||
title: res.msg,
|
||||
type: 'error',
|
||||
title: '注册成功',
|
||||
type: 'success',
|
||||
duration: '1000',
|
||||
back: 1,
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
} else {}
|
||||
})
|
||||
} else {
|
||||
that.$refs.uToast.show({
|
||||
title: res.msg,
|
||||
type: 'error',
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
});
|
||||
},
|
||||
//切换
|
||||
@ -574,9 +566,10 @@
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
background: #fff;
|
||||
::v-deep .select-modal .select-dialog{
|
||||
height: 370rpx !important;
|
||||
|
||||
|
||||
::v-deep .select-modal .select-dialog {
|
||||
height: 370rpx !important;
|
||||
|
||||
}
|
||||
|
||||
.Agreement {
|
||||
@ -909,4 +902,4 @@
|
||||
/deep/ .u-form-item__message {
|
||||
padding-left: 0 !important;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
@ -77,20 +77,12 @@
|
||||
methods: {
|
||||
info() {
|
||||
this.region = uni.getStorageSync('region')
|
||||
console.log(this.region, '859')
|
||||
if (this.region == 3) {
|
||||
this.$refs.uToast.show({
|
||||
title: '当前地区不支持,请重新选择区域',
|
||||
type: 'error',
|
||||
duration: '2000',
|
||||
// url:'/pages/homepage/homepage'
|
||||
})
|
||||
uni.navigateTo({
|
||||
'/pages/homepage/homepage'
|
||||
})
|
||||
// uni.navigateBack({
|
||||
// delta: 1
|
||||
// })
|
||||
}
|
||||
},
|
||||
//人员
|
||||
|
||||
@ -77,7 +77,7 @@
|
||||
已签到
|
||||
</view>
|
||||
</view>
|
||||
<!-- <view class="item" style="background-color: #F44B2F;">
|
||||
<!-- <view class="item" style="background-color: #F44B2F;">
|
||||
<image src="../../static/pagesB/yaoqing.png" mode=""></image>
|
||||
<view class="titletext">
|
||||
每邀请
|
||||
@ -290,6 +290,18 @@
|
||||
that.updata.phone = res.data[0].receivePhone
|
||||
that.userid = res.data[0].id
|
||||
}
|
||||
let useritem = null
|
||||
uni.$on('updata', function(data) {
|
||||
if (data.useritem) {
|
||||
useritem = JSON.parse(data.useritem)
|
||||
that.updata.receiver = useritem.receiveName
|
||||
that.updata.phone = useritem.receivePhone
|
||||
that.updata.receiveAddress = useritem.areaName + useritem
|
||||
.receiveAddress
|
||||
that.userid = useritem.id
|
||||
}
|
||||
uni.$off('updata')
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
@ -300,17 +312,6 @@
|
||||
duration: '2000',
|
||||
})
|
||||
}
|
||||
let useritem = null
|
||||
uni.$on('updata', function(data) {
|
||||
if (data.useritem) {
|
||||
useritem = JSON.parse(data.useritem)
|
||||
that.updata.receiver = useritem.receiveName
|
||||
that.updata.phone = useritem.receivePhone
|
||||
that.updata.receiveAddress = useritem.areaName + useritem.receiveAddress
|
||||
that.userid = useritem.id
|
||||
}
|
||||
uni.$off('updata')
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
yaoqingshowtrue() {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user