policy-change-information.vue 6.92 KB

<template>
	<div>
		<auth @onLogin="userLogin" @onLogout="userLogout" :checkProfile="true" ref="auth" :tipModel="'m2'"></auth>
		<modal-upload-card-comp :visible="modalUploadCardVisiable" :show-confirm="true" @close="modalUploadCardVisiable=false" @onSubmit="handleUpdatePolicyWithFile" ></modal-upload-card-comp>
    	<modal-comp :visible="modalVisiable" :show-confirm="false" :icon="modalIcon" :content="modalContent" :confirm="modalCallback" :overlay="modalCallback"></modal-comp>
		<template v-if="showForm">

			<div class="pure-u-1 form-item form-item2">
				<div class="label">
					{{$t('policyChangeInformation.obj')}}
				</div>
				<div class="cont">
					<div class="boo-btn pointer" :class="{active:isOwner}" @click="switchPolicyRole(1)">{{$t('policyChangeInformation.owner')}}</div>
					<div class="boo-btn pointer" :class="{active:!isOwner}" @click="switchPolicyRole(2)">{{$t('policyChangeInformation.insured')}}</div>
				</div>
			</div>

			<policy-head-list :multiSelectable="isOwner" @onSelect="handlePolicySelect" :model="'checkbox'"></policy-head-list>
			<div class="container border" v-if="selectedPolicies.length > 0 && data">
				<div class="table">
					<div class="table-header orange">
						<div class="table-header-item">{{$t('policyChangeInformation.title')}}</div>
					</div>
					<div class="gird-g form">
						<!-- 1 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label">
								<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-info.png"></div> {{$t('policyChangeInformation.name')}}
							</div>
							<div class="ipt-wrap">
								<input class="ipt" type="text" v-model="data.name">
							</div>
						</div>

						<!-- 2 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label label2">
								<div class="fla">
									<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-info.png"></div>{{$t('policyChangeInformation.sex')}}
								</div>
								<div class="fla">
									<div class="icon icon2"><img src="@/assets/images/policy-change-information/icon-pci-notice.png"></div>
									<span class="t1">{{$t('policyChangeInformation.modifyTips1')}}</span>&nbsp;
									<span class="t2" @click="toContactUs()">{{$t('policyChangeInformation.modifyTips2')}}</span>
								</div>
							</div>
							<div class="ipt-wrap">
								<div class="down-arrow"></div>

								<select disabled class="ipt disable" v-model="data.sex">
								<template v-if="sexCandidates">
									<option v-for="(item,index) in sexCandidates" :key="index" :value="item.value">{{item.name}}</option>
								</template>
								</select>
							</div>
						</div>

						<!-- 3 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label label2">
								<div class="fla">
									<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-date.png"></div>{{$t('policyChangeInformation.birth')}}
								</div>
								<div class="fla">
									<div class="icon icon2"><img src="@/assets/images/policy-change-information/icon-pci-notice.png"></div>
									<span class="t1">{{$t('policyChangeInformation.modifyTips1')}}</span>&nbsp;
									<span class="t2" @click="toContactUs()">{{$t('policyChangeInformation.modifyTips2')}}</span>
								</div>
							</div>
							<div class="ipt-wrap">
								<input disabled class="ipt disable" type="text" v-model="data.birthday">
							</div>
						</div>

						<!-- 4 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label">
								<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-card.png"></div>{{$t('policyChangeInformation.type')}}
							</div>
							<div class="ipt-wrap">
								<div class="down-arrow"></div>
								<select class="ipt" v-model="data.idType">
									<option v-for="(item,index) in policyIdTypeList" :key="index" :value="item.v">{{item.n}}</option>
								</select>
							</div>
						</div>

						<!-- 5 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label">
								<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-card.png"></div> {{$t('policyChangeInformation.NO')}}
							</div>
							<div class="ipt-wrap">
								<!-- <div class="eye"></div> -->
								<!--  -->
								<!-- <div class="eye eye-act"></div> -->
								<input class="ipt" type="text" v-model="data.idNumber">
							</div>
						</div>

						<!-- 6 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label">
								<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-card.png"></div> {{$t('policyChangeInformation.validityPeriod')}}
							</div>
							<div class="ipt-wrap">
								<!-- <date-picker class="date" v-model="data.idExpireAt" :filtModel="['history', 'today']"></date-picker> -->
								<input disabled class="ipt disable" type="text" value="-">
							</div>
						</div>

						<!-- 7 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label">
								<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-earth.png"></div> {{$t('policyChangeInformation.nationality')}}
							</div>
							<div class="ipt-wrap">
								<!-- <input class="ipt" type="text" v-model="data.nature"> -->

								<div class="down-arrow"></div>
								<select class="ipt" v-model="data.nature">
									<option v-for="(item,index) in nationList" :key="index" :value="item.v">{{item.n}}</option>
								</select>
							</div>
						</div>

						<!-- 8 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label">
								<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-build.png"></div> {{$t('policyChangeInformation.employer')}}
							</div>
							<div class="ipt-wrap">
								<input class="ipt" type="text" v-model="data.company">
							</div>
						</div>

						<!-- 9 -->
						<div class="pure-u-1 pure-u-md-1-2 form-item">
							<div class="label">
								<div class="icon"><img src="@/assets/images/policy-change-information/icon-pci-love.png"></div> {{$t('policyChangeInformation.maritalStatus')}}
							</div>
							<div class="ipt-wrap">
								<div class="down-arrow"></div>

								<!-- <input class="ipt" type="text" v-model="data.marriage"> -->
								<select class="ipt" v-model="data.marriage">
									<option v-for="(item,index) in marryList" :key="index" :value="item.v">{{item.n}}</option>
								</select>
							</div>
						</div>

						<div class="pure-u-1 pure-u-md-1-2 form-item"></div>

					</div>

					<div class="submit-btn flex-center" @click="handleUpdatePolicy">
						<van-loading v-if="loading" />
						<span>{{$t('policyChangeInformation.submit')}}</span>
					</div>
				</div>
			</div>
			<!-- <div v-else style="height:400px"></div> -->
		</template>
	</div>

</template>

<script src="./policy-change-information.js"></script>
<style lang="scss" scoped>
@import "./policy-change-information.scss";
</style>