<template>

    <el-table :data="formData" class="-mt-10px">
      <el-table-column label="序号" type="index" width="100" />
       <el-table-column label="是否授权人" prop="authPersonType" min-width="150" />
      <el-table-column label="姓名" prop="customerName" min-width="150" />
      <el-table-column label="手机号" prop="phoneNumber" min-width="150" />
      <el-table-column label="微信号" prop="wechat" min-width="150" />
      <el-table-column label="单位名称" prop="customerName" min-width="150" />
      <el-table-column label="职务" prop="name" min-width="150" />
      <el-table-column label="联系地址" prop="name" min-width="150" />
      <el-table-column label="类别" prop="name" min-width="150" />
      <el-table-column label="邮箱" prop="email" min-width="150" />
      <el-table-column label="身份证号" prop="name" min-width="150" />
      <el-table-column label="生日" prop="name" min-width="150" />
      <el-table-column label="性别" prop="name" min-width="150" />
    </el-table>
</template>
<script setup lang="ts">
import { getIntDictOptions, getStrDictOptions, DICT_TYPE, getBoolDictOptions } from '@/utils/dict'

const props = defineProps<{
  products: [] // 合同ID（主表的关联字段）
}>()
const formLoading = ref(false) // 表单的加载中
const formData = ref([])
const formRef = ref() // 表单 Ref

/** 监听主表的关联字段的变化，加载对应的子表数据 */
watch(
  () => props.products,
  async (val) => {
    // 1. 重置表单
    formData.value = val
  },
  { immediate: true }
)

/** 表单值 */
const getData = () => {
  return formData.value
}

defineExpose({ getData })
</script>