<template>
	<view class="index">
		<u-overlay :show="show" >
			<view class="warp">
				<view class="rect" @tap.stop>
					<view class="rect-indent">
						{{title}}
					</view>
					<image src="@/static/icon/qs.png" mode=""></image>
					<view class="rect-look">
						<view class="" @click="jump(1)">
							再看看
						</view>
						<view v-if="titbut == '1'" class="" @click="jump(2)">
							取消订单
						</view>
						<view v-else class="" @click="jump(3)">
							立即退款
						</view>
					</view>
				</view>
			</view>
		</u-overlay>
	</view>
</template>

<script>
	import apiBaseConfig from '@/config/index.js';
	export default {
		props: {
			show: {
				type: Boolean,
			},
			title: {
				type: String,
			},
			titbut: {
				type: String
			}
		},
		data() {
			return {
				imgBgUrl: apiBaseConfig.imgBgUrl,
				globalData: getApp().globalData,
			};
		},
		onLoad() {},
		methods: {
			// 再看看1 取消订单 立即退款 2
			jump(val){
				if(val == 1){
					this.$emit('aindex')
				}else{
					this.$emit('aindexst',val)
				}
			}
		}
	};
</script>

<style lang="scss" scoped>
	.index {}

	.warp {
		display: flex;
		margin-top: 322rpx;
		justify-content: center;
	}

	.rect {
		width: calc(100% - 75rpx * 2);
		background-color: #ffffff;
		border-radius: 18rpx;
		text-align: center;

		&-indent {
			margin-top: 30rpx;
			text-align: center;
			font-size: 30rpx;
			font-weight: 400;
			color: #333333;
		}

		&-look {
			border-top: 1rpx solid #E7E7E7;
			display: flex;

			>view:nth-child(1) {
				width: 50%;
				height: 93rpx;
				line-height: 93rpx;
				text-align: center;
				font-size: 28rpx;
				font-weight: 400;
				color: #333333;
				border-right: 1rpx solid #E7E7E7;
			}

			>view:nth-child(2) {
				width: 50%;
				height: 93rpx;
				line-height: 93rpx;
				text-align: center;
				font-size: 28rpx;
				font-weight: 400;
				color: #FD0000;
			}
		}

		>image {
			margin-top: 54rpx;
			width: 305rpx;
			height: 188rpx;
			margin-bottom: 56rpx;
		}
	}
</style>
