Commit 95959c9d authored by Mac's avatar Mac

个人资料的定位

parent 460ca7cc
......@@ -81,9 +81,11 @@
</view>
<input v-if="item1.name=='昵称' && item1.subType==1" maxlength='10' :placeholder="item1.placehloder" :disabled="item1.disabled" v-model="data[item1.field]" :type="item1.showType" class="subInput" />
<input v-if="item1.name!='昵称' && item1.subType==1" :placeholder="item1.placehloder" :disabled="item1.disabled" v-model="data[item1.field]" :type="item1.showType" class="subInput" @input='srnumber($event,item1.field)' />
<input v-if="item1.name=='微信号' && item1.subType==1" maxlength='20' :placeholder="item1.placehloder" :disabled="item1.disabled" v-model="data[item1.field]" :type="item1.showType" class="subInput" />
<input v-if="item1.name!='昵称'&&item1.name!='微信号' && item1.subType==1" :placeholder="item1.placehloder" :disabled="item1.disabled" v-model="data[item1.field]" :type="item1.showType" class="subInput" @input='srnumber($event,item1.field)' />
<!-- 显示有昵称的长度 -->
<view class="unit" v-if="item1.name=='昵称' && item1.subType==1">{{data[item1.field].length}}/10</view>
<view class="unit" v-if="item1.name=='微信号' && item1.subType==1">{{data[item1.field].length}}/20</view>
<view class="unit" v-if="item1.unit">
{{item1.unit}}
</view>
......@@ -96,7 +98,11 @@
</view>
<view class="subpicker" v-if="item1.subType==3" @click="addressShow = true">
<Text :style="{'color':address!=''? '#303133':'#9D9C9B'}">{{address!=''? address :'请选择'}}</Text>
<pickerAddress v-model="addressShow" @confirm="addresspick" />
<pickerAddress v-model="addressShow" @confirm="addresspick()" />
</view>
<view class="subpicker" v-if="item1.subType==5" @click="addressShow2 = true">
<Text :style="{'color':location!=''? '#303133':'#9D9C9B'}">{{location!=''? location :'请选择'}}</Text>
<pickerAddress v-model="addressShow2" @confirm="addresspick2()" />
</view>
</view>
<!-- 头像上传的情况 4-26新加 -->
......@@ -144,7 +150,7 @@
</view>
</view>
</view>
<view style="width: 100%;height:60px;position: fixed;left: 0;bottom: 0;display: flex;align-items: center;justify-content: center;background: #FFF;z-index: 99999;">
<view style="width: 100%;height:60px;position: fixed;left: 0;bottom: 0;display: flex;align-items: center;justify-content: center;background: #FFF;z-index: 99;">
<view class="saveBtn" :style="{'background-color': `${mainColor}`}" @click="saveData">
保存
</view>
......@@ -174,6 +180,14 @@
data:{},
//subType:1输入框,2选择框
childDataList:[{
name:"微信号",
field:"WechatNo",
placehloder:"请输入微信号",
subType:1,
showType:"text",
disabled:false,
must:true,
},{
name:"昵称",
field:"Name",
placehloder:"请填写昵称",
......@@ -189,6 +203,14 @@
showType:"text",
disabled:false,
must:true,//必填
},{
name:"手机号码",
field:"Moblie",
placehloder:"请输入手机号码",
subType:1,
showType:"number",
disabled:false,
must:true,
},{
name:"性别",
field:"SexStr",
......@@ -207,22 +229,6 @@
mode:"date",
disabled:false,
must:true,
},{
name:"手机号码",
field:"Moblie",
placehloder:"请输入手机号码",
subType:1,
showType:"number",
disabled:false,
must:true,
},{
name:"微信号",
field:"WechatNo",
placehloder:"请输入微信号",
subType:1,
showType:"text",
disabled:false,
must:true,
},{
name:"身高",
field:"Height",
......@@ -286,6 +292,14 @@
showType:"number",
disabled:false,
must:true,
},{
name:"个人定位",
field:"location",
placehloder:"请选择个人定位",
subType:5,
array:[],
mode:"region",
must:true,
},{
name:"毕业院校",
field:"SchoolInfo",
......@@ -461,7 +475,12 @@
IDCardBack:'',//反面
Moblie:'',//手机号
WechatNo:'',//微信号
location:'',//暂时参数个人定位
DWProvince:0,//个人省
DWCity:0,//个人市
DWDistrict:0,//个人区
},
locationtype:'',//判断地址选择是那个
//控制图片显示
AlbumListShow:{
img1:false,
......@@ -474,7 +493,9 @@
img8:false,
},
addressShow:false,
addressShow2:false,
address:'',
location:'',
Jumptype:0,
action:'',
showUploadList:false,
......@@ -522,7 +543,7 @@
this.$forceUpdate()
}
},
addresspick(obj) {
addresspick(obj,type) {
this.data.PName=obj.province.Name
this.data.Province=obj.province.ID
this.data.CName=obj.city.Name
......@@ -531,6 +552,12 @@
this.data.District=obj.area.ID
this.address=obj.province.Name+','+obj.city.Name+','+obj.area.Name
},
addresspick2(obj){
this.data.DWProvince=obj.province.ID
this.data.DWCity=obj.city.ID
this.data.DWDistrict=obj.area.ID
this.location=obj.province.Name+','+obj.city.Name+','+obj.area.Name
},
deleteimg(index,key){
let that = this
that.data.AlbumList[index]='';
......@@ -603,6 +630,8 @@
delete msg.nativePlace
delete msg.addCode
delete msg.location
if(this.data.Name == ''){
uni.showToast({
title: '昵称不能为空',
......@@ -706,6 +735,14 @@
});
return
}
if(this.data.DWProvince==0){
uni.showToast({
title: '请选择个人定位',
duration: 2000,
icon:"none"
});
return
}
// if(this.data.address==""){
// uni.showToast({
......@@ -853,6 +890,12 @@
this.address=""
}
if(res.data.DWPName&&res.data.DWCName&&res.data.DWDName){
this.location=res.data.DWPName+','+res.data.DWCName+','+res.data.DWDName
}else{
this.location=""
}
if(res.data.AlbumList){
res.data.AlbumList.map((item,index)=>{
this.AlbumListShow[`img${index+1}`]=true
......
......@@ -343,6 +343,7 @@
<view class="bubble" v-if="dataList.CarInfoStr">{{dataList.CarInfoStr}}</view>
<view class="bubble" v-if="dataList.Moblie && mall_UserInfo.UserId == dataList.Id">电话号码:{{dataList.Moblie}}</view>
<view class="bubble" v-if="dataList.WechatNo && mall_UserInfo.UserId == dataList.Id" >微信号:{{dataList.WechatNo}}</view>
<view class="bubble" v-if="dataList.DWCName!=''" >定位:{{dataList.DWPName}},{{dataList.DWCName}},{{dataList.DWDName}}</view>
</view>
<view class="pd-title">其他资料</view>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment