<script setup lang="ts">
import { ref } from 'vue';
import type { SupplierModel } from '@/model/care.model';
import { type VxeGridInstance, type VxeGridProps, VxeUI } from 'vxe-pc-ui';
type FollowModel = Partial<SupplierModel>;
const props = defineProps<{ data: FollowModel }>();
// 表格配置VxeGridProps<FormModel>
const gridOptions = reactive<VxeGridProps<FollowModel>>({
  border: true,
  showOverflow: true,
  height: 'auto',
  columns: [
    {
      type: 'seq', // 使用序号列
      title: '序号',
      width: 90,
      fixed: 'left',
    },
    {
      field: 'deptName',
      title: '机构',
      width: 700,
    },
  ],
  data: props.data,
});
// 表格引用
const gridRef = ref<VxeGridInstance>();
</script>

<template>
  <div class="page-container">
    <vxe-grid ref="gridRef" v-bind="gridOptions" />
  </div>
</template>
<style scoped lang="scss">
.page-container {
  padding: 20px;
  height: 600px;
}
</style>
