<template>
	<view class="wrap">
		<view class="fuwu_wrap"></view>
		<view class="footer">
		   <view class="submit1" @tap="toShop">放弃认证</view>
		   <view class="submit" @tap="to_attestation">立即认证</view>
		</view>
		<view :class="['discount_mask',isMask == 1?'showMask':'']">
			<view class="discount_mask_wrap">
				<image @tap="close" src="http://web.jzdsh.com/images/discount_mask.png"></image>
				<view class="cancel" @tap="close">
					<view class="iconfont header_close"></view>
				</view>
				<view class="discount_mask_title">{{title}}</view>
				<view class="discount_mask_time">{{time}}</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				isMask:1,//优惠券弹框是否显示
				title:'',//优惠券描述
				time:'',//优惠券有效期
				code:'',//优惠券状态
				id:'',//店铺id
			}
		},
		onLoad(options) {
			console.log(options);
			this.title = options.money;
			this.time = options.time;
			this.code = options.code;
			this.id = options.id;
			if(options.code == 202){
				this.isMask = 0;
			}
		},
		methods: {
			//点击关闭优惠券弹窗
			close(){
				this.isMask = 0;
			},
			//进入店铺
			toShop:function () {
			    uni.reLaunch({
			      url:"../../service/classify/shop_detail/shop_detail?id=" + this.id
			    })
			}
		}
	}
</script>

<style>
	.wrap{
		width:100%;
		height:100%;
	}
	.fuwu_wrap{
	  width:100%;
	  height:1546rpx;
	  background:url("https://wx.fujinyangche.com/nvrnetwork/images/fuwu_abc.jpg") no-repeat;
	  background-size: 100% 100%;
	}
	.footer{
	  width:100%;
	  height:100rpx;
	  padding:0 30rpx;
	  box-sizing: border-box;
	  display: flex;
	  background:rgba(255,255,255,1);
	  box-shadow:0px 4rpx 8rpx 0px rgba(0,0,0,0.5);
	  position: fixed;
	  bottom:0;
	  left:0;
	  z-index:100;
	}
	.submit{
	  flex:1;
	  height:80rpx;
	  background:linear-gradient(270deg,rgba(254,107,21,1) 0%,rgba(254,163,48,1) 100%);
	  border-radius:16rpx;
	  text-align: center;
	  font-size: 32rpx;
	  color:#ffffff;
	  line-height: 80rpx;
	  margin-top:10rpx;
	}
	.submit1{
	  flex:1;
	  height:80rpx;
	  border:1px solid rgba(254,163,48,1);
	  border-radius:16rpx;
	  text-align: center;
	  font-size: 32rpx;
	  background:linear-gradient(270deg, rgba(254,107,21,1) 0%, rgba(254,163,48,1) 100%);
	  -webkit-background-clip:text;
	  -webkit-text-fill-color:transparent;
	  margin-top:10rpx;
	  margin-right: 20rpx;
	  line-height: 80rpx;
	  box-sizing: border-box;
	}
	.discount_mask{
	  width:100%;
	  height:1546rpx;
	  background:rgba(0,0,0,0.5);
	  background-size: 100% 100%;
	  position: absolute;
	  top:0;
	  left:0;
	  display: none;
	}
	.discount_mask_wrap{
	  width:85%;
	  height:900rpx;
	  position: absolute;
	  top:80rpx;
	  left:50%;
	  transform: translateX(-50%);
	  z-index:200;
	}
	.discount_mask image{
	  display: block;
	  width: 100%;
	  height:100%;
	}
	.cancel{
	  width:40rpx;
	  height:40rpx;
	  border-radius: 50%;
	  background-color: rgba(253,102,1,0.8);
	  text-align: center;
	  line-height: 40rpx;
	  position: absolute;
	  top:0rpx;
	  right:0rpx;
	}
	.header_close{
	  font-size: 24rpx;
	  color:#FCD83C;
	}
	.discount_mask_title{
	  font-size: 60rpx;
	  color:#DF4606;
	  font-weight: bold;
	  position: absolute;
	  bottom:310rpx;
	  left:50%;
	  transform: translateX(-50%);
	}
	.discount_mask_time{
	  font-size: 28rpx;
	  color:#333334;
	  position: absolute;
	  bottom:260rpx;
	  left:50%;
	  transform: translateX(-50%);
	}
	.showMask{
	  display: block;
	}
</style>
