<template>
	<view class="approve_box">
		<view class="data">
			<view class="left">
				<image src="/static/other/approve.png" mode=""></image>
			</view>
			<view class="right">
				<view class="top">
					签约商家
				</view>
				<view class="bottom">
					sda 
				</view>
			</view>
		</view>
		<view class="data">
			<view class="left">
				<image src="/static/other/approve.png" mode=""></image>
			</view>
			<view class="right">
				<view class="top">
					实名认证已通过
				</view>
				<view class="bottom">
					所有商户签约入驻平台时，身份信息均已通过核验
				</view>
			</view>
		</view>
		<view class="data">
			<view class="left">
				<image src="/static/other/approve.png" mode=""></image>
			</view>
			<view class="right">
				<view class="top">
					健康证认证
				</view>
				<view class="bottom">
					该商户健康体检合格，并在平台已认证通过
				</view>
			</view>
		</view>
		<view class="data">
			<view class="left">
				<image src="/static/other/approve.png" mode=""></image>
			</view>
			<view class="right">
				<view class="top">
					该店铺已在平台完成市场主体登记认证
				</view>
				<view class="bottom">
					根据相关法律法规要求，经营者相关资质信息公示如下 
				</view>
			</view>
		</view>
		<view class="credential">
			<view class="title">
				所属商家资质
			</view>
			<view class="img">
				<image :src="$globalData.publicUrl + businessLicense" mode=""></image>
				<image src="/static/other/mask.png" mode="" class="mask"></image>
			</view>
		</view>
		<view class="credential">
			<view class="title">
				从业资格证书
			</view>
			<view class="img">
				<image :src="$globalData.publicUrl + certification" mode=""></image>
					<image src="/static/other/mask.png" mode="" class="mask"></image>
			</view>
		</view>
	</view>
</template>

<script>
	import {
		engineerDetails,
		addOrder,
		addCollect,
		cancleCollect
	} from '../../api/index.js'
	export default{
		data(){
			return{
				businessLicense:'',//营业执照
				certification:''//资格证
			}
		},
		methods:{
			getDetails(id) {
				const cId = {
					id: id,
					cOpenId: uni.getStorageSync('wx_copenid')
				}
				engineerDetails(cId).then(res => {
					this.businessLicense = res.data.data.businessLicense
					this.certification = res.data.data.certification
			// 		if (res.data.data) {
						
			// 			res.data.data.cImgList.forEach(item => {
			// 				this.swiper.push(this.public + item)
			// 			})
			// 			var prolist = res.data.data.projects
			// 			prolist.forEach(element => {
			// 				element.number = 0
			// 			});
			// 			this.details = res.data.data
			// 			this.projects = prolist
			// 			if (res.data.data.comments) {
			// 				this.comList = res.data.data.comments.slice(0,3)
			// 			} else {
			// 				this.comList = []
			// 			}
			
			// 		}
				})
			},
		},
		onLoad(options){
			this.getDetails(options.id)
		},
		onShow() {
			
		}
	}
</script>

<style lang="scss" scoped>
	.approve_box{
		width: 100vw;
		height: 100%;
		// overflow-y: auto;
		// background: radial-gradient(circle, #b1fffc, #fcfdff);
		background: linear-gradient(to bottom right, #fcfdff, #b1fffc);
		padding: 20rpx;
		box-sizing: border-box;
		overflow-y: auto;
		.data{
			width: 100%;
			height: 150rpx;
			background-color: #fff;
			border-radius: 16rpx;
			display: flex;
			align-items: center;
			padding: 20rpx;
			box-sizing: border-box;
			margin-bottom: 20rpx;
			.left{
				margin-right: 20rpx;
				image{
					width: 50rpx;
					height: 50rpx;
				}
			}
			.right{
				height: 80%;
				display: flex;
				flex-direction: column;
				justify-content: space-between;
				.top{
					font-size: 34rpx;
					font-weight: 700;
				}
				.bottom{
					font-size: 26rpx;
					color: #666;
				}
			}
		}
		.credential{
			width: 100%;
			height: auto;
			padding: 20rpx;
			box-sizing: border-box;
			background-color: #fff;
			border-radius: 16rpx;
			margin-bottom: 20rpx;
			.title{
				font-weight: 700;
			}
			.img{
				width: 100%;
				height: 200px;
				position: relative;
				margin-top: 10rpx;
				border-radius: 20rpx;
				overflow: hidden;
				image{
					width: 100%;
					height: 100%;
				}
				.mask{
					position: absolute;
					top: 0;
					left: 0;
				}
			}
		}
	}
</style>