<template>
	<view>
		<uni-notice-bar backgroundColor="#f2fded" color="#51c24e" single showIcon text="已发送电子邮箱"></uni-notice-bar>
		<uni-list>
			<uni-list-item title="发票预览" clickable showArrow @click="previewCell" />
		</uni-list>

		<uni-list>
			<view class="recordCon uni-list-cell-pd">
				<text class="color-black">发票信息</text>
			</view>
			<view class="recordCon uni-list-cell-pd">
				<text>电子邮箱：{{invoiceInfo.email}}</text>
			</view>
		</uni-list>

		<view class="bg-white border-bottom-1 pos-rel" @click="recordClick">
			<view class="recordCon uni-list-cell-pd">
				<text class="color-black">发票包含内容</text>
			</view>
			<view class="recordCon uni-list-cell-pd">
				<text>该发票包含{{invoiceInfo.number}}笔交易</text>
			</view>
			<view class="uni-icon pos-abs icon-arrowright uni-icon-arrowright">
			</view>
		</view>

		<view class="margin-top-30">
			<button type="primary" class="tel-btn">重发邮件</button>
			<button class="tel-btn" v-if="tel.length>0" type="primary" plain="true" @click="call">客服电话:{{tel}}</button>
		</view>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				invoiceInfo: {
					email: '123456@qq.com',
					number: 0
				},
				tel: '400-6345688'
			}
		},
		methods: {
			previewCell() {
				uni.navigateTo({
					url: '../invoicePreview/invoicePreview'

				});
			},
			recordClick() {
				uni.navigateTo({
					url: '../elecRecord/elecRecord'

				});
			},
		}
	}
</script>

<style lang="scss">
	.icon-arrowright {
		color: #bbb;
		font-size: 20px;
		right: 2upx;
		top: 60upx;
	}

	.tel-btn {
		width: 90%;
		margin: 30upx auto;
	}
</style>
