<template>
	<view class="container">

		<!-- #ifdef H5 -->
		<view style="color: #fff;">
			<tn-nav-bar backgroundColor="#26B3A0" :bottomShadow="false" @rightClick="jumpScoreRed">审核结果
				<!-- 	<template slot="right">
					课程购买记录
				</template> -->
			</tn-nav-bar>
			<view :style="{ height: tobheight + 'px' }"></view>
		</view>
		<!-- #endif -->


		<view class="content">
			<view class="topIcon">
				<!-- <image src="../../../static/posImg.png" mode=""></image> -->
				<icon type="error" size="54" color="#26B3A0" />
				<view class="txt">
					审核失败
				</view>
			</view>
			<view class="btn" @click="connectKefu">
				联系客服
			</view>
		</view>

		<view class="line">
		</view>
		<view class="sunTitle">
			失败原因
		</view>

		<view class="content2">
			{{detail.feedback_reason}}
		</view>
		<view class="sunTitle">
			失败截图
		</view>
		<view class="chooscontainer">
			<view class="addpicall" v-for="(item,index) in pic_url" :key="index">
				<image style="width: 184rpx;height:186rpx;border-radius: 20rpx;" @click="previewImg(item)" :src="item"
					mode="aspectFill"></image>
			</view>
		</view>
	</view>
</template>

<script>
	import {
		myTaskOrderDetail
	} from '@/api/my/index.js'
	export default {
		components: {},
		data() {
			return {
				tobheight: 45,
				pic_url: [require('@/static/posImg.png')],
				detail: {}
			};
		},
		computed: {

		},
		watch: {

		},
		async onLoad(o) {

			let res = await myTaskOrderDetail({
				task_order_id: o.id
			})
			if (res.code == 0) {
				this.detail = res.data
				this.pic_url = this.detail.feedback_image.split(',')
			}
			console.log('任务详情', this.detail);
		},
		onReady() {

		},
		onShow() {

		},
		onUnload() {

		},
		methods: {
			//点击预览图片
			previewImg(item) {
				uni.previewImage({
					current: item,
					urls: this.pic_url, //存放图片的数组
					loop: true,
					indicator: 'default'
				})
			},
			connectKefu() {
				uni.navigateTo({
					url: '/pages/user/public/kefu'
				})
			}
		}
	};
</script>

<style lang="scss" scoped>
	@import './index.scss';
</style>