RoleDesc.vue 777 B

123456789101112131415161718
  1. <template>
  2. <BasicDrawer v-bind="$attrs" @register="registerDrawer" title="角色详情" width="500px" destroyOnClose>
  3. <Description :column="1" :data="roleData" :schema="formDescSchema" />
  4. </BasicDrawer>
  5. </template>
  6. <script lang="ts" setup>
  7. import { ref, useAttrs } from 'vue';
  8. import { BasicDrawer, useDrawerInner } from '/src/components/Drawer';
  9. import { formDescSchema } from '../role.data';
  10. import { Description, useDescription } from '/@/components/Description/index';
  11. const emit = defineEmits(['register']);
  12. const attrs = useAttrs();
  13. const roleData = ref({});
  14. const [registerDrawer, { setDrawerProps, closeDrawer }] = useDrawerInner(async (data) => {
  15. setDrawerProps({ confirmLoading: false });
  16. roleData.value = data.record;
  17. });
  18. </script>