<template>
	<view class="UserAgreement">
		<view class="AgreementItem" @click="ToAgreement(1)">
			<van-icon name="question" />《服务协议》
		</view>
		<view class="AgreementItem" @click="ToAgreement(2)">
			<van-icon name="question" />《隐私权政策》
		</view>
		<view class="AgreementItem" @click="ToAgreement(3)">
			<van-icon name="question" />《未成年人个人信息保护规则》
		</view>
	</view>
</template>

<script>
	export default {
		name: "UserAgreement",
		data() {
			return {
				externalInfo: {
					seesionID: '',
					userID: '',
					AppID: ''
				}
			}
		},
		onLoad: function(options) {
			console.warn(options);
			this.externalInfo = options
		},
		methods: {
			// 跳转协议
			async ToAgreement(type) {
				try {
					uni.navigateTo({
						url: "../pdfPreview/pdfPreview?pdfName=" + this.externalInfo.AppID + '_' + type
					})
				} catch (e) {
					//TODO handle the exception
				}
			}
		}
	}
</script>

<style lang="scss">
	.UserAgreement {
		padding-top: 300rpx;
		margin-left: 150rpx;

		.AgreementItem {
			font-family: PingFang SC;
			font-size: 35rpx;
			letter-spacing: 1rpx;
			font-weight: 600;
			color: #34C98E;
			line-height: 100rpx;
		}
	}
</style>
