<script setup lang='ts'>
const router = useRouter()
import { Status } from '~/store/info'

const props = defineProps<{
  id: string
}>()

const detail = ref(null)
await request({
  url: '/dyaw/ctfx/detail',
  data: {
    dc_id: props.id
  }
}).then(
  res => {
    if (res.code === "1") {
      detail.value = res.data.one_info
    }
  }
)
</script>

<template>
  <div class="w-1400px h-640px flex flex-col">
    <!-- <div class="flex justify-between">
        <div class="space-x-2 text-blue-700 flex items-center">
          <i:cil:home />
          <span>首页</span>
          <span>/</span>
          <span>错题分析</span>
          <span>/</span>
          <span>上传错题</span>
          <span>/</span>
          <span class="text-gray-600">详情</span>
        </div>
        <el-button type="primary" @click="router.back()">返回</el-button>
      </div> -->
    <el-page-header @back="router.back()" content="错题详情" />
    <el-divider />

    <cuoti-detail v-if="detail" :d="detail" />

    <el-divider />
    <div>
      <span>审核结果：</span><span class="text-gray-600">{{ Status[detail.dc_check] }}</span>
    </div>
    <div v-show="detail.dc_check === '2'">
      <span>处理意见：</span><span class="text-gray-600">{{ detail.dc_check_desc }}</span>
    </div>
  </div>
</template>
