mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-09 13:26:44 +08:00
Merge branch 'dev' of http://112.124.100.131/GFRS/ebiz-h5 into dev
This commit is contained in:
@@ -219,13 +219,7 @@ export default {
|
||||
text: '港澳台居民居住证'
|
||||
}
|
||||
],
|
||||
//出生证明
|
||||
// birthType: [
|
||||
// {
|
||||
// id: 1,
|
||||
// text: '身份证'
|
||||
// }
|
||||
// ],
|
||||
|
||||
//投保人/被保人关系
|
||||
relationToAppnt: [
|
||||
{
|
||||
@@ -748,5 +742,110 @@ export default {
|
||||
id: '1',
|
||||
text: '已签收'
|
||||
}
|
||||
]
|
||||
],
|
||||
// 民族
|
||||
nationType: [
|
||||
{ id: '01', text: '汉族' },
|
||||
{ id: '02', text: '蒙古族' },
|
||||
{ id: '03', text: '回族' },
|
||||
{ id: '04', text: '藏族' },
|
||||
{ id: '05', text: '维吾尔族' },
|
||||
{ id: '06', text: '苗族' },
|
||||
{ id: '07', text: '彝族' },
|
||||
{ id: '08', text: '壮族' },
|
||||
{ id: '09', text: '布依族' },
|
||||
{ id: '10', text: '朝鲜族' },
|
||||
{ id: '11', text: '满族' },
|
||||
{ id: '12', text: '侗族' },
|
||||
{ id: '13', text: '瑶族' },
|
||||
{ id: '14', text: '白族' },
|
||||
{ id: '15', text: '土家族' },
|
||||
{ id: '16', text: '哈尼族' },
|
||||
{ id: '17', text: '哈萨克族' },
|
||||
{ id: '18', text: '傣族' },
|
||||
{ id: '19', text: '黎族' },
|
||||
{ id: '20', text: '傈僳族' },
|
||||
{ id: '21', text: '佤族' },
|
||||
{ id: '22', text: '畲族' },
|
||||
{ id: '23', text: '高山族' },
|
||||
{ id: '24', text: '拉祜族' },
|
||||
{ id: '25', text: '水族' },
|
||||
{ id: '26', text: '东乡族' },
|
||||
{ id: '27', text: '纳西族' },
|
||||
{ id: '28', text: '景颇族' },
|
||||
{ id: '代码', text: '民族' },
|
||||
{ id: '29', text: '柯尔克孜族' },
|
||||
{ id: '30', text: '土族' },
|
||||
{ id: '31', text: '达斡尔族' },
|
||||
{ id: '32', text: '仫佬族' },
|
||||
{ id: '33', text: '羌族' },
|
||||
{ id: '34', text: '布朗族' },
|
||||
{ id: '35', text: '撒拉族' },
|
||||
{ id: '36', text: '毛难族' },
|
||||
{ id: '37', text: '仡佬族' },
|
||||
{ id: '38', text: '锡伯族' },
|
||||
{ id: '39', text: '阿昌族' },
|
||||
{ id: '40', text: '普米族' },
|
||||
{ id: '41', text: '塔吉克族' },
|
||||
{ id: '42', text: '怒族' },
|
||||
{ id: '43', text: '乌孜别克族' },
|
||||
{ id: '44', text: '俄罗斯族' },
|
||||
{ id: '45', text: '鄂温克族' },
|
||||
{ id: '46', text: '崩龙族' },
|
||||
{ id: '47', text: '保安族' },
|
||||
{ id: '48', text: '裕固族' },
|
||||
{ id: '49', text: '京族' },
|
||||
{ id: '50', text: '塔塔尔族' },
|
||||
{ id: '51', text: '独龙族' },
|
||||
{ id: '52', text: '鄂伦春族' },
|
||||
{ id: '53', text: '赫哲族' },
|
||||
{ id: '54', text: '门巴族' },
|
||||
{ id: '55', text: '珞巴族' },
|
||||
{ id: '56', text: '基诺族' },
|
||||
{ id: '97', text: '其他' },
|
||||
{ id: '98', text: '外国血统' }
|
||||
],
|
||||
//政治面貌
|
||||
politicsStatus: [
|
||||
{ id: '01', text: '中共党员' },
|
||||
{ id: '02', text: '中共预备党员' },
|
||||
{ id: '04', text: '民革党员' },
|
||||
{ id: '05', text: '民盟盟员' },
|
||||
{ id: '06', text: '民建会员' },
|
||||
{ id: '07', text: '民进会员' },
|
||||
{ id: '08', text: '农工党党员' },
|
||||
{ id: '09', text: '致公党党员' },
|
||||
{ id: '10', text: '九三学社社员' },
|
||||
{ id: '11', text: '台盟盟员' },
|
||||
{ id: '12', text: '无党派人士' }
|
||||
],
|
||||
rsIdType: [
|
||||
{
|
||||
id: 1,
|
||||
text: '居民身份证'
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
text: '户口本'
|
||||
},
|
||||
|
||||
{
|
||||
id: 5,
|
||||
text: '港澳居民来往内地通行证'
|
||||
},
|
||||
{
|
||||
id: 6,
|
||||
text: '台湾居民来往大陆通行证'
|
||||
},
|
||||
{
|
||||
id: 8,
|
||||
text: '外国人永久居留身份证'
|
||||
},
|
||||
{
|
||||
id: 9,
|
||||
text: '港澳台居民居住证'
|
||||
}
|
||||
],
|
||||
// 健康状况
|
||||
healthCondition: []
|
||||
}
|
||||
|
||||
@@ -5,8 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
let apiDomain, imgDomain, assetsUrl, mainUrl,
|
||||
payUrl // 保融支付的收银台服务地址
|
||||
let apiDomain, imgDomain, assetsUrl, mainUrl, payUrl // 保融支付的收银台服务地址
|
||||
|
||||
// 可以多个接口域名,按需添加
|
||||
console.log('环境:', process.env.VUE_APP_FLAG)
|
||||
@@ -18,7 +17,7 @@ switch (process.env.VUE_APP_FLAG) {
|
||||
|
||||
// 静态服务资源
|
||||
assetsUrl = 'http://139.199.50.151:8000/app/'
|
||||
mainUrl = 'http://47.96.143.111'
|
||||
mainUrl = 'http://139.199.50.151'
|
||||
payUrl = 'http://10.10.100.84:7003/s3-modules-gateway/embed/gateway.action'
|
||||
break
|
||||
case 'staging':
|
||||
@@ -36,7 +35,7 @@ switch (process.env.VUE_APP_FLAG) {
|
||||
// 静态服务资源
|
||||
// assetsUrl = 'http://211.159.248.138:7001/' // 上生产前
|
||||
assetsUrl = 'https://iagentsales-sr.e-guofu.com:8443/'
|
||||
mainUrl = 'http://47.96.143.111'
|
||||
mainUrl = 'https://iagentsales.e-guofu.com'
|
||||
payUrl = 'https://uns3.e-guofu.com/s3-modules-gateway/embed/gateway.action'
|
||||
break
|
||||
}
|
||||
|
||||
@@ -1 +1,32 @@
|
||||
export default []
|
||||
const DepartInfo = () => import('@/views/ebiz/Department/DepartInfo')
|
||||
const DepartInfoOne = () => import('@/views/ebiz/Department/DepartInfoOne')
|
||||
const DepartInfoTwo = () => import('@/views/ebiz/Department/DepartInfoTwo')
|
||||
export default [
|
||||
{
|
||||
path: '/Department/DepartInfo',
|
||||
name: 'DepartmentInformation',
|
||||
component: DepartInfo,
|
||||
meta: {
|
||||
title: '入司基本信息'
|
||||
},
|
||||
redirect: '/Department/DepartInfo/one',
|
||||
children: [
|
||||
{
|
||||
path: 'one',
|
||||
name: 'DepartInfoOne',
|
||||
component: DepartInfoOne,
|
||||
meta: {
|
||||
title: '入司基本信息one'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'Two',
|
||||
name: 'DepartInfoTwo',
|
||||
component: DepartInfoTwo,
|
||||
meta: {
|
||||
title: '入司基本信息'
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
@@ -4,7 +4,6 @@ import sale from './sale'
|
||||
import customer from './customer'
|
||||
import my from './my'
|
||||
import serve from './serve'
|
||||
|
||||
import common from './common'
|
||||
import product from './product'
|
||||
import Department from './Department'
|
||||
|
||||
23
src/views/ebiz/Department/DepartInfo.vue
Normal file
23
src/views/ebiz/Department/DepartInfo.vue
Normal file
@@ -0,0 +1,23 @@
|
||||
<template>
|
||||
<div>
|
||||
<van-notice-bar color="#1989fa" background="#ecf9ff" wrapable :scrollable="false">
|
||||
<van-icon name="info-o" class="v-middle" />
|
||||
个险营销员需如实填写下列各项内容及真实提供简历、学历证明、身份证等材料。如有不实,后果自负。
|
||||
</van-notice-bar>
|
||||
<RouterView />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { NoticeBar, Icon } from 'vant'
|
||||
export default {
|
||||
name: 'DepartInfo',
|
||||
data() {
|
||||
return {}
|
||||
},
|
||||
components: {
|
||||
[NoticeBar.name]: NoticeBar,
|
||||
[Icon.name]: Icon
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped></style>
|
||||
323
src/views/ebiz/Department/DepartInfoOne.vue
Normal file
323
src/views/ebiz/Department/DepartInfoOne.vue
Normal file
@@ -0,0 +1,323 @@
|
||||
<template>
|
||||
<div class="insured-info-container pb50">
|
||||
<!-- 基本信息 -->
|
||||
<van-cell-group class="mt10">
|
||||
<p style="border-bottom: 1px solid #ebedf0" class="fs15 fwb pl10 pv12">基本信息</p>
|
||||
<van-field v-model="userInfo.name" label="姓名" name="姓名" v-validate="'required'" clearable />
|
||||
<van-field
|
||||
:value="userInfo.idType | idToText('rsIdType')"
|
||||
v-validate="'required'"
|
||||
readonly
|
||||
label="证件类型"
|
||||
name="证件类型"
|
||||
right-icon="arrow"
|
||||
placeholder="请选择"
|
||||
@click="toSelect('1')"
|
||||
/>
|
||||
<van-field v-model="userInfo.idNo" maxlength="18" label="证件号码" name="证件号码" placeholder="请输入" clearable @blur="getRelatedData(userInfo.idNo)">
|
||||
<!-- <van-button v-if="userInfo.idType == 1" slot="button" size="small" type="danger" round @click="selectClick('3')">证件扫描</van-button> -->
|
||||
</van-field>
|
||||
|
||||
<select-radio :radios="sexRadio" label="性别" name="性别" v-validate="'required'" :required="false" :value.sync="userInfo.sex"></select-radio>
|
||||
<FieldDatePicter
|
||||
v-validate="'required'"
|
||||
label="出生日期"
|
||||
name="出生日期"
|
||||
:value.sync="userInfo.birthday"
|
||||
type="date"
|
||||
:flag="true"
|
||||
@confirm="onDateConfirm($event, '2')"
|
||||
ref="birthday"
|
||||
:maxDate="maxDate"
|
||||
></FieldDatePicter>
|
||||
<!-- +++++++++++++++++++ -->
|
||||
<van-field v-model="userInfo.age" label="年龄" name="年龄" v-validate="'required'" clearable />
|
||||
<!-- ++++++++++++++++++++++ -->
|
||||
<van-field
|
||||
:value="userInfo.nativeplace | idToText('nationType')"
|
||||
readonly
|
||||
label="民族"
|
||||
name="民族"
|
||||
v-validate="'required'"
|
||||
right-icon="arrow"
|
||||
placeholder="请选择"
|
||||
@click="toSelect('2')"
|
||||
/>
|
||||
|
||||
<!-- ++++++++++++原户籍 -->
|
||||
<van-field
|
||||
:value="census"
|
||||
readonly
|
||||
label="户口所在地"
|
||||
name="户口所在地"
|
||||
v-validate="'required'"
|
||||
right-icon="arrow"
|
||||
placeholder="请选择"
|
||||
@click="censusShow = true"
|
||||
/>
|
||||
<!-- ++++++++++新加 -->
|
||||
<van-field
|
||||
:value="userInfo.healthCondition | idToText('healthCondition')"
|
||||
readonly
|
||||
label="健康状况"
|
||||
name="健康状况"
|
||||
right-icon="arrow"
|
||||
placeholder="请选择"
|
||||
v-validate="'required'"
|
||||
@click="toSelect('3')"
|
||||
/>
|
||||
<van-field
|
||||
:value="userInfo.marriage | idToText('marriage')"
|
||||
readonly
|
||||
label="婚姻状况"
|
||||
name="婚姻状况"
|
||||
right-icon="arrow"
|
||||
placeholder="请选择"
|
||||
v-validate="'required'"
|
||||
@click="toSelect('4')"
|
||||
/>
|
||||
<!-- 新加++++++++++++++++++++ -->
|
||||
<van-field
|
||||
:value="userInfo.politicsStatus | idToText('politicsStatus')"
|
||||
readonly
|
||||
label="政治面貌"
|
||||
name="政治面貌"
|
||||
right-icon="arrow"
|
||||
placeholder="请选择"
|
||||
v-validate="'required'"
|
||||
@click="toSelect('5')"
|
||||
/>
|
||||
<!--++++++++++ 原文化程度 -->
|
||||
<van-field
|
||||
:value="userInfo.degree | idToText('degree')"
|
||||
readonly
|
||||
label="学历"
|
||||
name="学历"
|
||||
right-icon="arrow"
|
||||
placeholder="请选择"
|
||||
v-validate="'required'"
|
||||
@click="toSelect('6')"
|
||||
/>
|
||||
<!-- +++++++++++++++++ -->
|
||||
<van-field v-model="userInfo.name" placeholder="请输入" label="毕业院校" name="毕业院校" v-validate="'required'" clearable />
|
||||
<!-- +++++++++++++++++ -->
|
||||
<van-field v-model="userInfo.name" label="所学专业" placeholder="请输入" name="所学专业" v-validate="'required'" clearable />
|
||||
<van-field v-model="userInfo.name" label="宅电" placeholder="请输入" name="宅电" v-validate="'required'" clearable />
|
||||
<van-field v-model="userInfo.name" label="手机" placeholder="请输入" name="手机" v-validate="'required'" clearable />
|
||||
|
||||
<van-field v-model="userInfo.email" label="电子邮箱" name="电子邮箱" placeholder="请输入" v-validate="'required|email'" clearable />
|
||||
|
||||
<van-field v-model="userInfo.email" label="电子邮箱" type="textarea" name="电子邮箱" placeholder="请输入" v-validate="'required|email'" clearable />
|
||||
</van-cell-group>
|
||||
|
||||
<van-cell-group :border="false">
|
||||
<p style=" border-bottom: 1px solid #ebedf0" class="fs15 fwb pl10 mt10 pv12">推荐人信息</p>
|
||||
<van-field class="referrerW" v-model="userInfo.email" label="推荐人编号" name="推荐人编号" placeholder="请输入" readonly />
|
||||
<van-field class="referrerW" v-model="userInfo.email" label="推荐人姓名" name="推荐人姓名" placeholder="请输入" readonly />
|
||||
<van-field class="referrerW" v-model="userInfo.email" label="营业组主管代码" name="营业组主管代码" placeholder="请输入" readonly />
|
||||
<van-field class="referrerW" v-model="userInfo.email" label="营业组主管姓名" name="营业组主管姓名" placeholder="请输入" readonly />
|
||||
<van-field class="referrerW" v-model="userInfo.email" label="营业处经理代码" name="营业处经理代码" placeholder="请输入" readonly />
|
||||
<van-field class="referrerW" v-model="userInfo.email" label="营业处经理姓名" name="营业处经理姓名" placeholder="请输入" readonly />
|
||||
<van-field class="referrerW" v-model="userInfo.email" label=" 营业区经理代码" name=" 营业区经理代码" placeholder="请输入" readonly />
|
||||
<van-field class="referrerW" v-model="userInfo.email" label="营业区经理姓名" name="营业区经理姓名" placeholder="请输入" readonly />
|
||||
</van-cell-group>
|
||||
|
||||
<!-- DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD -->
|
||||
|
||||
<!-- <van-button type="danger" class="bottom-btn" @click="nextStep" v-no-more-click="1000">下一步</van-button> -->
|
||||
|
||||
<!-- 字段选择 -->
|
||||
<van-popup v-model="popupShow" position="bottom">
|
||||
<van-picker show-toolbar :columns="columns" @confirm="onConfirm" @cancel="popupShow = false" />
|
||||
</van-popup>
|
||||
|
||||
<!-- 户籍选择 -->
|
||||
<van-popup v-model="censusShow" position="bottom">
|
||||
<van-area :area-list="areaList" value="110101" :columns-num="2" @confirm="sureArea($event, '3')" @cancel="censusShow = false" />
|
||||
</van-popup>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { Field, CellGroup, Checkbox, Popup, Picker, Area, RadioGroup, Radio } from 'vant'
|
||||
import SelectRadio from '@/components/ebiz/SelectRadio'
|
||||
import FieldDatePicter from '@/components/ebiz/FieldDatePicter'
|
||||
import OccupationPicker from '@/components/ebiz/occipation/OccupationPicker'
|
||||
import CustomerPicker from '@/components/ebiz/customer/CustomerPicker'
|
||||
import DataDictionary from '@/assets/js/utils/data-dictionary'
|
||||
import areaList from '@/assets/js/utils/area'
|
||||
import { saveOrUpdateOrderInfo, getAuthCode, getOrderDetail } from '@/api/ebiz/sale/sale'
|
||||
import utilsAge from '@/assets/js/utils/age'
|
||||
import getAreaName from '@/assets/js/utils/get-area-name'
|
||||
import IdentityCardScan from '@/components/ebiz/sale/IdentityCardScan'
|
||||
import idNoCheck from '@/assets/js/utils/idNoCheck'
|
||||
import beforeDate from '@/assets/js/utils/getBeforeDate.js'
|
||||
import { idToData } from './js/verification'
|
||||
// import { selectComp } from './js/methods'
|
||||
import Vue from 'vue'
|
||||
export default {
|
||||
name: 'insuredInfo',
|
||||
components: {
|
||||
[SelectRadio.name]: SelectRadio,
|
||||
[FieldDatePicter.name]: FieldDatePicter,
|
||||
[OccupationPicker.name]: OccupationPicker,
|
||||
[CustomerPicker.name]: CustomerPicker,
|
||||
[Field.name]: Field,
|
||||
[CellGroup.name]: CellGroup,
|
||||
[Checkbox.name]: Checkbox,
|
||||
[Popup.name]: Popup,
|
||||
[Picker.name]: Picker,
|
||||
[Area.name]: Area,
|
||||
[RadioGroup.name]: RadioGroup,
|
||||
[Radio.name]: Radio,
|
||||
[IdentityCardScan.name]: IdentityCardScan
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
sexRadio: [
|
||||
{
|
||||
label: '男',
|
||||
value: '0'
|
||||
},
|
||||
{
|
||||
label: '女',
|
||||
value: '1'
|
||||
}
|
||||
],
|
||||
maxDate: beforeDate.getBeforeYear(18),
|
||||
popupShow: false,
|
||||
censusShow: false, //户籍联动
|
||||
pickerType: undefined,
|
||||
columns: [],
|
||||
valueKey: 'text',
|
||||
census: '', //户籍
|
||||
|
||||
userInfo: {
|
||||
name: '', //投保人姓名
|
||||
sex: '0', //投保人性别
|
||||
nativeplace: '1', //国家地区
|
||||
birthday: '',
|
||||
idType: '1', //证件类型
|
||||
idNo: '', //证件号码
|
||||
age: '', //年龄
|
||||
politicsStatus: '', //政治面貌
|
||||
|
||||
healthCondition: '', //健康状况
|
||||
|
||||
mobile: '', //移动电话
|
||||
|
||||
degree: '', //文化程度
|
||||
|
||||
marriage: '', //婚姻状况
|
||||
|
||||
householdProvince: '', //户籍省
|
||||
householdCity: '' //户籍市
|
||||
},
|
||||
areaList: areaList
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
//弹框选择
|
||||
toSelect(pickerType, valueKey) {
|
||||
//pickerType 1、证件类型 2、民族 3、健康状况 4 婚姻状况 5 政治面貌
|
||||
;[this.popupShow, this.pickerType] = [true, pickerType]
|
||||
if (valueKey) this.valueKey = valueKey
|
||||
if (pickerType == '1') {
|
||||
this.columns = DataDictionary.rsIdType
|
||||
} else if (pickerType == '2') {
|
||||
this.columns = DataDictionary.nationType
|
||||
} else if (pickerType == '3') {
|
||||
this.columns = DataDictionary.healthCondition
|
||||
} else if (pickerType == '4') {
|
||||
this.columns = DataDictionary.marriage
|
||||
} else if (pickerType == '5') {
|
||||
this.columns = DataDictionary.politicsStatus
|
||||
} else if (pickerType == '6') {
|
||||
this.columns = DataDictionary.degree
|
||||
} else if (pickerType == '7') {
|
||||
this.columns = DataDictionary.workCondition
|
||||
} else if (pickerType == '8') {
|
||||
this.columns = DataDictionary.salarySource
|
||||
}
|
||||
},
|
||||
// //确认选择字段
|
||||
onConfirm(value) {
|
||||
this.popupShow = false
|
||||
|
||||
if (this.pickerType == '1') {
|
||||
this.userInfo.idType = value.id
|
||||
} else if (this.pickerType == '2') {
|
||||
this.userInfo.nativeplace = value.id
|
||||
} else if (this.pickerType == '3') {
|
||||
this.userInfo.healthCondition = value.id
|
||||
} else if (this.pickerType == '4') {
|
||||
this.userInfo.marriage = value.id
|
||||
} else if (this.pickerType == '5') {
|
||||
this.userInfo.politicsStatus = value.id
|
||||
} else if (this.pickerType == '6') {
|
||||
this.userInfo.degree = value.id
|
||||
} else if (this.pickerType == '7') {
|
||||
this.userInfo.jobStatus = value.id
|
||||
} else if (this.pickerType == '8') {
|
||||
this.userInfo.salarySource = value.id
|
||||
}
|
||||
},
|
||||
//
|
||||
onDateConfirm(val, type) {
|
||||
// 2 出生日期
|
||||
switch (type) {
|
||||
case '2':
|
||||
{
|
||||
//出生日期
|
||||
//如果录入日期晚于当前日期
|
||||
if (Date.parse(val) > Date.parse(new Date())) {
|
||||
this.userInfo.birthday = ''
|
||||
this.$refs.birthday.date = ''
|
||||
return this.$toast('出生日期不晚于当日')
|
||||
}
|
||||
//长判断
|
||||
if (this.userInfo.idType == '1') {
|
||||
let age = utilsAge.getAge(this.userInfo.birthday, new Date())
|
||||
// this.effectiveDateTypeAble = !(age >= 45)
|
||||
}
|
||||
}
|
||||
break
|
||||
}
|
||||
},
|
||||
//区域选择
|
||||
sureArea(area, type) {
|
||||
switch (type) {
|
||||
case '3': //户籍
|
||||
this.census = getAreaName(area)
|
||||
;[this.userInfo.householdProvince, this.userInfo.householdCity] = [area[0].code, area[1].code]
|
||||
this.censusShow = false
|
||||
break
|
||||
}
|
||||
},
|
||||
getRelatedData(val) {
|
||||
if (this.userInfo.idType != '1') {
|
||||
return
|
||||
}
|
||||
//如果证件校验不通过,恢复默认值
|
||||
if (idToData(val).text) {
|
||||
;[this.userInfo.idNo, this.userInfo.sex, this.userInfo.birthday, this.effectiveDateTypeAble] = ['', '0', '', false]
|
||||
return this.$toast(idToData(val).text)
|
||||
}
|
||||
this.userInfo.effectiveDateType = false
|
||||
this.effectiveDateTypeAble = idToData(val).age < 45
|
||||
this.userInfo.birthday = idToData(val).birthday
|
||||
this.userInfo.sex = idToData(val).sex
|
||||
this.userInfo.age = utilsAge.getAge(this.userInfo.birthday, new Date())
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.insured-info-container {
|
||||
.referrerW {
|
||||
/deep/.van-cell__title {
|
||||
width: 110px;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
51
src/views/ebiz/Department/DepartInfoTwo.vue
Normal file
51
src/views/ebiz/Department/DepartInfoTwo.vue
Normal file
@@ -0,0 +1,51 @@
|
||||
<template>
|
||||
<div class="insured-info-container pb50">
|
||||
<!-- 基本信息 -->
|
||||
<van-cell-group class="mt10">
|
||||
<p style="border-bottom: 1px solid #ebedf0" class="fs15 fwb pl10 pv12">教育经历(高中起)</p>
|
||||
<FieldDatePicter v-validate="'required'" label="开始时间" name="开始时间" type="date" :flag="true" ref="birthday"></FieldDatePicter>
|
||||
<FieldDatePicter v-validate="'required'" label="截至时间" name="截至时间" type="date" :flag="true" ref="birthday"></FieldDatePicter>
|
||||
<van-field label="学校名称" type="text" name="学校名称" placeholder="请输入" v-validate="'required|email'" clearable />
|
||||
|
||||
<van-field label="专业" type="text" name="专业" placeholder="请输入" v-validate="'required|email'" clearable />
|
||||
<van-field label="所获奖励" type="text" name="所获奖励" placeholder="请输入" v-validate="'required|email'" clearable />
|
||||
</van-cell-group>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { Field, CellGroup, Checkbox, Popup, Picker, Area, RadioGroup, Radio } from 'vant'
|
||||
import FieldDatePicter from '@/components/ebiz/FieldDatePicter'
|
||||
import Vue from 'vue'
|
||||
export default {
|
||||
name: 'DepartInfoTwo',
|
||||
components: {
|
||||
[FieldDatePicter.name]: FieldDatePicter,
|
||||
[Field.name]: Field,
|
||||
[CellGroup.name]: CellGroup,
|
||||
[Checkbox.name]: Checkbox,
|
||||
[Popup.name]: Popup,
|
||||
[Picker.name]: Picker,
|
||||
[Area.name]: Area,
|
||||
[RadioGroup.name]: RadioGroup,
|
||||
[Radio.name]: Radio
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
userInfo: [{ start: '', end: '' }]
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
//弹框选择
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.insured-info-container {
|
||||
.referrerW {
|
||||
/deep/.van-cell__title {
|
||||
width: 110px;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
52
src/views/ebiz/Department/js/verification.js
Normal file
52
src/views/ebiz/Department/js/verification.js
Normal file
@@ -0,0 +1,52 @@
|
||||
import changeFifteenToEighteen from '@/assets/js/utils/changeFifteenToEighteen'
|
||||
import idNoCheck from '@/assets/js/utils/idNoCheck'
|
||||
import utilsAge from '@/assets/js/utils/age'
|
||||
|
||||
//身份证带出出生日期,性别,年龄
|
||||
export function idToData(idNo) {
|
||||
//非空
|
||||
if (!idNo.trim()) {
|
||||
return {
|
||||
text: '证件号码不能为空'
|
||||
}
|
||||
}
|
||||
|
||||
// 证件号码规则校验
|
||||
if (!idNoCheck.isIdno(idNo)) {
|
||||
return {
|
||||
text: '您填写的证件号码有误'
|
||||
}
|
||||
}
|
||||
|
||||
//如果是15位身份证号先转为18位
|
||||
if (idNo.length == 15) {
|
||||
idNo = changeFifteenToEighteen(idNo)
|
||||
}
|
||||
let birthday = getBirthById(idNo)
|
||||
let age = utilsAge.getAge(birthday, new Date())
|
||||
let sex = getSexById(idNo)
|
||||
return {
|
||||
birthday,
|
||||
age,
|
||||
sex
|
||||
}
|
||||
}
|
||||
|
||||
function getBirthById(idNo) {
|
||||
// 获取生日
|
||||
var year = idNo.substr(6, 4)
|
||||
var month = idNo.substr(10, 2)
|
||||
var day = idNo.substr(12, 2)
|
||||
return year + '-' + month + '-' + day
|
||||
}
|
||||
|
||||
function getSexById(idNo) {
|
||||
// 获取性别
|
||||
if (idNo.charAt(16) >= '0' && idNo.charAt(16) <= '9') {
|
||||
if (parseInt(idNo.charAt(16)) % 2 == 0) {
|
||||
return '1'
|
||||
} else {
|
||||
return '0'
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -497,6 +497,7 @@ export default {
|
||||
},
|
||||
//弹框选择
|
||||
toSelect(pickerType, valueKey) {
|
||||
console.log(valueKey)
|
||||
//pickerType 1、国家地区 2、证件类型 3、文化程度 4、有无社保(弃用) 5、税收居民身份 6、婚姻状况 7、在职情况 8、收入来源
|
||||
;[this.popupShow, this.pickerType] = [true, pickerType]
|
||||
if (valueKey) this.valueKey = valueKey
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<van-button icon="photo" @click="facetoface" class="mt12" type="primary">人脸识别</van-button>
|
||||
<br />
|
||||
<!-- <UploadImageFile @sendimage="sendimage"></UploadImageFile> -->
|
||||
<div>
|
||||
<div class="value">
|
||||
{{ value }}
|
||||
</div>
|
||||
|
||||
@@ -379,3 +379,8 @@ export default {
|
||||
// }
|
||||
}
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.value {
|
||||
word-wrap: break-word;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user