<script setup lang="tsx">
import { PropType, ref } from 'vue'
import { TableData } from '@/api/reporting/RepVariableManagement/types'
import { Descriptions, DescriptionsSchema } from '@/components/Descriptions'

const detailSchema = ref<DescriptionsSchema[]>([
  {
    field: 'repCode',
    label: '报告编码'
  },
  {
    field: 'repName',
    label: '报名名称'
  },
  {
    field: 'indexCode',
    label: '指标编码'
  },
  {
    field: 'indexName',
    label: '指标名称'
  },
  {
    field: 'indexRule',
    label: '指标规则'
  }
])

defineProps({
  currentRow: {
    type: Object as PropType<TableData>,
    default: () => {}
  }
})
</script>

<template>
  <Descriptions :schema="detailSchema" :data="currentRow || {}" />
</template>
