|
|
@@ -27,8 +27,8 @@
|
|
|
</view>
|
|
|
<view class="info-gender-box">
|
|
|
<radio-group @change="radioCheck" class="padding-left-2">
|
|
|
- <label class="radio margin-right-10"><radio value="0" :checked="userSex==='0'" color="#00A1B4" class="form-radio"/>男</label>
|
|
|
- <label class="radio"><radio value="1" :checked="userSex==='1'" color="#00A1B4" class="form-radio"/>女</label>
|
|
|
+ <label class="radio margin-right-10"><radio value="1" :checked="userSex==='1'" color="#00A1B4" class="form-radio"/>男</label>
|
|
|
+ <label class="radio"><radio value="0" :checked="userSex==='0'" color="#00A1B4" class="form-radio"/>女</label>
|
|
|
</radio-group>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -58,7 +58,7 @@
|
|
|
</picker> -->
|
|
|
</view>
|
|
|
<view class="textarea-box">
|
|
|
- <textarea auto-height placeholder="请输入详细地址" />
|
|
|
+ <textarea auto-height placeholder="请输入详细地址" v-model="addressDetail" />
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -103,7 +103,7 @@
|
|
|
<text>您目前从事的家具品牌</text>
|
|
|
</view>
|
|
|
<view class="info-value-box">
|
|
|
- <input type="text" placeholder="请输入您目前从事的家具品牌">
|
|
|
+ <input type="text" placeholder="请输入您目前从事的家具品牌" v-model="userBrand">
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
@@ -144,7 +144,11 @@
|
|
|
province: '',
|
|
|
city: '',
|
|
|
},
|
|
|
- address: ''
|
|
|
+ address: '',
|
|
|
+ addressObj:{},
|
|
|
+ userBrand:'',
|
|
|
+ addressDetail:'',
|
|
|
+ loginObj:{}
|
|
|
}
|
|
|
},
|
|
|
onLoad() {
|
|
|
@@ -164,6 +168,7 @@
|
|
|
methods: {
|
|
|
addresspick(obj) {
|
|
|
console.log(obj)
|
|
|
+ this.addressObj = obj;
|
|
|
this.txt = obj.province.name + obj.city.name;
|
|
|
},
|
|
|
getProvinceRequest(){
|
|
|
@@ -247,52 +252,6 @@
|
|
|
this.txt = data.data.join('')
|
|
|
console.log(data.data.join(''))
|
|
|
},
|
|
|
- bindMultiPickerColumnChange: function(e) {
|
|
|
- console.log('修改的列为:' + e.detail.column + ',值为:' + e.detail.value)
|
|
|
- this.multiIndex[e.detail.column] = e.detail.value
|
|
|
- switch (e.detail.column) {
|
|
|
- case 0: //拖动第1列
|
|
|
- switch (this.multiIndex[0]) {
|
|
|
- case 0:
|
|
|
- this.multiArray[1] = ['中国', '日本']
|
|
|
- this.multiArray[2] = ['北京', '上海', '广州']
|
|
|
- break
|
|
|
- case 1:
|
|
|
- this.multiArray[1] = ['英国', '法国']
|
|
|
- this.multiArray[2] = ['伦敦', '曼彻斯特']
|
|
|
- break
|
|
|
- }
|
|
|
- this.multiIndex.splice(1, 1, 0)
|
|
|
- this.multiIndex.splice(2, 1, 0)
|
|
|
- break
|
|
|
- case 1: //拖动第2列
|
|
|
- switch (this.multiIndex[0]) { //判断第一列是什么
|
|
|
- case 0:
|
|
|
- switch (this.multiIndex[1]) {
|
|
|
- case 0:
|
|
|
- this.multiArray[2] = ['北京', '上海', '广州']
|
|
|
- break
|
|
|
- case 1:
|
|
|
- this.multiArray[2] = ['东京','北海道']
|
|
|
- break
|
|
|
- }
|
|
|
- break
|
|
|
- case 1:
|
|
|
- switch (this.multiIndex[1]) {
|
|
|
- case 0:
|
|
|
- this.multiArray[2] = ['伦敦', '曼彻斯特']
|
|
|
- break
|
|
|
- case 1:
|
|
|
- this.multiArray[2] = ['巴黎', '马赛']
|
|
|
- break
|
|
|
- }
|
|
|
- break
|
|
|
- }
|
|
|
- this.multiIndex.splice(2, 1, 0)
|
|
|
- break
|
|
|
- }
|
|
|
- this.$forceUpdate()
|
|
|
- },
|
|
|
bindPickerChange(e,type) {
|
|
|
let that = this;
|
|
|
switch (type){
|
|
|
@@ -352,11 +311,50 @@
|
|
|
}
|
|
|
},
|
|
|
submitRequest(params){
|
|
|
- console.log(params)
|
|
|
- //this.goCustomCardPage('0')
|
|
|
+ console.log(params)
|
|
|
+ let that = this;
|
|
|
+ uni.request({
|
|
|
+ url:getApp().globalData.shareUrl, //需要设置为全局
|
|
|
+ method: 'POST',
|
|
|
+ header: {
|
|
|
+ 'content-type': 'application/x-www-form-urlencoded'
|
|
|
+ },
|
|
|
+ data: {
|
|
|
+ method: 'common_guest_login',
|
|
|
+ timestamp: getApp().globalData.globalTimestamp, //Date.now()
|
|
|
+ sign: md5('common_guest_login' + getApp().globalData.globalTimestamp),
|
|
|
+ phone:getApp().globalData.userPhone,
|
|
|
+ wxopenid:getApp().globalData.openId,
|
|
|
+ name:params.selfName,
|
|
|
+ sex:that.userSex,//0-女 1-男
|
|
|
+ province:that.addressObj.province.id,//省份id
|
|
|
+ city:that.addressObj.city.id,//城市id
|
|
|
+ detailaddress:that.addressDetail,
|
|
|
+ hangye:params.trade,
|
|
|
+ zhiye:params.profession,
|
|
|
+ purpose:params.ends,
|
|
|
+ brand:that.userBrand,
|
|
|
+ },
|
|
|
+ success: res => {
|
|
|
+ console.log(res)
|
|
|
+ if(res.data.code === 200){
|
|
|
+ that.loginObj = res.data.msg;
|
|
|
+ getApp().globalData.userCodeNumber = that.loginObj.code;
|
|
|
+ getApp().globalData.managerPhone = that.loginObj.qyjl_phone;
|
|
|
+ getApp().globalData.managerName = that.loginObj.qyjl_name;
|
|
|
+ this.goCustomCardPage(that.loginObj.pass)
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ uni.showToast({
|
|
|
+ title: res.data.msg,
|
|
|
+ icon: 'none'
|
|
|
+ });
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
},
|
|
|
goCustomCardPage(type){
|
|
|
- type === '1' ?
|
|
|
+ type === 1 ?
|
|
|
uni.redirectTo({
|
|
|
url: '/pages/index/successPage/index?types='+'custom', //游客成功页面
|
|
|
success: res => {},
|