<template>
	<view class="container">
		<Navbar title="认证中心" canBack bgColor="#ff630c" textColor="#fff" leftIconColor="#fff"></Navbar>
		<view class="warp flex justify-between  align-center padding-lr" style="padding-top: 100rpx;">
			<view class="flex flex-direction">
				<view class="text-bold" style="font-size: 32px;">
					实名认证中心
				</view>
				<view class="text-gray margin-top-sm">
					完成认证，订气无需再次采集
				</view>
			</view>
			<view class="align-end">
				<u-image src="@/static/images/gas-icon/authicon.png" width="277rpx" height="209rpx"
					mode="widthFix"></u-image>
			</view>
		</view>
		<!-- 居民身份认证 -->
		<view class="usuallyCard margin flex justify-between align-center padding" @click="handleToAuth(0)">
			<view class="flex">
				<view class=""><u-image src="" width="80rpx" height="80rpx" shape="circle"></u-image></view>
				<view class="margin-left">
					<view class="text-xl text-bold">居民身份认证</view>
					<view class="text-gray text-lg">二代身份证认证</view>
				</view>
			</view>
			<view class=""><u-icon name="arrow-right" color="#000"></u-icon></view>
		</view>
		<!-- 非居民身份认证 -->
		<view class="usuallyCard margin flex justify-between align-center padding" @click="handleToAuth(1)">
			<view class="flex">
				<view class=""><u-image src="" width="80rpx" height="80rpx" shape="circle"></u-image></view>
				<view class="margin-left">
					<view class="text-xl text-bold">非居民身份认证</view>
					<view class="text-gray text-lg">二代身份证认证&企业营业资质</view>
				</view>
			</view>
			<view class=""><u-icon name="arrow-right" color="#000"></u-icon></view>
		</view>
		<view class="padding-lr text-gray">
			根据《中华人民共和国住房和城乡建设部》等相关要求，为了更
			好的提供订气服务，需您提供真实的身份信息。我司承诺将根据
			《隐私政策》约定保护您提供的身份信息。后续您本人订气时仅
			需出示有效身份证件供查阅确认即可，无需再次采集。
		</view>
	</view>
</template>

<script>
	import basisCellCard from '@/components/basisCellCard/basisCellCard'
	export default {
		components: {
			basisCellCard
		},
    onLoad(routeData){
      console.log('打印options',routeData)
      if(routeData.option){
        this.options = JSON.parse(routeData.option);
      }
		  if(routeData && routeData.mode){
		    this.handleToAuth(routeData.mode);
      }
    },
		data() {
			return {
			  options:{}
      };
		},
		methods: {
			handleToAuth(mode) {
				uni.navigateTo({
					url: `/pages/mine/appList/realNameAuth/realNameAuthentication?mode=${mode}&option=${JSON.stringify(this.options)}`
				})
			}
		}
	}
</script>

<style lang="scss">
	.container {
		padding-bottom: 10px;

		.warp {
			height: 420rpx;
			background-image: linear-gradient(-180deg, #ff630c 0%, #f2f4f3 100%);
			box-sizing: border-box;
		}
	}
</style>