修改身份信息和社保信息
This commit is contained in:
@@ -4707,7 +4707,7 @@ const laborType = [
|
||||
"残疾人",
|
||||
"外来农民工",
|
||||
];
|
||||
const insureType = ["已缴纳城乡居民社保", "已缴纳灵活就业社保"];
|
||||
const insureType = ["已缴纳城乡居民社保", "已缴纳灵活就业社保","已缴纳城镇企业职工社保"];
|
||||
|
||||
export default {
|
||||
ind,
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
<view class="headuser">
|
||||
<image src="@/static/img/head.svg" class="headuserImg" mode=""></image>
|
||||
<view v-if="auth.realNameState" class="name">
|
||||
<view class="userName">{{authInfo.realName}}</view>
|
||||
<view class="userInfo">{{idNumberFilter(authInfo.idNumber)}}</view>
|
||||
<view class="userName">{{ authInfo.realName }}</view>
|
||||
<view class="userInfo">{{ idNumberFilter(authInfo.idNumber) }}</view>
|
||||
</view>
|
||||
<view v-else class="name">
|
||||
<view class="userName">姓名</view>
|
||||
@@ -93,21 +93,23 @@
|
||||
<view class="name">
|
||||
姓名
|
||||
</view>
|
||||
<text v-if="auth.realNameState" style="color: #1b66ff;">{{auth.authInfo.realName}}</text>
|
||||
<input v-else type="text" value="" placeholder="请输入真实姓名" @input="setName" placeholder-style="color:#cccccc;" />
|
||||
<text v-if="auth.realNameState" style="color: #1b66ff;">{{ auth.authInfo.realName }}</text>
|
||||
<input v-else type="text" value="" placeholder="请输入真实姓名" @input="setName"
|
||||
placeholder-style="color:#cccccc;" />
|
||||
</view>
|
||||
<view>
|
||||
<view class="list">
|
||||
<view class="name">
|
||||
身份证号
|
||||
</view>
|
||||
<text v-if="auth.realNameState" style="color: #1b66ff;">{{idNumberFilter(auth.authInfo.idNumber)}}</text>
|
||||
<input v-else type="idcard" value="" placeholder="请输入身份证号" @input="setCard" style="text-transform:uppercase"
|
||||
placeholder-style="color:#cccccc;" />
|
||||
<text v-if="auth.realNameState" style="color: #1b66ff;">{{ idNumberFilter(auth.authInfo.idNumber)
|
||||
}}</text>
|
||||
<input v-else type="idcard" value="" placeholder="请输入身份证号" @input="setCard"
|
||||
style="text-transform:uppercase" placeholder-style="color:#cccccc;" />
|
||||
</view>
|
||||
<view v-if="error" class="error">身份证填写有误</view>
|
||||
</view>
|
||||
<picker :range="identityList" @change="identityChange" :value="index">
|
||||
<picker :range="identityList" @change="identityChange" :value="indexId">
|
||||
<view class="list">
|
||||
<view class="listLeft">
|
||||
<view class="name">
|
||||
@@ -134,7 +136,9 @@
|
||||
</view>
|
||||
<view class="listRight">
|
||||
<view class="listRightContent">
|
||||
<view class="" v-if="auth.insureState">{{insureList[indexBao]}}</view>
|
||||
<view class="" v-if="auth.insureState">{{ insureList[indexBao] ? insureList[indexBao] :
|
||||
authInfo.politics
|
||||
}}</view>
|
||||
<view class="" v-else>未选择</view>
|
||||
</view>
|
||||
<image src="@/static/img/right.svg" mode=""></image>
|
||||
@@ -178,20 +182,23 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import textdata from '@/common/textdata.js'
|
||||
import {
|
||||
import textdata from '@/common/textdata.js'
|
||||
import {
|
||||
setInfo
|
||||
} from '@/api/federation.js'
|
||||
import {
|
||||
mapGetters
|
||||
} from 'vuex'
|
||||
import {
|
||||
} from 'vuex'
|
||||
import {
|
||||
idNumberFilter
|
||||
} from '@/untils/format.js'
|
||||
} from '@/untils/format.js'
|
||||
|
||||
import {
|
||||
import {
|
||||
check18IdCardNo,
|
||||
validatenull
|
||||
} from '@/untils/validate.js'
|
||||
} from '@/untils/validate.js'
|
||||
|
||||
export default {
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
laborType: textdata.laborType,
|
||||
@@ -205,6 +212,9 @@
|
||||
identityList: textdata.laborType,
|
||||
insureList: textdata.insureType,
|
||||
realIndex: 0,
|
||||
|
||||
subIdentity: "",
|
||||
subSocial: "",
|
||||
};
|
||||
},
|
||||
onLoad() {
|
||||
@@ -212,10 +222,15 @@
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['auth', 'authInfo', 'autograph']),
|
||||
indexbao() {
|
||||
if (this.auth.insureState) {
|
||||
return this.authInfo.bakValue - 1
|
||||
} else {
|
||||
indexId() {
|
||||
if (this.index > 0) {
|
||||
return this.index
|
||||
} else if (this.authInfo.nation) {
|
||||
if (this.identityList.findIndex(item => item === this.authInfo.nation) >= 0) {
|
||||
return this.identityList.findIndex(item => item === this.authInfo.nation)
|
||||
}
|
||||
return 0;
|
||||
} {
|
||||
return 0
|
||||
}
|
||||
},
|
||||
@@ -224,15 +239,20 @@
|
||||
return check18IdCardNo(this.card) && !validatenull(this.name)
|
||||
},
|
||||
indexBao() {
|
||||
if (this.auth.insureState) {
|
||||
if (this.auth.insureState && this.authInfo.bakValue >= 0) {
|
||||
return this.authInfo.bakValue - 1
|
||||
} else if (this.authInfo.politics) {
|
||||
if (this.insureList.findIndex(item => item === this.authInfo.politics) >= 0) {
|
||||
return this.insureList.findIndex(item => item === this.authInfo.politics)
|
||||
}
|
||||
return 0;
|
||||
} else {
|
||||
return 0
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
setSeal(){
|
||||
setSeal() {
|
||||
if (this.auth.realNameState) {
|
||||
uni.navigateTo({
|
||||
url: '/pageMy/setUserBase/seal/index'
|
||||
@@ -244,7 +264,7 @@
|
||||
})
|
||||
}
|
||||
},
|
||||
setIcCard: function() {
|
||||
setIcCard: function () {
|
||||
if (this.auth.realNameState) {
|
||||
uni.navigateTo({
|
||||
url: '/pageMy/setUserBase/icCard/index'
|
||||
@@ -256,12 +276,12 @@
|
||||
})
|
||||
}
|
||||
},
|
||||
goRealName: function() {
|
||||
goRealName: function () {
|
||||
uni.navigateTo({
|
||||
url: '/pageMy/setUserBase/realName'
|
||||
})
|
||||
},
|
||||
bindPickerChangeBao: function(e) {
|
||||
bindPickerChangeBao: function (e) {
|
||||
uni.showLoading()
|
||||
this.$store.dispatch('authInsure', e.target.value * 1 + 1).then(resp => {
|
||||
uni.hideLoading()
|
||||
@@ -269,7 +289,7 @@
|
||||
uni.hideLoading()
|
||||
})
|
||||
},
|
||||
bindPickerChange: function(e) {
|
||||
bindPickerChange: function (e) {
|
||||
uni.showLoading()
|
||||
this.$store.dispatch('authLabor').then(resp => {
|
||||
this.index = e.target.value;
|
||||
@@ -281,15 +301,15 @@
|
||||
idNumberFilter,
|
||||
|
||||
|
||||
setName: function(e) {
|
||||
setName: function (e) {
|
||||
this.name = e.detail.value;
|
||||
},
|
||||
setCard: function(e) {
|
||||
setCard: function (e) {
|
||||
this.card = e.detail.value.toUpperCase();
|
||||
this.error = !check18IdCardNo(this.card)
|
||||
return e.detail.value.toUpperCase()
|
||||
},
|
||||
goSet: function() {
|
||||
goSet: function () {
|
||||
this.loading = true
|
||||
this.$store.dispatch('authRealName', {
|
||||
name: this.name,
|
||||
@@ -303,8 +323,14 @@
|
||||
})
|
||||
},
|
||||
idNumberFilter,
|
||||
identityChange(val) {
|
||||
console.log("val",val);
|
||||
async identityChange(val) {
|
||||
const value = this.identityList.filter((item, index) => index === val.detail.value)
|
||||
this.subIdentity = value.join('')
|
||||
// await setInfo({ nation: this.subIdentity, politics: this.subSocial })
|
||||
await setInfo({ nation: value.join(''), politics: "" })
|
||||
|
||||
|
||||
console.log(value.join(''), '00000000000000');
|
||||
uni.showLoading();
|
||||
this.$store.dispatch('authLabor').then(() => {
|
||||
this.realIndex = val.detail.value;
|
||||
@@ -313,45 +339,51 @@
|
||||
uni.hideLoading();
|
||||
})
|
||||
},
|
||||
insureChange(val) {
|
||||
async insureChange(val) {
|
||||
console.log("", val, '-----');
|
||||
const value = this.insureList.filter((item, index) => index === val.detail.value)
|
||||
this.subSocial = value.join('')
|
||||
// await setInfo({ nation: this.subIdentity, politics: this.subSocial })
|
||||
await setInfo({ nation: "", politics: value.join('') })
|
||||
|
||||
uni.showLoading();
|
||||
this.$store.dispatch('authInsure', val.detail.value * 1 + 1).then(() => {
|
||||
uni.hideLoading();
|
||||
}).catch(()=>{
|
||||
}).catch(() => {
|
||||
uni.hideLoading();
|
||||
})
|
||||
},
|
||||
}
|
||||
};
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.nochoose {
|
||||
.nochoose {
|
||||
color: #1b66ff;
|
||||
}
|
||||
}
|
||||
|
||||
.listRight {
|
||||
.listRight {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-family: PingFangSC-Regular;
|
||||
font-size: 28rpx;
|
||||
color: #999999;
|
||||
}
|
||||
}
|
||||
|
||||
.listRight image {
|
||||
.listRight image {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
margin-left: 15rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.listContent {
|
||||
.listContent {
|
||||
font-family: PingFangSC-Regular;
|
||||
font-size: 28rpx;
|
||||
color: #666666;
|
||||
}
|
||||
}
|
||||
|
||||
.list {
|
||||
.list {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
@@ -360,23 +392,23 @@
|
||||
color: #333333;
|
||||
padding: 30rpx;
|
||||
line-height: 50rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.border {
|
||||
.border {
|
||||
margin-left: 30rpx;
|
||||
width: 720rpx;
|
||||
height: 2rpx;
|
||||
background-color: #f2f2f2;
|
||||
/* border-bottom: 1rpx solid #dddddd; */
|
||||
}
|
||||
}
|
||||
|
||||
.tx image {
|
||||
.tx image {
|
||||
width: 32rpx;
|
||||
height: 32rpx;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.tx {
|
||||
.tx {
|
||||
font-family: PingFangSC-Regular;
|
||||
font-size: 24rpx;
|
||||
color: #ffffff;
|
||||
@@ -385,55 +417,55 @@
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
}
|
||||
|
||||
.userInfo {
|
||||
.userInfo {
|
||||
font-family: PingFangSC-Regular;
|
||||
font-size: 26rpx;
|
||||
color: #ffffff;
|
||||
font-weight: normal;
|
||||
}
|
||||
}
|
||||
|
||||
.name {
|
||||
.name {
|
||||
margin-left: 20rpx;
|
||||
font-family: PingFangSC-Medium;
|
||||
font-size: 36rpx;
|
||||
color: #ffffff;
|
||||
font-weight: bold;
|
||||
line-height: 50rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.headuserImg {
|
||||
.headuserImg {
|
||||
width: 100rpx;
|
||||
height: 100rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.headuser {
|
||||
.headuser {
|
||||
padding: 30rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
}
|
||||
|
||||
.stamp {
|
||||
.stamp {
|
||||
position: absolute;
|
||||
top: 30rpx;
|
||||
right: 30rpx;
|
||||
/* opacity: 0.6; */
|
||||
width: 200rpx;
|
||||
height: 200rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.logo {
|
||||
.logo {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
opacity: 0.1;
|
||||
width: 200rpx;
|
||||
height: 200rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.head {
|
||||
.head {
|
||||
width: 690rpx;
|
||||
height: 250rpx;
|
||||
padding-top: 30rpx;
|
||||
@@ -443,18 +475,18 @@
|
||||
position: relative;
|
||||
background: #1b66ff;
|
||||
box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
}
|
||||
|
||||
.body {
|
||||
.body {
|
||||
background-color: #fefefe;
|
||||
padding-top: 30rpx;
|
||||
}
|
||||
}
|
||||
|
||||
page {
|
||||
page {
|
||||
background-color: #f6f6f6;
|
||||
}
|
||||
}
|
||||
|
||||
.bottombtn {
|
||||
.bottombtn {
|
||||
background-color: #1B66FF;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
@@ -463,9 +495,9 @@
|
||||
font-size: 32rpx;
|
||||
height: 90rpx;
|
||||
line-height: 90rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.btn {
|
||||
.btn {
|
||||
background-color: #fefefe;
|
||||
width: 690rpx;
|
||||
padding: 30rpx;
|
||||
@@ -473,24 +505,24 @@
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.name {
|
||||
.name {
|
||||
font-family: PingFangSC-Regular;
|
||||
font-size: 32rpx;
|
||||
color: #333333;
|
||||
width: 200rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.error {
|
||||
.error {
|
||||
font-family: PingFangSC-Regular;
|
||||
font-size: 26rpx;
|
||||
color: red;
|
||||
margin: 5px 0 0 200rpx;
|
||||
padding-bottom: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.list {
|
||||
.list {
|
||||
padding: 20rpx;
|
||||
padding-left: 0;
|
||||
display: flex;
|
||||
@@ -498,50 +530,50 @@
|
||||
justify-content: space-between;
|
||||
border-bottom: 1rpx solid #f2f2f2;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.pickerList {
|
||||
.pickerList {
|
||||
padding: 20rpx;
|
||||
padding-left: 0;
|
||||
|
||||
border-bottom: 1rpx solid #f2f2f2;
|
||||
}
|
||||
}
|
||||
|
||||
.listRight {
|
||||
.listRight {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-family: PingFangSC-Regular;
|
||||
font-size: 28rpx;
|
||||
color: #999999;
|
||||
}
|
||||
}
|
||||
|
||||
.listRightContent {
|
||||
.listRightContent {
|
||||
color: #1b66ff;
|
||||
}
|
||||
}
|
||||
|
||||
.listRight image {
|
||||
.listRight image {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
margin-left: 15rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.listContent {
|
||||
.listContent {
|
||||
color: #999;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.body {
|
||||
.body {
|
||||
background-color: #fefefe;
|
||||
padding-left: 20rpx;
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.nocheck {
|
||||
.nocheck {
|
||||
opacity: 0.3;
|
||||
}
|
||||
}
|
||||
|
||||
page {
|
||||
page {
|
||||
background-color: #f6f6f6;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user