<template>
	<view class="bagStorageSuccess">
		<view class="top">
			<navigation-bar-view ref="nav" :maxTimer="60"></navigation-bar-view>
			<view class="icon-box">
				<image class="icon" :src="require('../../static/images/icon-success.png')"></image>
				<view class="label">下单成功</view>
			</view>
			<view class="hint">{{options.remind}}</view>
		</view>
		<!-- <view class="bottom">
			<view class="label-box">常见问题：</view>
			<scroll-view scroll-y style="height: 39.9vh;">
				<block v-for="(item, i) in faq" :key="i">
					<view class="item">
						<view class="label">{{i + 1}}、{{item.title}}</view>
						<view class="message">{{item.content}}</view>
					</view>
				</block>
				<view style="height: 5vw;"></view>
			</scroll-view>
		</view> -->
	</view>
</template>

<script>
	import navigationBarView from '../../components/navigationBarView.vue';
	export default {
		components: {
			navigationBarView,
		},

		data() {
			return {
				faq: [],
				options: {}
			}
		},

		onLoad(options) {
			this.options = options
			this.getFaq();
		},
		
		onHide() {
			const $this = this;
			$this.$nextTick(function(){
				$this.$refs.nav.clearTimer();
			})
		},

		methods: {
			getFaq() {
				this.$api.commonHelpList({
					// type: 1
				}).then(res => {
					this.faq = res.data;
				})
			}
		}
	}
</script>

<style lang="scss">
	.bagStorageSuccess {
		min-height: 100vh;
		background-color: #F8F8F8;

		.top {
			padding-bottom: 10.4vw;
			background-color: #FFFFFF;

			.icon-box {
				display: flex;
				align-items: center;
				flex-direction: column;
				margin-top: 12.1vw;

				.icon {
					width: 18.8vw;
					height: 18.8vw;
				}

				.label {
					margin-top: 4.6vw;
					font-size: 4.5vw;
					line-height: 4.5vw;
				}
			}

			.hint {
				display: flex;
				align-items: center;
				justify-content: center;
				height: 12.1vw;
				border-radius: 12.1vw;
				background: linear-gradient(to right, #FEE704, #FDD001);
				margin: 9vw 7.3vw 0;
				font-size: 4.2vw;
			}
		}

		.bottom {
			.label-box {
				margin: 8.3vw 7.5vw 3vw;
				font-weight: bold;
				font-size: 4.3vw;
				line-height: 4.3vw;
			}
			
			.item {
				padding: 0 7.3vw 7.3vw;
				.label {
					font-size: 3.5vw;
				}
				
				.message {
					margin: 3vw 7.3vw 0;
					color: #888888;
					font-size: 3.2vw;
				}
			}
		}
	}
</style>
