user.vue 890 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <template>
  2. <div class="hc-project-wbs-user relative h-full">
  3. <hc-card>
  4. <template #header>
  5. 自定义标题栏
  6. </template>
  7. <template #extra>
  8. 自定义标题栏右边
  9. </template>
  10. 内容区域
  11. <template #action>
  12. 自定义底部
  13. </template>
  14. </hc-card>
  15. </div>
  16. </template>
  17. <script setup>
  18. import { onMounted, ref, watch } from 'vue'
  19. //双向绑定
  20. const modelData = defineModel('modelValue', {
  21. default: {},
  22. })
  23. //监听数据
  24. const formModel = ref({})
  25. watch(() => modelData.value, (data) => {
  26. formModel.value = data
  27. }, { immediate: true, deep: true })
  28. //渲染完成
  29. onMounted(() => {
  30. })
  31. </script>
  32. <style lang="scss">
  33. .hc-project-wbs-user {
  34. .el-card.hc-card-box.hc-new-card-box {
  35. box-shadow: none;
  36. }
  37. }
  38. </style>