<template>
	<view class="successful-page">
		<view class="banner-image">
			<image src="https://catmdogf.oss-cn-shanghai.aliyuncs.com/CMDF/front/petServiceOrder/TopDetail.png" mode="widthFix" style="width: 100%;"></image>
		</view>
		
		<view class="content-card">
			<view class="card-item">
				<view class="item-icon">
					<image src="/pages_order/static/order/f.png" mode="aspectFit" :show-menu-by-longpress="true"></image>
				</view>
				<view class="item-text">
					<text class="item-title">请及时添加服务顾问的企业微信</text>
					
                    <view class="code">
                        <image src="https://catmdogf.oss-cn-shanghai.aliyuncs.com/CMDF/front/details/QR_Code.png" 
                        mode="aspectFit"
                        style="width: 260rpx; height:260rpx"/>
                    </view>

				</view>
			</view>
			
			<view class="card-item">
				<view class="item-icon">
					<image src="/pages_order/static/order/f.png" mode="aspectFit"></image>
				</view>
				<view class="item-text">
					<text class="item-title">完善服务档案</text>
					<text class="item-desc">请上传宠物喂养要求及用品摆放位置</text>
				</view>
				<view class="item-action">
					<text class="action-btn">去完善</text>
				</view>
			</view>
			
			<view class="card-item">
				<view class="item-icon">
					<image src="/pages_order/static/order/f.png" mode="aspectFit"></image>
				</view>
				<view class="item-text">
					<text class="item-title">完善门锁信息</text>
					<text class="item-desc">请上传门锁及相应密码要求</text>
				</view>
				<view class="item-action">
					<text class="action-btn">去完善</text>
				</view>
			</view>
		</view>
		
		<view class="back-home">
			<button class="details-btn" @click="goHome">返回首页</button>
		</view>
		<Kefu></Kefu>
	</view>
</template>

<script>
	import Kefu from '@/pages/common/kefu.vue'
	export default {
		data() {
			return {

			};
		},
		components:{
			Kefu
		},
		methods: {
			goHome() {
				this.$globalData.itemPrice=[]
				this.$globalData.submitData = {}
				this.$globalData.newOrderData={
						currentAddress:{},
						currentPets:[],
						totalPrice:0,
						needPreFamiliarize:[]
					}
				// 清空页面栈
				uni.reLaunch({
					url: "/pages/index"
				});
			},
		}
	}
</script>

<style lang="scss" scoped>
	.successful-page {
		position: relative;
		height: 100vh;
        padding: 20rpx;
		padding-bottom: 58px;
		background-color: #f5f5f5;
		
		.banner-image {
			width: 100%;
			background-color: #FFFFFF;
		}
		
		.content-card {
			
			.card-item {
				display: flex;
				align-items: center;
				padding: 30rpx 20rpx;
                margin: 20rpx;
                background-color: #FFFFFF;
                border-radius: 20rpx;
                position: relative;

				&::after {
					position: absolute;
					content: '';
					left: 40rpx;
					top: 62rpx;
					width: 40rpx;
					height: 40rpx;
                    border-radius: 50%;
					background-color: #FFB13Faa;
				}

                &:first-child {
                    .item-text {
                        display: flex;
                        flex-direction: column;
                        justify-content: center;;
                        align-items: center;
                        .item-title {
                            font-size: 28rpx;
                            color: #333;
                            font-weight: bold;
                            display: block;
                        }
                        
                        .code {
                            padding: 20rpx 0;
                        }
                    }
                	&::after {
                        top: 190rpx;
                    }
                }
				
				&:last-child {
					border-bottom: none;
				}
				
				.item-icon {
					width: 60rpx;
					height: 60rpx;
					margin-right: 20rpx;
                    position: relative;
                    z-index: 2;
					
					image {
						width: 100%;
						height: 100%;
					}
				}
				
				.item-text {
					flex: 1;
					line-height: 50rpx;
					.item-title {
						font-size: 28rpx;
						color: #333;
						font-weight: bold;
						display: block;
					}
					
					.item-desc {
						font-size: 24rpx;
						color: #999;
						display: block;
						margin-top: 6rpx;
					}
				}
				
				.item-action {
					.action-btn {
						padding: 16rpx 30rpx;
						background-color: #FFB13F;
						color: #FFFFFF;
						border-radius: 30rpx;
						font-size: 24rpx;
					}
				}
			}
		}
		
		.back-home {
			height: 116rpx;
			position: fixed;
			bottom: 0;
			width: calc(100% - 40rpx);
			display: flex;
			justify-content: center;
			align-items: center;
			
			.details-btn {
				width: 90%;
				border-radius: 40rpx;
				background: #FFB13F;
				font-size: 32rpx;
				color: #FFFFFF;
			}
		}
	}
</style>
