【增加】AI 角色使用
This commit is contained in:
@ -33,7 +33,7 @@
|
||||
|
||||
</div>
|
||||
<div class="btn-container">
|
||||
<el-button type="primary" size="small">使用</el-button>
|
||||
<el-button type="primary" size="small" @click="handleUseClick(role)">使用</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</el-card>
|
||||
@ -53,7 +53,8 @@ const props = defineProps({
|
||||
}
|
||||
})
|
||||
// 定义钩子
|
||||
const emits = defineEmits(['onDelete', 'onEdit'])
|
||||
const emits = defineEmits(['onDelete', 'onEdit', 'onUse'])
|
||||
|
||||
// more 点击
|
||||
const handleMoreClick = async (data) => {
|
||||
const type = data[0]
|
||||
@ -65,6 +66,11 @@ const handleMoreClick = async (data) => {
|
||||
}
|
||||
}
|
||||
|
||||
// 使用
|
||||
const handleUseClick = (role) => {
|
||||
emits('onUse', role)
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
console.log('props', props.roleList)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user