This commit is contained in:
clay
2024-03-04 19:13:43 +08:00
commit e44edd71c0
350 changed files with 52288 additions and 0 deletions

View File

@@ -0,0 +1,48 @@
<template>
<node title="发起人" :is-root="true" :mode="mode" :content="content" show-avatar :user-info="config.props.assignedUser"
@selected="emit('selected')" @insertNode="type => emit('insertNode', type)"
placeholder="所有人" :header-bgc="config.props.headerBgc" :header-icon="UserFilled"/>
</template>
<script setup>
import Node from './Node.vue'
import {UserFilled} from '@element-plus/icons-vue'
import {defineExpose, defineProps} from "vue";
const emit = defineEmits(['insertNode','selected'])
const props = defineProps({
config:{
type: Object,
default: () => {
return {}
}
},
mode: {
type: String,
default: 'design'
}
})
const content = computed(() => {
if (props.config.props.assignedUser.length > 0){
let texts = []
props.config.props.assignedUser.forEach(org => texts.push(org.name))
return String(texts).replaceAll(',', '、')
} else {
return '所有人'
}
})
const validate = () => {
console.log("调用成功")
return []
}
defineExpose({
validate
})
</script>