|
@@ -64,7 +64,7 @@
|
|
|
@on-list-change="changePhotoListHeader"
|
|
@on-list-change="changePhotoListHeader"
|
|
|
>
|
|
>
|
|
|
<template v-slot:addBtn>
|
|
<template v-slot:addBtn>
|
|
|
- <image :src="form.oneInchPhotos ? $method.splitImgHost( form.oneInchPhotos) : '/static/info_1.png'" style="width: 120rpx; height: 169rpx;"></image>
|
|
|
|
|
|
|
+ <image :src="form.oneInchPhotos ? $method.splitImgHost(form.oneInchPhotos) : '/static/info_1.png'" style="width: 120rpx; height: 169rpx;"></image>
|
|
|
</template>
|
|
</template>
|
|
|
</u-upload>
|
|
</u-upload>
|
|
|
</u-form-item>
|
|
</u-form-item>
|
|
@@ -104,12 +104,12 @@
|
|
|
</u-form-item> -->
|
|
</u-form-item> -->
|
|
|
</u-form>
|
|
</u-form>
|
|
|
</view>
|
|
</view>
|
|
|
- <button @click="resultForm" class="submit_btn">提交</button>
|
|
|
|
|
|
|
+ <button @click="resultForm" class="submit_btn">提交</button>
|
|
|
</view>
|
|
</view>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
- import {mapGetters} from 'vuex';
|
|
|
|
|
|
|
+import { mapGetters } from 'vuex';
|
|
|
export default {
|
|
export default {
|
|
|
data() {
|
|
data() {
|
|
|
return {
|
|
return {
|
|
@@ -159,54 +159,54 @@ export default {
|
|
|
}
|
|
}
|
|
|
],
|
|
],
|
|
|
width: 0,
|
|
width: 0,
|
|
|
- height: 0,
|
|
|
|
|
|
|
+ height: 0
|
|
|
}
|
|
}
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
onReady() {
|
|
onReady() {
|
|
|
this.$refs.uForm.setRules(this.rules);
|
|
this.$refs.uForm.setRules(this.rules);
|
|
|
- this.form = this.userInfo
|
|
|
|
|
- if(this.form.houseProvince === ''||this.form.houseProvince == null){
|
|
|
|
|
- this.form.houseProvince = '广东省'
|
|
|
|
|
|
|
+ this.form = this.userInfo;
|
|
|
|
|
+ if (this.form.houseProvince === '' || this.form.houseProvince == null) {
|
|
|
|
|
+ this.form.houseProvince = '广东省';
|
|
|
}
|
|
}
|
|
|
- if(this.form.houseCity === ''||this.form.houseCity == null){
|
|
|
|
|
- this.form.houseCity = '广州市'
|
|
|
|
|
|
|
+ if (this.form.houseCity === '' || this.form.houseCity == null) {
|
|
|
|
|
+ this.form.houseCity = '广州市';
|
|
|
}
|
|
}
|
|
|
- if(this.form.houseDistrict === ''||this.form.houseDistrict == null){
|
|
|
|
|
- this.form.houseDistrict = '天河区'
|
|
|
|
|
|
|
+ if (this.form.houseDistrict === '' || this.form.houseDistrict == null) {
|
|
|
|
|
+ this.form.houseDistrict = '天河区';
|
|
|
}
|
|
}
|
|
|
- if(this.form.province === ''||this.form.province == null){
|
|
|
|
|
- this.form.province = '广东省'
|
|
|
|
|
|
|
+ if (this.form.province === '' || this.form.province == null) {
|
|
|
|
|
+ this.form.province = '广东省';
|
|
|
}
|
|
}
|
|
|
- if(this.form.city === ''||this.form.city == null){
|
|
|
|
|
- this.form.city = '广州市'
|
|
|
|
|
|
|
+ if (this.form.city === '' || this.form.city == null) {
|
|
|
|
|
+ this.form.city = '广州市';
|
|
|
}
|
|
}
|
|
|
- if(this.form.district === ''||this.form.district == null){
|
|
|
|
|
- this.form.district = '天河区'
|
|
|
|
|
|
|
+ if (this.form.district === '' || this.form.district == null) {
|
|
|
|
|
+ this.form.district = '天河区';
|
|
|
}
|
|
}
|
|
|
- if(this.form.marry !== null && this.form.marry != 'undefined' && this.form.marry !== ''){
|
|
|
|
|
- this.index_marry = this.array_marry.indexOf(this.form.marry)
|
|
|
|
|
|
|
+ if (this.form.marry !== null && this.form.marry != 'undefined' && this.form.marry !== '') {
|
|
|
|
|
+ this.index_marry = this.array_marry.indexOf(this.form.marry);
|
|
|
}
|
|
}
|
|
|
- if(this.form.politic !== null && this.form.politic != 'undefined' && this.form.politic !== ''){
|
|
|
|
|
- this.index_politic = this.array_politic.indexOf(this.form.politic)
|
|
|
|
|
|
|
+ if (this.form.politic !== null && this.form.politic != 'undefined' && this.form.politic !== '') {
|
|
|
|
|
+ this.index_politic = this.array_politic.indexOf(this.form.politic);
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
onLoad(option) {
|
|
onLoad(option) {
|
|
|
- this.getUserInfos()
|
|
|
|
|
|
|
+ this.getUserInfos();
|
|
|
const Verify = require('@/wxcomponents/verify_mpsdk/main.js');
|
|
const Verify = require('@/wxcomponents/verify_mpsdk/main.js');
|
|
|
Verify.init();
|
|
Verify.init();
|
|
|
- this.array_marry = this.$store.state.dictObj['marry_status']
|
|
|
|
|
- this.array_politic = this.$store.state.dictObj['politic_status']
|
|
|
|
|
|
|
+ this.array_marry = this.$store.state.dictObj['marry_status'];
|
|
|
|
|
+ this.array_politic = this.$store.state.dictObj['politic_status'];
|
|
|
},
|
|
},
|
|
|
methods: {
|
|
methods: {
|
|
|
- getUserInfos(){
|
|
|
|
|
- var self = this
|
|
|
|
|
|
|
+ getUserInfos() {
|
|
|
|
|
+ var self = this;
|
|
|
this.$api.getInfo().then(res => {
|
|
this.$api.getInfo().then(res => {
|
|
|
- this.form = res.data.data
|
|
|
|
|
|
|
+ this.form = res.data.data;
|
|
|
if (this.form.HeadImageUrl !== null) {
|
|
if (this.form.HeadImageUrl !== null) {
|
|
|
self.fileList = [{ url: self.$method.splitImgHost(self.form.oneInchPhotos) }];
|
|
self.fileList = [{ url: self.$method.splitImgHost(self.form.oneInchPhotos) }];
|
|
|
}
|
|
}
|
|
|
- })
|
|
|
|
|
|
|
+ });
|
|
|
},
|
|
},
|
|
|
changePhotoListHeader(lists, name) {
|
|
changePhotoListHeader(lists, name) {
|
|
|
this.fileList = lists;
|
|
this.fileList = lists;
|
|
@@ -233,7 +233,7 @@ export default {
|
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
|
self.$api.facecertification(self.BizToken).then(faceRec => {
|
|
self.$api.facecertification(self.BizToken).then(faceRec => {
|
|
|
//刷新用户信息
|
|
//刷新用户信息
|
|
|
- self.getUserInfos()
|
|
|
|
|
|
|
+ self.getUserInfos();
|
|
|
});
|
|
});
|
|
|
}, 500);
|
|
}, 500);
|
|
|
},
|
|
},
|
|
@@ -249,7 +249,7 @@ export default {
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
imageInfos() {
|
|
imageInfos() {
|
|
|
- var self = this
|
|
|
|
|
|
|
+ var self = this;
|
|
|
return new Promise((resolve, reject) => {
|
|
return new Promise((resolve, reject) => {
|
|
|
uni.getImageInfo({
|
|
uni.getImageInfo({
|
|
|
src: self.fileList[0].url,
|
|
src: self.fileList[0].url,
|
|
@@ -264,13 +264,13 @@ export default {
|
|
|
height: '50%',
|
|
height: '50%',
|
|
|
success: async rest => {
|
|
success: async rest => {
|
|
|
const waitUpload = await self.uploadFile(rest.tempFilePath, 0);
|
|
const waitUpload = await self.uploadFile(rest.tempFilePath, 0);
|
|
|
- resolve()
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ resolve();
|
|
|
|
|
+ }
|
|
|
});
|
|
});
|
|
|
} else {
|
|
} else {
|
|
|
console.log('无需压缩');
|
|
console.log('无需压缩');
|
|
|
const waitUpload = await self.uploadFile(self.fileList[0].url, 0);
|
|
const waitUpload = await self.uploadFile(self.fileList[0].url, 0);
|
|
|
- resolve()
|
|
|
|
|
|
|
+ resolve();
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
@@ -305,7 +305,7 @@ export default {
|
|
|
title: '提交成功',
|
|
title: '提交成功',
|
|
|
icon: 'none'
|
|
icon: 'none'
|
|
|
});
|
|
});
|
|
|
- self.$api.refreshUserInfo()
|
|
|
|
|
|
|
+ self.$api.refreshUserInfo();
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
@@ -364,7 +364,7 @@ export default {
|
|
|
this.form.politic = e.detail.value;
|
|
this.form.politic = e.detail.value;
|
|
|
},
|
|
},
|
|
|
bindPickerChangeMarry(e) {
|
|
bindPickerChangeMarry(e) {
|
|
|
- console.log(e)
|
|
|
|
|
|
|
+ console.log(e);
|
|
|
this.form.marry = e.detail.value;
|
|
this.form.marry = e.detail.value;
|
|
|
},
|
|
},
|
|
|
//城市
|
|
//城市
|
|
@@ -375,7 +375,7 @@ export default {
|
|
|
},
|
|
},
|
|
|
// 籍贯获取选择的地区
|
|
// 籍贯获取选择的地区
|
|
|
handleGetRegion(region) {
|
|
handleGetRegion(region) {
|
|
|
- console.log(region)
|
|
|
|
|
|
|
+ console.log(region);
|
|
|
this.form.houseProvince = region[0].name;
|
|
this.form.houseProvince = region[0].name;
|
|
|
this.form.houseCity = region[1].name;
|
|
this.form.houseCity = region[1].name;
|
|
|
this.form.houseDistrict = region[2].name;
|
|
this.form.houseDistrict = region[2].name;
|
|
@@ -387,31 +387,30 @@ export default {
|
|
|
// var month = this.userBirth.substr(5, 2);
|
|
// var month = this.userBirth.substr(5, 2);
|
|
|
// var day = this.userBirth.substr(8, 2);
|
|
// var day = this.userBirth.substr(8, 2);
|
|
|
},
|
|
},
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
actionSheetCallback(index) {
|
|
actionSheetCallback(index) {
|
|
|
uni.hideKeyboard();
|
|
uni.hideKeyboard();
|
|
|
this.form.sex_text = this.actionSheetList[index].text;
|
|
this.form.sex_text = this.actionSheetList[index].text;
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
- computed: {...mapGetters(['userInfo'])},
|
|
|
|
|
- watch:{
|
|
|
|
|
- userInfo(val, oldVal){
|
|
|
|
|
- this.form = val
|
|
|
|
|
- console.log(this.form,66)
|
|
|
|
|
|
|
+ computed: { ...mapGetters(['userInfo']) },
|
|
|
|
|
+ watch: {
|
|
|
|
|
+ userInfo(val, oldVal) {
|
|
|
|
|
+ this.form = val;
|
|
|
|
|
+ console.log(this.form, 66);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
};
|
|
};
|
|
|
</script>
|
|
</script>
|
|
|
|
|
|
|
|
-
|
|
|
|
|
<style scope>
|
|
<style scope>
|
|
|
- .submit_btn{
|
|
|
|
|
- background-color: #32467B !important;
|
|
|
|
|
- border-color: #32467B !important;
|
|
|
|
|
- color: #FFFFFF;
|
|
|
|
|
- font-size: 30rpx;
|
|
|
|
|
- padding: 5rpx;
|
|
|
|
|
- }
|
|
|
|
|
|
|
+.submit_btn {
|
|
|
|
|
+ background-color: #32467b !important;
|
|
|
|
|
+ border-color: #32467b !important;
|
|
|
|
|
+ color: #ffffff;
|
|
|
|
|
+ font-size: 30rpx;
|
|
|
|
|
+ padding: 5rpx;
|
|
|
|
|
+}
|
|
|
.u-form-item__message.data-v-5e7216f1 {
|
|
.u-form-item__message.data-v-5e7216f1 {
|
|
|
padding: 0px !important;
|
|
padding: 0px !important;
|
|
|
}
|
|
}
|